From 3f305b9ab3cb66374e6bdf4662ff1bfe90b3c225 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Dietrich?= Date: Thu, 14 Apr 2022 03:04:29 +0200 Subject: Fix T97053: on cage GPU subdivision shows subdivided edges as actual edges When wireframe mode is turned on, the subdivision edges not originating from coarse edges were also drawn as regular edges, which would confuse users trying to select them. These should not be drawn in edit mode, only in object mode when optimal display is turned off (matching the CPU subdivision case). --- source/blender/draw/intern/draw_cache_impl_subdivision.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'source/blender/draw/intern') diff --git a/source/blender/draw/intern/draw_cache_impl_subdivision.cc b/source/blender/draw/intern/draw_cache_impl_subdivision.cc index e0ec0e64ea2..c859a72b371 100644 --- a/source/blender/draw/intern/draw_cache_impl_subdivision.cc +++ b/source/blender/draw/intern/draw_cache_impl_subdivision.cc @@ -1942,7 +1942,9 @@ static bool draw_subdiv_create_requested_buffers(const Scene *scene, return false; } - const bool optimal_display = (smd->flags & eSubsurfModifierFlag_ControlEdges); + /* Edges which do not come from coarse edges should not be drawn in edit mode, only in object + * mode when optimal display in turned off. */ + const bool optimal_display = (smd->flags & eSubsurfModifierFlag_ControlEdges) || is_editmode; draw_cache->bm = bm; draw_cache->mesh = mesh_eval; -- cgit v1.2.3