Overlay: Fix crash caused by NULL passes
This commit is contained in:
parent
86c61ce64f
commit
839f0cfa41
Notes:
blender-bot
2023-02-14 10:32:59 +01:00
Referenced by issue #75112, GPencil – Crash When Selecting 2D Animation
|
@ -183,9 +183,11 @@ void OVERLAY_antialiasing_cache_finish(OVERLAY_Data *vedata)
|
|||
GPU_ATTACHMENT_TEXTURE(txl->overlay_line_tx)});
|
||||
}
|
||||
|
||||
pd->antialiasing.do_depth_copy = !DRW_pass_is_empty(psl->wireframe_ps) ||
|
||||
pd->antialiasing.do_depth_copy = !(psl->wireframe_ps == NULL ||
|
||||
DRW_pass_is_empty(psl->wireframe_ps)) ||
|
||||
(pd->xray_enabled && pd->xray_opacity > 0.0f);
|
||||
pd->antialiasing.do_depth_infront_copy = !DRW_pass_is_empty(psl->wireframe_xray_ps);
|
||||
pd->antialiasing.do_depth_infront_copy = !(psl->wireframe_xray_ps == NULL ||
|
||||
DRW_pass_is_empty(psl->wireframe_xray_ps));
|
||||
|
||||
const bool do_wireframe = pd->antialiasing.do_depth_copy ||
|
||||
pd->antialiasing.do_depth_infront_copy;
|
||||
|
|
Loading…
Reference in New Issue