mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-06-28 21:56:24 +02:00
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
|
@ -69,6 +69,7 @@ namespace Ryujinx.Graphics.Shader
|
|||
{
|
||||
string typeName = (type & SamplerType.Mask) switch
|
||||
{
|
||||
SamplerType.None => "sampler",
|
||||
SamplerType.Texture1D => "sampler1D",
|
||||
SamplerType.TextureBuffer => "samplerBuffer",
|
||||
SamplerType.Texture2D => "sampler2D",
|
||||
|
@ -95,6 +96,31 @@ namespace Ryujinx.Graphics.Shader
|
|||
return typeName;
|
||||
}
|
||||
|
||||
public static string ToGlslTextureType(this SamplerType type)
|
||||
{
|
||||
string typeName = (type & SamplerType.Mask) switch
|
||||
{
|
||||
SamplerType.Texture1D => "texture1D",
|
||||
SamplerType.TextureBuffer => "textureBuffer",
|
||||
SamplerType.Texture2D => "texture2D",
|
||||
SamplerType.Texture3D => "texture3D",
|
||||
SamplerType.TextureCube => "textureCube",
|
||||
_ => throw new ArgumentException($"Invalid texture type \"{type}\"."),
|
||||
};
|
||||
|
||||
if ((type & SamplerType.Multisample) != 0)
|
||||
{
|
||||
typeName += "MS";
|
||||
}
|
||||
|
||||
if ((type & SamplerType.Array) != 0)
|
||||
{
|
||||
typeName += "Array";
|
||||
}
|
||||
|
||||
return typeName;
|
||||
}
|
||||
|
||||
public static string ToGlslImageType(this SamplerType type, AggregateType componentType)
|
||||
{
|
||||
string typeName = (type & SamplerType.Mask) switch
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue