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:
authorPablo Dobarro <pablodp606@gmail.com>2020-10-08 00:43:40 +0300
committerPablo Dobarro <pablodp606@gmail.com>2020-10-08 00:43:40 +0300
commitd8fcd8a3162faf9c0ad4c4eaf51bd43bc92f5789 (patch)
tree7c52bd08f8e65d3dba9e0943dc86cee99b8a4cda /source/blender/editors/sculpt_paint
parentc4a281e8018b4e2ee37628ea40b601daa138b921 (diff)
Fix sculpt raycast function returning wrong value
When sampled normals were disabled SCULPT_cursor_geometry_info_update was returning false instead of the value from the raycast data.
Diffstat (limited to 'source/blender/editors/sculpt_paint')
-rw-r--r--source/blender/editors/sculpt_paint/sculpt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 2bc19b625cd..1a2848f1b38 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -7162,7 +7162,7 @@ bool SCULPT_cursor_geometry_info_update(bContext *C,
mat[3][3];
float viewDir[3] = {0.0f, 0.0f, 1.0f};
int totnode;
- bool original = false, hit = false;
+ bool original = false;
ED_view3d_viewcontext_init(C, &vc, depsgraph);
@@ -7227,7 +7227,7 @@ bool SCULPT_cursor_geometry_info_update(bContext *C,
/* Option to return the face normal directly for performance o accuracy reasons. */
if (!use_sampled_normal) {
copy_v3_v3(out->normal, srd.face_normal);
- return hit;
+ return srd.hit;
}
/* Sampled normal calculation. */