Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrea Weikert <elubie@gmx.net>2007-02-14 22:40:17 +0300
committerAndrea Weikert <elubie@gmx.net>2007-02-14 22:40:17 +0300
commit20a97122193b570b310bfcddba8375c7fa6f0f08 (patch)
tree56e9af2de5754d29350af79f028257c9be5ca49b
parent4aa33f56331351ee02d353fb47e6d71381404bb1 (diff)
=== bugfix ===
- possible fix for crash mentioned in [ #5781 ] Sculpt Brush Tool not working correctly - workaround for possible compiler glitch with floating point conversion.
-rw-r--r--source/blender/src/sculptmode.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/src/sculptmode.c b/source/blender/src/sculptmode.c
index fedf1d89392..ac03d36e1cb 100644
--- a/source/blender/src/sculptmode.c
+++ b/source/blender/src/sculptmode.c
@@ -1074,8 +1074,8 @@ float tex_strength(EditData *e, float *point, const float len,const unsigned vin
/* For Tile and Drag modes, get the 2D screen coordinates of the
and scale them up or down to the texture size. */
if(sd->texrept==SCULPTREPT_TILE) {
- const float sx= sd->mtex[sd->texact]->size[0];
- const float sy= sd->texsep ? sd->mtex[sd->texact]->size[1] : sx;
+ const int sx= (const int)sd->mtex[sd->texact]->size[0];
+ const int sy= (const int)sd->texsep ? sd->mtex[sd->texact]->size[1] : sx;
float fx= pv.co[0];
float fy= pv.co[1];
@@ -1090,8 +1090,8 @@ float tex_strength(EditData *e, float *point, const float len,const unsigned vin
px= len * cos(angle) + 2000;
py= len * sin(angle) + 2000;
}
- px%= (int)sx;
- py%= (int)sy;
+ px %= sx;
+ py %= sy;
p= get_ri_pixel(ri, ri->pr_rectx*px/sx, ri->pr_recty*py/sy);
} else {
float fx= (pv.co[0] - e->mouse[0] + half) * (ri->pr_rectx*1.0f/bsize) - ri->pr_rectx/2;