mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-10-01 12:30:00 +02:00
gpu: Implement missing texture formats (#1867)
* gpu: Implement Etc2Rgba texture format * Add more format * Fix wrong pixel format
This commit is contained in:
parent
430ba6da65
commit
73f6149bd6
3 changed files with 7 additions and 0 deletions
|
@ -82,6 +82,8 @@ namespace Ryujinx.Graphics.GAL
|
|||
Bc7Srgb,
|
||||
Bc6HSfloat,
|
||||
Bc6HUfloat,
|
||||
Etc2RgbaUnorm,
|
||||
Etc2RgbaSrgb,
|
||||
R8Uscaled,
|
||||
R8Sscaled,
|
||||
R16Uscaled,
|
||||
|
|
|
@ -53,6 +53,7 @@ namespace Ryujinx.Graphics.Gpu.Image
|
|||
{ 0x7ffaf, new FormatInfo(Format.D32Float, 1, 1, 4, 1) },
|
||||
{ 0x24a0e, new FormatInfo(Format.D24UnormS8Uint, 1, 1, 4, 2) },
|
||||
{ 0x24a29, new FormatInfo(Format.D24UnormS8Uint, 1, 1, 4, 2) },
|
||||
{ 0x48a29, new FormatInfo(Format.D24UnormS8Uint, 1, 1, 4, 2) },
|
||||
{ 0x25385, new FormatInfo(Format.D32FloatS8Uint, 1, 1, 8, 2) },
|
||||
{ 0x253b0, new FormatInfo(Format.D32FloatS8Uint, 1, 1, 8, 2) },
|
||||
{ 0xa4908, new FormatInfo(Format.R8G8B8A8Srgb, 1, 1, 4, 4) },
|
||||
|
@ -77,6 +78,8 @@ namespace Ryujinx.Graphics.Gpu.Image
|
|||
{ 0xa4917, new FormatInfo(Format.Bc7Srgb, 4, 4, 16, 4) },
|
||||
{ 0x7ff90, new FormatInfo(Format.Bc6HSfloat, 4, 4, 16, 4) },
|
||||
{ 0x7ff91, new FormatInfo(Format.Bc6HUfloat, 4, 4, 16, 4) },
|
||||
{ 0x2490b, new FormatInfo(Format.Etc2RgbaUnorm, 4, 4, 16, 4) },
|
||||
{ 0xa490b, new FormatInfo(Format.Etc2RgbaSrgb, 4, 4, 16, 4) },
|
||||
{ 0x24940, new FormatInfo(Format.Astc4x4Unorm, 4, 4, 16, 4) },
|
||||
{ 0x24950, new FormatInfo(Format.Astc5x4Unorm, 5, 4, 16, 4) },
|
||||
{ 0x24941, new FormatInfo(Format.Astc5x5Unorm, 5, 5, 16, 4) },
|
||||
|
|
|
@ -96,6 +96,8 @@ namespace Ryujinx.Graphics.OpenGL
|
|||
Add(Format.Bc7Srgb, new FormatInfo(1, false, false, All.CompressedSrgbAlphaBptcUnorm));
|
||||
Add(Format.Bc6HSfloat, new FormatInfo(1, false, false, All.CompressedRgbBptcSignedFloat));
|
||||
Add(Format.Bc6HUfloat, new FormatInfo(1, false, false, All.CompressedRgbBptcUnsignedFloat));
|
||||
Add(Format.Etc2RgbaUnorm, new FormatInfo(1, false, false, All.CompressedRgba8Etc2Eac));
|
||||
Add(Format.Etc2RgbaSrgb, new FormatInfo(1, false, false, All.CompressedSrgb8Alpha8Etc2Eac));
|
||||
Add(Format.R8Uscaled, new FormatInfo(1, false, true, All.R8ui, PixelFormat.RedInteger, PixelType.UnsignedByte));
|
||||
Add(Format.R8Sscaled, new FormatInfo(1, false, true, All.R8i, PixelFormat.RedInteger, PixelType.Byte));
|
||||
Add(Format.R16Uscaled, new FormatInfo(1, false, true, All.R16ui, PixelFormat.RedInteger, PixelType.UnsignedShort));
|
||||
|
|
Loading…
Reference in a new issue