Fix #112289: Workbench: Always clear depth_in_front
This commit is contained in:
@@ -470,6 +470,10 @@ class Instance {
|
||||
GPU_DEPTH24_STENCIL8,
|
||||
GPU_TEXTURE_USAGE_SHADER_READ |
|
||||
GPU_TEXTURE_USAGE_ATTACHMENT);
|
||||
|
||||
fb.ensure(GPU_ATTACHMENT_TEXTURE(resources.depth_in_front_tx));
|
||||
fb.bind();
|
||||
GPU_framebuffer_clear_depth_stencil(fb, 1.0f, 0x00);
|
||||
}
|
||||
|
||||
opaque_ps.draw(
|
||||
|
||||
@@ -172,10 +172,10 @@ void OpaquePass::draw(Manager &manager,
|
||||
opaque_fb.bind();
|
||||
|
||||
manager.submit(gbuffer_in_front_ps_, view);
|
||||
}
|
||||
|
||||
if (resources.depth_in_front_tx.is_valid()) {
|
||||
GPU_texture_copy(resources.depth_in_front_tx, resources.depth_tx);
|
||||
if (resources.depth_in_front_tx.is_valid()) {
|
||||
GPU_texture_copy(resources.depth_in_front_tx, resources.depth_tx);
|
||||
}
|
||||
}
|
||||
|
||||
if (!gbuffer_ps_.is_empty()) {
|
||||
|
||||
Reference in New Issue
Block a user