Overlay Engine: Fix T72147 Blender crashes when Lock Object Modes off
Also fix sculpt mask inverted
This commit is contained in:
parent
574a59dfb0
commit
fda791ab12
Notes:
blender-bot
2023-02-14 10:37:49 +01:00
Referenced by issue #74286, Viewport anti-aliasing outline for selected objects not working Referenced by issue #72147, Blender crashes when Lock Object Modes off (Overlay engine refactor related ?)
|
@ -51,7 +51,7 @@ void OVERLAY_sculpt_cache_populate(OVERLAY_Data *vedata, Object *ob)
|
|||
const bool use_pbvh = BKE_sculptsession_use_pbvh_draw(ob, draw_ctx->v3d);
|
||||
|
||||
if (use_pbvh || !ob->sculpt->deform_modifiers_active || ob->sculpt->shapekey_active) {
|
||||
if (pbvh_has_mask(pbvh)) {
|
||||
if (!use_pbvh || pbvh_has_mask(pbvh)) {
|
||||
DRW_shgroup_call_sculpt(pd->sculpt_mask_grp, ob, false, true, false);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -11,8 +11,7 @@ void main()
|
|||
vec3 world_pos = point_object_to_world(pos);
|
||||
gl_Position = point_world_to_ndc(world_pos);
|
||||
|
||||
float mask = 1.0 - (msk * maskOpacity);
|
||||
finalColor = vec4(0.0, 0.0, 0.0, mask);
|
||||
finalColor = vec4(0.0, 0.0, 0.0, msk * maskOpacity);
|
||||
|
||||
#ifdef USE_WORLD_CLIP_PLANES
|
||||
world_clip_planes_calc_clip_distance(world_pos);
|
||||
|
|
Loading…
Reference in New Issue