Actual fix for bug #17819, that doesn't disable the functionality, crash with tiled...
authorBrecht Van Lommel <brechtvanlommel@pandora.be>
Sat, 11 Oct 2008 22:16:39 +0000 (22:16 +0000)
committerBrecht Van Lommel <brechtvanlommel@pandora.be>
Sat, 11 Oct 2008 22:16:39 +0000 (22:16 +0000)
source/blender/gpu/intern/gpu_draw.c

index 8fcf0457812660fe275b6d62408aed49e27c05a7..2cd548afe52aefd6d6597cae1c88d0611eda96be 100644 (file)
@@ -359,6 +359,8 @@ int GPU_verify_image(Image *ima, int tftile, int tfmode, int compare)
        else
                GTS.tile= tftile;
 
+       GTS.tile = MAX2(0, GTS.tile);
+
        if(ima) {
                GTS.tileXRep = ima->xrep;
                GTS.tileYRep = ima->yrep;
@@ -448,9 +450,6 @@ int GPU_verify_image(Image *ima, int tftile, int tfmode, int compare)
 
        /* for tiles, copy only part of image into buffer */
        if (GTS.tilemode) {
-               return 0; //disabled for now, it causes crashes
-               //see http://projects.blender.org/tracker/index.php?func=detail&aid=17819&group_id=9&atid=125
-
                tilerect= MEM_mallocN(rectw*recth*sizeof(*tilerect), "tilerect");
 
                for (y=0; y<recth; y++) {