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:
authorPhilipp Oeser <info@graphics-engineer.com>2020-10-06 13:50:11 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2020-10-13 14:17:01 +0300
commitc11ae5cd21259a991b3cb1febdd4184fa62d789a (patch)
tree0bb29791dd416c82831c08805347b47e973de354 /source/blender/editors/sculpt_paint/sculpt_intern.h
parent3f78569c3e62ea3a184c7e0854e6e699c814cc72 (diff)
Fix sculpting/painting with viewport clipping and radial symmetry
This was reported for sculpting, the same is true for weightpaint or vertexpaint though. When viewport clipping and radial symmetry are enabled, the 'sculpt_brush_test_clipping()' function was not considering radial symmetry at all, so if the coordinate was outside the clipping planes, no action would take place. Now the coordinte is brought back to where the stroke actually happens and that is checked against clipping. Since other mirroring options while painting/sculpting (as well as editmode operations with mirroring) usually still take place even if the mirrored coord is outside the clipping planes, this should also be the case for radial symmetry. This grows the 'SculptBrushTest' struct a bit, but should be acceptable? Fixes T81466 Maniphest Tasks: T81466 Differential Revision: https://developer.blender.org/D9120
Diffstat (limited to 'source/blender/editors/sculpt_paint/sculpt_intern.h')
-rw-r--r--source/blender/editors/sculpt_paint/sculpt_intern.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt_intern.h b/source/blender/editors/sculpt_paint/sculpt_intern.h
index e6710e27115..84a47ab86ba 100644
--- a/source/blender/editors/sculpt_paint/sculpt_intern.h
+++ b/source/blender/editors/sculpt_paint/sculpt_intern.h
@@ -735,6 +735,9 @@ typedef struct SculptBrushTest {
float dist;
int mirror_symmetry_pass;
+ int radial_symmetry_pass;
+ float symm_rot_mat_inv[4][4];
+
/* For circle (not sphere) projection. */
float plane_view[4];