mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-12-11 14:19:10 +00:00
video_core: Address various UE bugs (#3559)
* vk_rasterizer: Reorder image query in fast clear elimination Fixes missing clears when a texture is being cleared using this method but never actually used for rendering purposes by ensuring the texture cache has at least a chance to register cmask * shader_recompiler: Partial support for ANCILLARY_ENA * pixel_format: Add number conversion of BC6 srgb format * texture_cache: Support aliases of 3D and 2D array images Used be UE to render its post processing LUT * pixel_format: Test BC6 srgb as unorm Still not sure what is up with snorm/unorm can be useful to have both actions to compare for now * video_core: Use attachment feedback layout instead of general if possible UE games often do mipgen passes where the previous mip of the image being rendered to is bound for reading. This appears to cause corruption issues so use attachment feedback loop extension to ensure correct output * renderer_vulkan: Improve feedback loop code * Set proper usage flag for feedback loop usage * Add dynamic state extension and enable it for color aspect when necessary * Check if image is bound instead of force_general for better code consistency * shader_recompiler: More proper depth export implementation * shader_recompiler: Fix bug in output modifiers * shader_recompiler: Fix sampling from MSAA images This is not allowed by any graphics API but seems hardware supports it somehow and it can be encountered. To avoid glitched output translate to to a texelFetch call on sample 0 * clang format * image: Add back missing code * shader_recompiler: Better ancillary implementation Now is implemented with a custom attribute that is constant propagated depending on which parts of it are extracted. It will assert if an unknown part is used or if the attribute itself is not removed by dead code elim * copy_shader: Ignore not enabled export channels * constant_propagation: Invalidate ancillary after successful elimination * spirv: Fix f11/f10 conversion to f32 --------- Co-authored-by: georgemoralis <giorgosmrls@gmail.com>
This commit is contained in:
@@ -205,12 +205,13 @@ struct FragmentRuntimeInfo {
|
||||
u32 num_inputs;
|
||||
std::array<PsInput, 32> inputs;
|
||||
std::array<PsColorBuffer, MaxColorBuffers> color_buffers;
|
||||
AmdGpu::Liverpool::ShaderExportFormat z_export_format;
|
||||
bool dual_source_blending;
|
||||
|
||||
bool operator==(const FragmentRuntimeInfo& other) const noexcept {
|
||||
return std::ranges::equal(color_buffers, other.color_buffers) &&
|
||||
en_flags.raw == other.en_flags.raw && addr_flags.raw == other.addr_flags.raw &&
|
||||
num_inputs == other.num_inputs &&
|
||||
num_inputs == other.num_inputs && z_export_format == other.z_export_format &&
|
||||
dual_source_blending == other.dual_source_blending &&
|
||||
std::ranges::equal(inputs.begin(), inputs.begin() + num_inputs, other.inputs.begin(),
|
||||
other.inputs.begin() + num_inputs);
|
||||
|
||||
Reference in New Issue
Block a user