diff options
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/draw/intern/draw_manager_exec.c | 3 | ||||
-rw-r--r-- | source/blender/gpu/GPU_state.h | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/draw/intern/draw_manager_exec.c b/source/blender/draw/intern/draw_manager_exec.c index b3e1258ff7f..8a81b3db7d8 100644 --- a/source/blender/draw/intern/draw_manager_exec.c +++ b/source/blender/draw/intern/draw_manager_exec.c @@ -99,6 +99,9 @@ void drw_state_set(DRWState state) if (state & DRW_STATE_WRITE_COLOR) { write_mask |= GPU_WRITE_COLOR; } + if (state & DRW_STATE_WRITE_STENCIL_ENABLED) { + write_mask |= GPU_WRITE_STENCIL; + } switch (state & (DRW_STATE_CULL_BACK | DRW_STATE_CULL_FRONT)) { case DRW_STATE_CULL_BACK: diff --git a/source/blender/gpu/GPU_state.h b/source/blender/gpu/GPU_state.h index e56df6d77a7..253877bcca0 100644 --- a/source/blender/gpu/GPU_state.h +++ b/source/blender/gpu/GPU_state.h @@ -29,6 +29,7 @@ typedef enum eGPUWriteMask { GPU_WRITE_BLUE = (1 << 2), GPU_WRITE_ALPHA = (1 << 3), GPU_WRITE_DEPTH = (1 << 4), + GPU_WRITE_STENCIL = (1 << 5), GPU_WRITE_COLOR = (GPU_WRITE_RED | GPU_WRITE_GREEN | GPU_WRITE_BLUE | GPU_WRITE_ALPHA), } eGPUWriteMask; |