Fix T81484: Weight/Vertex paint with mirror and viewport clipping does not update stroke on initial side
Issue introduced in rB4f616c93f7cb. Issue here is that the the `StrokeCache` `mirror_symmetry_pass` is still in its previous state when entering `wpaint_do_symmetrical_brush_actions`. For the initial stroke this means that the (wrong) cache `mirror_symmetry_pass` ends up in SculptBrushTest `mirror_symmetry_pass` as well and thus the clipping test in `sculpt_brush_test_clipping` will fail. [ This one flips the coords to test against clipping according to (now wrong) `mirror_symmetry_pass` ] Solution seems simple: just ensure we start of with a `mirror_symmetry_pass` of zero in `wpaint_do_symmetrical_brush_actions` for the initial stroke. Same thing is done for vertex paint as well. Maniphest Tasks: T81484 Differential Revision: https://developer.blender.org/D9268
This commit is contained in:
parent
477d983c2e
commit
29dbe00719
Notes:
blender-bot
2023-02-13 22:37:44 +01:00
Referenced by issue #81484, Weight/Vertex paint with mirror and viewport clipping does not update stroke on original side
|
@ -2296,6 +2296,7 @@ static void wpaint_do_symmetrical_brush_actions(
|
|||
int i = 0;
|
||||
|
||||
/* initial stroke */
|
||||
cache->mirror_symmetry_pass = 0;
|
||||
wpaint_do_paint(C, ob, wp, sd, wpd, wpi, me, brush, 0, 'X', 0, 0);
|
||||
wpaint_do_radial_symmetry(C, ob, wp, sd, wpd, wpi, me, brush, 0, 'X');
|
||||
wpaint_do_radial_symmetry(C, ob, wp, sd, wpd, wpi, me, brush, 0, 'Y');
|
||||
|
@ -3316,6 +3317,7 @@ static void vpaint_do_symmetrical_brush_actions(
|
|||
int i = 0;
|
||||
|
||||
/* initial stroke */
|
||||
cache->mirror_symmetry_pass = 0;
|
||||
vpaint_do_paint(C, sd, vp, vpd, ob, me, brush, i, 'X', 0, 0);
|
||||
vpaint_do_radial_symmetry(C, sd, vp, vpd, ob, me, brush, i, 'X');
|
||||
vpaint_do_radial_symmetry(C, sd, vp, vpd, ob, me, brush, i, 'Y');
|
||||
|
|
Loading…
Reference in New Issue