Commit: ed44bb902d6b2f861cbcdbb1bffd5339ab3b50e7 Author: Philipp Oeser Date: Fri Mar 20 11:41:25 2020 +0100 Branches: master https://developer.blender.org/rBed44bb902d6b2f861cbcdbb1bffd5339ab3b50e7
Fix T74872: Clipping Region not updating Caused by rBc476c36e4008. This hooks into the existing FIXME (workaround for a missing update tagging), needs to also check the clip_state (to detect changes in DRW_STATE_CLIP_PLANES). Maniphest Tasks: T74872 Differential Revision: https://developer.blender.org/D7193 =================================================================== M source/blender/draw/engines/workbench/workbench_data.c =================================================================== diff --git a/source/blender/draw/engines/workbench/workbench_data.c b/source/blender/draw/engines/workbench/workbench_data.c index ceb57327fb0..432179e68e2 100644 --- a/source/blender/draw/engines/workbench/workbench_data.c +++ b/source/blender/draw/engines/workbench/workbench_data.c @@ -189,7 +189,15 @@ void workbench_private_data_init(WORKBENCH_PrivateData *wpd) wpd->preferences = &U; wpd->scene = scene; wpd->sh_cfg = draw_ctx->sh_cfg; - wpd->clip_state = RV3D_CLIPPING_ENABLED(v3d, rv3d) ? DRW_STATE_CLIP_PLANES : 0; + + /* FIXME: This reproduce old behavior when workbench was separated in 2 engines. + * But this is a workaround for a missing update tagging. */ + DRWState clip_state = RV3D_CLIPPING_ENABLED(v3d, rv3d) ? DRW_STATE_CLIP_PLANES : 0; + if (clip_state != wpd->clip_state) { + wpd->view_updated = true; + } + wpd->clip_state = clip_state; + wpd->cull_state = CULL_BACKFACE_ENABLED(wpd) ? DRW_STATE_CULL_BACK : 0; wpd->vldata = vldata; wpd->world_ubo = vldata->world_ubo; _______________________________________________ Bf-blender-cvs mailing list [email protected] https://lists.blender.org/mailman/listinfo/bf-blender-cvs
