From 71c37dd6c420ed7726d120d3ccba06a534195e55 Mon Sep 17 00:00:00 2001 From: Billy Laws Date: Sat, 4 Jun 2022 17:40:49 +0100 Subject: [PATCH] Add D24X8Unorm depth RT format support --- app/src/main/cpp/skyline/gpu/interconnect/graphics_context.h | 2 ++ app/src/main/cpp/skyline/gpu/texture/format.h | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/app/src/main/cpp/skyline/gpu/interconnect/graphics_context.h b/app/src/main/cpp/skyline/gpu/interconnect/graphics_context.h index 2c398b4b..8e9b99d6 100644 --- a/app/src/main/cpp/skyline/gpu/interconnect/graphics_context.h +++ b/app/src/main/cpp/skyline/gpu/interconnect/graphics_context.h @@ -278,6 +278,8 @@ namespace skyline::gpu::interconnect { return format::D32Float; case MaxwellDepthRtFormat::S8D24Unorm: return format::S8UintD24Unorm; + case MaxwellDepthRtFormat::D24X8Unorm: + return format::D24UnormX8Uint; case MaxwellDepthRtFormat::D24S8Unorm: return format::D24UnormS8Uint; case MaxwellDepthRtFormat::D32S8X24Float: diff --git a/app/src/main/cpp/skyline/gpu/texture/format.h b/app/src/main/cpp/skyline/gpu/texture/format.h index 2776b79d..41f3b98f 100644 --- a/app/src/main/cpp/skyline/gpu/texture/format.h +++ b/app/src/main/cpp/skyline/gpu/texture/format.h @@ -154,6 +154,11 @@ namespace skyline::gpu::format { FORMAT(D32Float, 32, eD32Sfloat, vka::eDepth, .swizzleMapping = { .g = vk::ComponentSwizzle::eR }); + FORMAT(D24UnormX8Uint, 32, eX8D24UnormPack32, .vkAspect = { + vka::eDepth + }, .swizzleMapping = { + .g = vk::ComponentSwizzle::eR + }); FORMAT(D24UnormS8Uint, 32, eD24UnormS8Uint, .vkAspect = { vka::eStencil | vka::eDepth }, .swizzleMapping = {