Ryujinx-uplift/Ryujinx.Graphics.Shader
riperiperi 79adba4402
Add support for render scale to vertex stage. (#2763)
* Add support for render scale to vertex stage.

Occasionally games read off textureSize on the vertex stage to inform the fragment shader what size a texture is without querying in there. Scales were not present in the vertex shader to correct the sizes, so games were providing the raw upscaled texture size to the fragment shader, which was incorrect.

One downside is that the fragment and vertex support buffer description must be identical, so the full size scales array must be defined when used. I don't think this will have an impact though. Another is that the fragment texture count must be updated when vertex shader textures are used. I'd like to correct this so that the update is folded into the update for the scales.

Also cleans up a bunch of things, like it making no sense to call CommitRenderScale for each stage.

Fixes render scale causing a weird offset bloom in Super Mario Party and Clubhouse Games. Clubhouse Games still has a pixelated look in a number of its games due to something else it does in the shader.

* Split out support buffer update, lazy updates.

* Commit support buffer before compute dispatch

* Remove unnecessary qualifier.

* Address Feedback
2022-01-08 14:48:48 -03:00
..
CodeGen/Glsl Add support for render scale to vertex stage. (#2763) 2022-01-08 14:48:48 -03:00
Decoders Support shader gl_Color, gl_SecondaryColor and gl_TexCoord built-ins (#2817) 2021-11-08 13:18:46 -03:00
Instructions Fix SUATOM and other texture shader instructions with RZ dest (#2885) 2021-12-08 18:36:09 -03:00
IntermediateRepresentation Fix FLO.SH shader instruction with a input of 0 (#2876) 2021-12-05 13:25:05 +01:00
StructuredIr Implement remaining shader double-precision instructions (#2845) 2021-12-08 17:54:12 -03:00
Translation Add support for render scale to vertex stage. (#2763) 2022-01-08 14:48:48 -03:00
BufferDescriptor.cs Implement lazy flush-on-read for Buffers (SSBO/Copy) (#1790) 2021-01-17 17:08:06 -03:00
BufferUsageFlags.cs Implement lazy flush-on-read for Buffers (SSBO/Copy) (#1790) 2021-01-17 17:08:06 -03:00
Constants.cs Initial support for shader attribute indexing (#2546) 2021-08-27 01:44:47 +02:00
IGpuAccessor.cs Add support for fragment shader interlock (#2768) 2021-10-28 19:53:12 -03:00
InputTopology.cs Salieri: shader cache (#1701) 2020-11-13 00:15:34 +01:00
OutputTopology.cs Support texture rectangle targets (non-normalized coords) 2020-01-09 02:13:00 +01:00
Ryujinx.Graphics.Shader.csproj Add support for render scale to vertex stage. (#2763) 2022-01-08 14:48:48 -03:00
SamplerType.cs Avoid sampler conflicts on bindless samplers with the same name (#1642) 2020-10-28 21:20:43 +01:00
ShaderProgram.cs shadertools: Prepare for new target Languages and APIs (#2465) 2021-07-18 12:49:39 +02:00
ShaderProgramInfo.cs Only make render target 2D textures layered if needed (#2646) 2021-09-29 01:55:12 +02:00
ShaderStage.cs Add support for render scale to vertex stage. (#2763) 2022-01-08 14:48:48 -03:00
SupportBuffer.cs Add support for render scale to vertex stage. (#2763) 2022-01-08 14:48:48 -03:00
TessPatchType.cs Initial tessellation shader support (#2534) 2021-10-18 18:38:04 -03:00
TessSpacing.cs Initial tessellation shader support (#2534) 2021-10-18 18:38:04 -03:00
TextureDescriptor.cs Salieri: shader cache (#1701) 2020-11-13 00:15:34 +01:00
TextureFormat.cs Implement SULD shader instruction (#1117) 2020-04-22 09:35:28 +10:00
TextureHandle.cs Extend bindless elimination to work with masked and shifted handles (#2727) 2021-10-17 17:28:18 -03:00
TextureUsageFlags.cs Add support for fragment shader interlock (#2768) 2021-10-28 19:53:12 -03:00