[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [12940] trunk/blender/source/blender/src/ sculptmode.c: Fixed bug #7960, Sculpt Mode: Crash after Scaling brush to 1 ("Tile" mode)
Nicholas Bishop
nicholasbishop at gmail.com
Wed Dec 19 00:27:27 CET 2007
Revision: 12940
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=12940
Author: nicholasbishop
Date: 2007-12-19 00:27:26 +0100 (Wed, 19 Dec 2007)
Log Message:
-----------
Fixed bug #7960, Sculpt Mode: Crash after Scaling brush to 1 ("Tile" mode)
Division by zero fix
Modified Paths:
--------------
trunk/blender/source/blender/src/sculptmode.c
Modified: trunk/blender/source/blender/src/sculptmode.c
===================================================================
--- trunk/blender/source/blender/src/sculptmode.c 2007-12-18 21:56:17 UTC (rev 12939)
+++ trunk/blender/source/blender/src/sculptmode.c 2007-12-18 23:27:26 UTC (rev 12940)
@@ -857,8 +857,10 @@
px= len * cos(angle) + 2000;
py= len * sin(angle) + 2000;
}
- px %= sx-1;
- py %= sy-1;
+ if(sx != 1)
+ px %= sx-1;
+ if(sy != 1)
+ py %= sy-1;
p= get_texcache_pixel(ss, tcw*px/sx, tch*py/sy);
} else {
float fx= (pv.co[0] - e->mouse[0] + half) * (tcw*1.0f/bsize) - tcw/2;
More information about the Bf-blender-cvs
mailing list