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:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2010-03-27 15:35:14 +0300
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2010-03-27 15:35:14 +0300
commit865ceab54540d20cb2044c00fb69386f5557e6ca (patch)
tree648294189dfd3f0d4e29e1a9668dd9c58e1c2924 /source/blender
parent59d76439be0806ad76296337385dff1f20a3258a (diff)
Fix #20717: sculpt not working with ortho view + certain object scale.
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/editors/sculpt_paint/sculpt.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 0b11c1a25f6..509a1bcc61e 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -1852,13 +1852,13 @@ int sculpt_stroke_get_location(bContext *C, struct PaintStroke *stroke, float ou
sculpt_stroke_modifiers_check(C, ss);
viewline(vc->ar, vc->v3d, mval, ray_start, ray_end);
- sub_v3_v3v3(ray_normal, ray_end, ray_start);
- dist= normalize_v3(ray_normal);
invert_m4_m4(obimat, ss->ob->obmat);
mul_m4_v3(obimat, ray_start);
- mul_mat3_m4_v3(obimat, ray_normal);
- normalize_v3(ray_normal);
+ mul_m4_v3(obimat, ray_end);
+
+ sub_v3_v3v3(ray_normal, ray_end, ray_start);
+ dist= normalize_v3(ray_normal);
srd.ss = vc->obact->sculpt;
srd.ray_start = ray_start;