diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2020-02-03 15:30:41 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2020-02-03 18:15:05 +0300 |
commit | dcf44dfe8e0b0a084554ecb2cb2d34f0e273d933 (patch) | |
tree | 9bbcb5c3b89e48e0260ecbb19b105cab0db8b521 /source/blender/draw/engines/overlay/overlay_armature.c | |
parent | f13940e883cf7c64ee5d7dd1d05ac425db56d126 (diff) |
Fix T65114 Overlay: Armature: Bones with negative scale have wrong display
This moves the backface culling to the fragment shader to avoid all the
limitations of the current system. This has a cost but it is unlikely that
bone drawing will be a bottleneck.
Diffstat (limited to 'source/blender/draw/engines/overlay/overlay_armature.c')
-rw-r--r-- | source/blender/draw/engines/overlay/overlay_armature.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/draw/engines/overlay/overlay_armature.c b/source/blender/draw/engines/overlay/overlay_armature.c index 0b77fcad265..9fde3ec0902 100644 --- a/source/blender/draw/engines/overlay/overlay_armature.c +++ b/source/blender/draw/engines/overlay/overlay_armature.c @@ -186,7 +186,7 @@ void OVERLAY_armature_cache_init(OVERLAY_Data *vedata) cb->custom_shapes_ghash = BLI_ghash_ptr_new(__func__); DRWState infront_state = (DRW_state_is_select() && (i == 1)) ? DRW_STATE_IN_FRONT_SELECT : 0; - state = DRW_STATE_WRITE_COLOR | DRW_STATE_DEPTH_LESS_EQUAL | DRW_STATE_CULL_BACK | + state = DRW_STATE_WRITE_COLOR | DRW_STATE_DEPTH_LESS_EQUAL | (pd->armature.transparent ? DRW_STATE_BLEND_ALPHA : DRW_STATE_WRITE_DEPTH); DRW_PASS_CREATE(*p_armature_ps, state | pd->clipping_state | infront_state); |