Fix #27346: When The FONT object is blank, the dimensions are calculated wong.
authorSergey Sharybin <sergey.vfx@gmail.com>
Mon, 9 May 2011 20:14:34 +0000 (20:14 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Mon, 9 May 2011 20:14:34 +0000 (20:14 +0000)
This commit fixes boundbox for empty curve-typed objects. Because of strange
reason (-1,-1,-1) and (1,1,1) was used as boundbox. Now it uses zero-sized
boundbox (as it's done for meshes).

This commit makes nothig with that single space character text from the report.

source/blender/blenkernel/intern/displist.c

index b5194ca2f8965fac0b259b513016b084354b68f0..29b9fd5eab7a855b37698d1f982bdf1392204d34 100644 (file)
@@ -1973,8 +1973,9 @@ static void boundbox_displist(Object *ob)
                }
                
                if(!doit) {
-                       min[0] = min[1] = min[2] = -1.0f;
-                       max[0] = max[1] = max[2] = 1.0f;
+                       /* there's no geometry in displist, use zero-sized boundbox */
+                       zero_v3(min);
+                       zero_v3(max);
                }
                
        }