Add support for bindless textures from shader input (vertex buffer) on Vulkan (#6577)
* Add support for bindless textures from shader input (vertex buffer) * Shader cache version bump * Format whitespace * Remove cache entries on pool removal, disable for OpenGL * PR feedback
This commit is contained in:
parent
9b94662b4b
commit
c6f8bfed90
39 changed files with 1091 additions and 311 deletions
|
@ -192,12 +192,14 @@ namespace Ryujinx.Graphics.Gpu.Shader
|
|||
/// This automatically translates, compiles and adds the code to the cache if not present.
|
||||
/// </remarks>
|
||||
/// <param name="channel">GPU channel</param>
|
||||
/// <param name="samplerPoolMaximumId">Maximum ID that an entry in the sampler pool may have</param>
|
||||
/// <param name="poolState">Texture pool state</param>
|
||||
/// <param name="computeState">Compute engine state</param>
|
||||
/// <param name="gpuVa">GPU virtual address of the binary shader code</param>
|
||||
/// <returns>Compiled compute shader code</returns>
|
||||
public CachedShaderProgram GetComputeShader(
|
||||
GpuChannel channel,
|
||||
int samplerPoolMaximumId,
|
||||
GpuChannelPoolState poolState,
|
||||
GpuChannelComputeState computeState,
|
||||
ulong gpuVa)
|
||||
|
@ -214,7 +216,7 @@ namespace Ryujinx.Graphics.Gpu.Shader
|
|||
}
|
||||
|
||||
ShaderSpecializationState specState = new(ref computeState);
|
||||
GpuAccessorState gpuAccessorState = new(poolState, computeState, default, specState);
|
||||
GpuAccessorState gpuAccessorState = new(samplerPoolMaximumId, poolState, computeState, default, specState);
|
||||
GpuAccessor gpuAccessor = new(_context, channel, gpuAccessorState);
|
||||
gpuAccessor.InitializeReservedCounts(tfEnabled: false, vertexAsCompute: false);
|
||||
|
||||
|
@ -291,6 +293,7 @@ namespace Ryujinx.Graphics.Gpu.Shader
|
|||
/// <param name="state">GPU state</param>
|
||||
/// <param name="pipeline">Pipeline state</param>
|
||||
/// <param name="channel">GPU channel</param>
|
||||
/// <param name="samplerPoolMaximumId">Maximum ID that an entry in the sampler pool may have</param>
|
||||
/// <param name="poolState">Texture pool state</param>
|
||||
/// <param name="graphicsState">3D engine state</param>
|
||||
/// <param name="addresses">Addresses of the shaders for each stage</param>
|
||||
|
@ -299,6 +302,7 @@ namespace Ryujinx.Graphics.Gpu.Shader
|
|||
ref ThreedClassState state,
|
||||
ref ProgramPipelineState pipeline,
|
||||
GpuChannel channel,
|
||||
int samplerPoolMaximumId,
|
||||
ref GpuChannelPoolState poolState,
|
||||
ref GpuChannelGraphicsState graphicsState,
|
||||
ShaderAddresses addresses)
|
||||
|
@ -319,7 +323,7 @@ namespace Ryujinx.Graphics.Gpu.Shader
|
|||
UpdatePipelineInfo(ref state, ref pipeline, graphicsState, channel);
|
||||
|
||||
ShaderSpecializationState specState = new(ref graphicsState, ref pipeline, transformFeedbackDescriptors);
|
||||
GpuAccessorState gpuAccessorState = new(poolState, default, graphicsState, specState, transformFeedbackDescriptors);
|
||||
GpuAccessorState gpuAccessorState = new(samplerPoolMaximumId, poolState, default, graphicsState, specState, transformFeedbackDescriptors);
|
||||
|
||||
ReadOnlySpan<ulong> addressesSpan = addresses.AsSpan();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue