[Bf-blender-cvs] [2b3367cdf86] blender-v3.1-release: Fix T93573: Curve evaluated mesh selected in edit mode
Hans Goudey
noreply at git.blender.org
Mon Mar 7 20:54:59 CET 2022
Commit: 2b3367cdf8694a3e48ed5cc2be5381aabceed9c4
Author: Hans Goudey
Date: Mon Mar 7 13:54:49 2022 -0600
Branches: blender-v3.1-release
https://developer.blender.org/rB2b3367cdf8694a3e48ed5cc2be5381aabceed9c4
Fix T93573: Curve evaluated mesh selected in edit mode
This fixes the second part of T93573 that 8506f3d9fe9359518e didn't
properly address. Specifically, outlines of instances still had the
selected color in edit mode in wireframe view. This change is the
same as that commit, just in a different place.
Differential Revision: https://developer.blender.org/D14229
===================================================================
M source/blender/draw/engines/overlay/overlay_wireframe.c
===================================================================
diff --git a/source/blender/draw/engines/overlay/overlay_wireframe.c b/source/blender/draw/engines/overlay/overlay_wireframe.c
index 1eb8fc981cf..b97e76085e9 100644
--- a/source/blender/draw/engines/overlay/overlay_wireframe.c
+++ b/source/blender/draw/engines/overlay/overlay_wireframe.c
@@ -291,8 +291,12 @@ void OVERLAY_wireframe_cache_populate(OVERLAY_Data *vedata,
const bool is_sculpt_mode = ((ob->mode & OB_MODE_SCULPT) != 0) && (ob->sculpt != NULL);
const bool use_sculpt_pbvh = BKE_sculptsession_use_pbvh_draw(ob, draw_ctx->v3d) &&
!DRW_state_is_image_render();
+ const bool is_instance = (ob->base_flag & BASE_FROM_DUPLI);
+ const bool instance_parent_in_edit_mode = is_instance ? DRW_object_is_in_edit_mode(
+ DRW_object_get_dupli_parent(ob)) :
+ false;
const bool use_coloring = (use_wire && !is_edit_mode && !is_sculpt_mode &&
- !has_edit_mesh_cage);
+ !has_edit_mesh_cage && !instance_parent_in_edit_mode);
geom = DRW_cache_object_face_wireframe_get(ob);
if (geom || use_sculpt_pbvh) {
More information about the Bf-blender-cvs
mailing list