[Bf-blender-cvs] [141de0c] blender-v2.76-release: Fix T46148: Sculpt view-clip fails in ortho mode

Campbell Barton noreply at git.blender.org
Wed Sep 23 16:11:45 CEST 2015


Commit: 141de0cc7f4aaaafce61f991ec9a9cdb25d471e0
Author: Campbell Barton
Date:   Fri Sep 18 15:29:49 2015 +1000
Branches: blender-v2.76-release
https://developer.blender.org/rB141de0cc7f4aaaafce61f991ec9a9cdb25d471e0

Fix T46148: Sculpt view-clip fails in ortho mode

===================================================================

M	source/blender/editors/sculpt_paint/sculpt.c

===================================================================

diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 4cedf52..07511e1 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -4217,7 +4217,10 @@ static float sculpt_raycast_init(ViewContext *vc, const float mouse[2], float ra
 	sub_v3_v3v3(ray_normal, ray_end, ray_start);
 	dist = normalize_v3(ray_normal);
 
-	if (!rv3d->is_persp) {
+	if ((rv3d->is_persp == false) &&
+	    /* if the ray is clipped, don't adjust its start/end */
+	    ((rv3d->rflag & RV3D_CLIPPING) == 0))
+	{
 		BKE_pbvh_raycast_project_ray_root(ob->sculpt->pbvh, original, ray_start, ray_end, ray_normal);
 
 		/* recalculate the normal */




More information about the Bf-blender-cvs mailing list