Pass CbufSlot when getting info from the texture descriptor (#2291)
* Pass CbufSlot when getting info from the texture descriptor Fixes some issues with bindless textures, when CbufSlot is not equal to the current TextureBufferIndex. Specifically fixes a random chance of full screen colour flickering in Super Mario Party. * Apply suggestions from code review Oops Co-authored-by: gdkchan <gab.dark.100@gmail.com> Co-authored-by: gdkchan <gab.dark.100@gmail.com>
This commit is contained in:
parent
c805542b29
commit
0129250c2e
10 changed files with 35 additions and 27 deletions
|
@ -340,10 +340,11 @@ namespace Ryujinx.Graphics.Gpu.Image
|
|||
/// </summary>
|
||||
/// <param name="state">Current GPU state</param>
|
||||
/// <param name="handle">Shader "fake" handle of the texture</param>
|
||||
/// <param name="cbufSlot">Shader constant buffer slot of the texture</param>
|
||||
/// <returns>The texture descriptor</returns>
|
||||
public TextureDescriptor GetComputeTextureDescriptor(GpuState state, int handle)
|
||||
public TextureDescriptor GetComputeTextureDescriptor(GpuState state, int handle, int cbufSlot)
|
||||
{
|
||||
return _cpBindingsManager.GetTextureDescriptor(state, 0, handle);
|
||||
return _cpBindingsManager.GetTextureDescriptor(state, 0, handle, cbufSlot);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -352,10 +353,11 @@ namespace Ryujinx.Graphics.Gpu.Image
|
|||
/// <param name="state">Current GPU state</param>
|
||||
/// <param name="stageIndex">Index of the shader stage where the texture is bound</param>
|
||||
/// <param name="handle">Shader "fake" handle of the texture</param>
|
||||
/// <param name="cbufSlot">Shader constant buffer slot of the texture</param>
|
||||
/// <returns>The texture descriptor</returns>
|
||||
public TextureDescriptor GetGraphicsTextureDescriptor(GpuState state, int stageIndex, int handle)
|
||||
public TextureDescriptor GetGraphicsTextureDescriptor(GpuState state, int stageIndex, int handle, int cbufSlot)
|
||||
{
|
||||
return _gpBindingsManager.GetTextureDescriptor(state, stageIndex, handle);
|
||||
return _gpBindingsManager.GetTextureDescriptor(state, stageIndex, handle, cbufSlot);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -1297,4 +1299,4 @@ namespace Ryujinx.Graphics.Gpu.Image
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue