diff options
author | Alexander Gavrilov <angavrilov@gmail.com> | 2018-11-29 14:24:30 +0300 |
---|---|---|
committer | Alexander Gavrilov <angavrilov@gmail.com> | 2018-11-29 14:25:16 +0300 |
commit | 28d2058e2c4801da4b4c60b2870deb13b535b1cc (patch) | |
tree | c0903f3c15a3d821b2b93de33c20d68f264ee729 /source | |
parent | fbb19bcaf95c2f3d1a2d2abc826d298e45c5a060 (diff) |
Fix rotate around point under cursor 'seeing' hidden faces in paint modes.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/draw/engines/basic/basic_engine.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/draw/engines/basic/basic_engine.c b/source/blender/draw/engines/basic/basic_engine.c index 9dc8c8f2f34..8356838a885 100644 --- a/source/blender/draw/engines/basic/basic_engine.c +++ b/source/blender/draw/engines/basic/basic_engine.c @@ -157,7 +157,10 @@ static void basic_cache_populate(void *vedata, Object *ob) } } - struct GPUBatch *geom = DRW_cache_object_surface_get(ob); + const bool is_active = (ob == draw_ctx->obact); + const bool use_hide = is_active && DRW_object_use_hide_faces(ob); + + struct GPUBatch *geom = DRW_cache_object_surface_get_ex(ob, use_hide); if (geom) { const bool do_cull = (draw_ctx->v3d && (draw_ctx->v3d->flag2 & V3D_BACKFACE_CULLING)); /* Depth Prepass */ |