mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-12-10 21:58:45 +00:00
video_core: Check DB_SHADER_CONTROL register before performing depth exports (#3588)
The DB_SHADER_CONTROL register has several enable flags which must be set before certain depth exports are enabled. This commit adds logic to respect the values in this register when performing depth exports, which fixes the regression in earlier versions of KNACK. I've also renamed DepthBufferControl to DepthShaderControl, since that's closer to the official name for the register.
This commit is contained in:
@@ -338,7 +338,7 @@ struct Liverpool {
|
||||
GreaterThanZ = 2,
|
||||
};
|
||||
|
||||
union DepthBufferControl {
|
||||
union DepthShaderControl {
|
||||
u32 raw;
|
||||
BitField<0, 1, u32> z_export_enable;
|
||||
BitField<1, 1, u32> stencil_test_val_export_enable;
|
||||
@@ -1410,7 +1410,7 @@ struct Liverpool {
|
||||
DepthControl depth_control;
|
||||
INSERT_PADDING_WORDS(1);
|
||||
ColorControl color_control;
|
||||
DepthBufferControl depth_buffer_control;
|
||||
DepthShaderControl depth_shader_control;
|
||||
ClipperControl clipper_control;
|
||||
PolygonControl polygon_control;
|
||||
ViewportControl viewport_control;
|
||||
|
||||
Reference in New Issue
Block a user