summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_opengl/gl_rasterizer_cache.cpp
diff options
context:
space:
mode:
authorgreggameplayer <33609333+greggameplayer@users.noreply.github.com>2018-08-31 18:11:19 +0200
committerbunnei <bunneidev@gmail.com>2018-08-31 18:11:19 +0200
commit06578e89b2598eca6c2da1cb8dcdc576aa3f632a (patch)
tree2aadd703183d718591d538253072a03d0cfb0ceb /src/video_core/renderer_opengl/gl_rasterizer_cache.cpp
parentMerge pull request #1204 from lioncash/pimpl (diff)
downloadyuzu-06578e89b2598eca6c2da1cb8dcdc576aa3f632a.tar
yuzu-06578e89b2598eca6c2da1cb8dcdc576aa3f632a.tar.gz
yuzu-06578e89b2598eca6c2da1cb8dcdc576aa3f632a.tar.bz2
yuzu-06578e89b2598eca6c2da1cb8dcdc576aa3f632a.tar.lz
yuzu-06578e89b2598eca6c2da1cb8dcdc576aa3f632a.tar.xz
yuzu-06578e89b2598eca6c2da1cb8dcdc576aa3f632a.tar.zst
yuzu-06578e89b2598eca6c2da1cb8dcdc576aa3f632a.zip
Diffstat (limited to '')
-rw-r--r--src/video_core/renderer_opengl/gl_rasterizer_cache.cpp16
1 files changed, 13 insertions, 3 deletions
diff --git a/src/video_core/renderer_opengl/gl_rasterizer_cache.cpp b/src/video_core/renderer_opengl/gl_rasterizer_cache.cpp
index d87f90a62..e53a1a2ec 100644
--- a/src/video_core/renderer_opengl/gl_rasterizer_cache.cpp
+++ b/src/video_core/renderer_opengl/gl_rasterizer_cache.cpp
@@ -120,7 +120,11 @@ static constexpr std::array<FormatTuple, SurfaceParams::MaxPixelFormat> tex_form
true}, // DXN2UNORM
{GL_COMPRESSED_SIGNED_RG_RGTC2, GL_RG, GL_INT, ComponentType::SNorm, true}, // DXN2SNORM
{GL_COMPRESSED_RGBA_BPTC_UNORM_ARB, GL_RGBA, GL_UNSIGNED_INT_8_8_8_8, ComponentType::UNorm,
- true}, // BC7U
+ true}, // BC7U
+ {GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_ARB, GL_RGB, GL_UNSIGNED_INT_8_8_8_8,
+ ComponentType::UNorm, true}, // BC6H_UF16
+ {GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT_ARB, GL_RGB, GL_UNSIGNED_INT_8_8_8_8, ComponentType::UNorm,
+ true}, // BC6H_SF16
{GL_RGBA8, GL_RGBA, GL_UNSIGNED_BYTE, ComponentType::UNorm, false}, // ASTC_2D_4X4
{GL_RG8, GL_RG, GL_UNSIGNED_BYTE, ComponentType::UNorm, false}, // G8R8U
{GL_RG8, GL_RG, GL_BYTE, ComponentType::SNorm, false}, // G8R8S
@@ -210,6 +214,8 @@ static bool IsFormatBCn(PixelFormat format) {
case PixelFormat::DXN2SNORM:
case PixelFormat::DXN2UNORM:
case PixelFormat::BC7U:
+ case PixelFormat::BC6H_UF16:
+ case PixelFormat::BC6H_SF16:
return true;
}
return false;
@@ -266,6 +272,8 @@ static constexpr std::array<void (*)(u32, u32, u32, std::vector<u8>&, Tegra::GPU
MortonCopy<true, PixelFormat::DXN2UNORM>,
MortonCopy<true, PixelFormat::DXN2SNORM>,
MortonCopy<true, PixelFormat::BC7U>,
+ MortonCopy<true, PixelFormat::BC6H_UF16>,
+ MortonCopy<true, PixelFormat::BC6H_SF16>,
MortonCopy<true, PixelFormat::ASTC_2D_4X4>,
MortonCopy<true, PixelFormat::G8R8U>,
MortonCopy<true, PixelFormat::G8R8S>,
@@ -314,8 +322,10 @@ static constexpr std::array<void (*)(u32, u32, u32, std::vector<u8>&, Tegra::GPU
MortonCopy<false, PixelFormat::RGBA16UI>,
MortonCopy<false, PixelFormat::R11FG11FB10F>,
MortonCopy<false, PixelFormat::RGBA32UI>,
- // TODO(Subv): Swizzling DXT1/DXT23/DXT45/DXN1/DXN2/BC7U/ASTC_2D_4X4 formats is not
- // supported
+ // TODO(Subv): Swizzling DXT1/DXT23/DXT45/DXN1/DXN2/BC7U/BC6H_UF16/BC6H_SF16/ASTC_2D_4X4
+ // formats are not supported
+ nullptr,
+ nullptr,
nullptr,
nullptr,
nullptr,