diff options
author | Hans Goudey <h.goudey@me.com> | 2022-03-07 22:54:49 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2022-03-07 22:54:49 +0300 |
commit | 2b3367cdf8694a3e48ed5cc2be5381aabceed9c4 (patch) | |
tree | 3cc752dee6a09fbdf68628dd45842036a33d9339 | |
parent | 60481e4d99920d28c840342c0b27fa083dd4ffd9 (diff) |
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
-rw-r--r-- | source/blender/draw/engines/overlay/overlay_wireframe.c | 6 |
1 files changed, 5 insertions, 1 deletions
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) { |