Revert "Overlay: Wireframe: avoid using custom depth bias with xray enabled"

This reverts commit 14500953ed.

The commit has introduced multiple drawing regressions in xray mode and
was already reverted in 4.1. A different solution has to be found or
the current one should make sure these regressions are fixed.

Finding the correct solution isn't priority.

* #120208
* #119527

Pull Request: https://projects.blender.org/blender/blender/pulls/120285
This commit is contained in:
Jeroen Bakker
2024-04-05 08:08:09 +02:00
parent 4cb1d7242a
commit 4574de1092

View File

@@ -67,8 +67,7 @@ void OVERLAY_wireframe_cache_init(OVERLAY_Data *vedata)
const bool use_select = (DRW_state_is_select() || DRW_state_is_depth());
GPUShader *wires_sh = use_select ? OVERLAY_shader_wireframe_select() :
OVERLAY_shader_wireframe(pd->antialiasing.enabled &&
!pd->xray_enabled);
OVERLAY_shader_wireframe(pd->antialiasing.enabled);
for (int xray = 0; xray < (is_material_shmode ? 1 : 2); xray++) {
DRWState state = DRW_STATE_FIRST_VERTEX_CONVENTION | DRW_STATE_WRITE_COLOR |