diff options
author | Falk David <falkdavid@gmx.de> | 2021-01-04 17:31:53 +0300 |
---|---|---|
committer | Falk David <falkdavid@gmx.de> | 2021-01-04 17:34:02 +0300 |
commit | 09c1cb8a17e4c1a0aeea0d5477ec2db61390a5e8 (patch) | |
tree | 375c360ff15a6d346f337edee0492501c0f659b9 /source/blender/draw/engines/overlay/shaders | |
parent | c6e5b3f42dfc05e911ef30df12821138e1225e91 (diff) |
Fix T84260: NURBS edit mode lines not showing
When in edit mode, the edit lines for de-selected surfaces did not
show up.
The bug was caused by the is_gpencil bool which reused another flag.
Both grease pencil and nurbs surfaces use the edit_curve_handle shader.
A dedicated flag was added to make sure the is_gpencil bool is
set correctly.
Reviewed By: fclem
Maniphest Tasks: T84260
Differential Revision: https://developer.blender.org/D9985
Diffstat (limited to 'source/blender/draw/engines/overlay/shaders')
-rw-r--r-- | source/blender/draw/engines/overlay/shaders/edit_curve_handle_geom.glsl | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/draw/engines/overlay/shaders/edit_curve_handle_geom.glsl b/source/blender/draw/engines/overlay/shaders/edit_curve_handle_geom.glsl index 442f69aec7e..ad791a9416d 100644 --- a/source/blender/draw/engines/overlay/shaders/edit_curve_handle_geom.glsl +++ b/source/blender/draw/engines/overlay/shaders/edit_curve_handle_geom.glsl @@ -53,9 +53,8 @@ void main() bool edge_selected = (((vertFlag[1] | vertFlag[0]) & VERT_SELECTED) != 0); bool handle_selected = (showCurveHandles && (((vertFlag[1] | vertFlag[0]) & VERT_SELECTED_BEZT_HANDLE) != 0)); - /* It reuses freestyle flag because the flag is 8 bits and all are already used and this - * flag is not used in this context. */ - bool is_gpencil = ((vertFlag[1] & EDGE_FREESTYLE) != 0); + + bool is_gpencil = ((vertFlag[1] & VERT_GPENCIL_BEZT_HANDLE) != 0); /* If handle type is only selected and the edge is not selected, don't show. */ if ((curveHandleDisplay != CURVE_HANDLE_ALL) && (!handle_selected)) { |