diff options
author | Alexander Gavrilov <angavrilov@gmail.com> | 2018-11-25 18:34:28 +0300 |
---|---|---|
committer | Alexander Gavrilov <angavrilov@gmail.com> | 2018-11-26 20:26:29 +0300 |
commit | 7d32d87a86e442c11e7775d7200eba2055f34f07 (patch) | |
tree | a370091fc1ee952a54ff870174f05e5216824b39 /source/blender/draw/engines/eevee/eevee_materials.c | |
parent | 99f7934e19ddf6796e866d2ddc0c3882ed8fcc2b (diff) |
Viewport: implement hiding faces in paint modes.
In 2.79 hiding works in paint modes with selection enabled,
so it is a missing feature. This implements it in texture
paint overlays and in workbench base shading.
Reviewers: fclem
Differential Revision: https://developer.blender.org/D3989
Diffstat (limited to 'source/blender/draw/engines/eevee/eevee_materials.c')
-rw-r--r-- | source/blender/draw/engines/eevee/eevee_materials.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/draw/engines/eevee/eevee_materials.c b/source/blender/draw/engines/eevee/eevee_materials.c index a87b4626628..6736d4c4110 100644 --- a/source/blender/draw/engines/eevee/eevee_materials.c +++ b/source/blender/draw/engines/eevee/eevee_materials.c @@ -1450,6 +1450,7 @@ void EEVEE_materials_cache_populate(EEVEE_Data *vedata, EEVEE_ViewLayerData *sld is_sculpt_mode && ((ob->sculpt && ob->sculpt->pbvh) && (BKE_pbvh_type(ob->sculpt->pbvh) != PBVH_FACES)); #endif + const bool use_hide = is_active && DRW_object_use_hide_faces(ob); const bool is_default_mode_shader = is_sculpt_mode; /* First get materials for this mesh. */ @@ -1526,7 +1527,7 @@ void EEVEE_materials_cache_populate(EEVEE_Data *vedata, EEVEE_ViewLayerData *sld int *auto_layer_is_srgb; int auto_layer_count; struct GPUBatch **mat_geom = DRW_cache_object_surface_material_get( - ob, gpumat_array, materials_len, + ob, gpumat_array, materials_len, use_hide, &auto_layer_names, &auto_layer_is_srgb, &auto_layer_count); |