diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2018-08-17 00:51:15 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2018-08-17 00:58:29 +0300 |
commit | 7d29c9a16b815b51bdd7539bbef2332e2ce94ec4 (patch) | |
tree | 6edc9de6c034ce44df9eb386cdf5f803553d7732 /source | |
parent | a01dec2d9cc10d8588ee08332322d5e906d2e66b (diff) |
Overlay: Fix crash when ghosting is enabled without wireframe
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/draw/modes/overlay_mode.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/draw/modes/overlay_mode.c b/source/blender/draw/modes/overlay_mode.c index fffbd60b5d4..e893aaa4038 100644 --- a/source/blender/draw/modes/overlay_mode.c +++ b/source/blender/draw/modes/overlay_mode.c @@ -223,8 +223,9 @@ static void overlay_cache_finish(void *vedata) /* only in solid mode */ if (v3d->shading.type == OB_SOLID && (v3d->shading.flag & V3D_SHADING_XRAY) == 0) { - if (stl->g_data->ghost_stencil_test) + if (stl->g_data->ghost_stencil_test && (psl->face_wireframe_pass != NULL)) { DRW_pass_state_add(psl->face_wireframe_pass, DRW_STATE_STENCIL_EQUAL); + } } } |