video_core: Adjust depth format

This commit is contained in:
IndecisiveTurtle 2024-09-03 20:37:28 +03:00
parent e6325d2327
commit cb66b92854
2 changed files with 3 additions and 3 deletions

View file

@ -179,8 +179,7 @@ const ComputePipeline* PipelineCache::GetComputePipeline() {
}
bool ShouldSkipShader(u64 shader_hash, const char* shader_type) {
static constexpr std::array<u64, 7> skip_hashes = {
0x42f2a521, 0x2da7fe60, 0x8e3f8dc4, 0xa509af23, 0x4ca76892, 0xa954e79d, 0x1635154c};
static constexpr std::array<u64, 0> skip_hashes = {};
if (std::ranges::contains(skip_hashes, shader_hash)) {
LOG_WARNING(Render_Vulkan, "Skipped {} shader hash {:#x}.", shader_type, shader_hash);
return true;

View file

@ -123,7 +123,8 @@ ImageView::ImageView(const Vulkan::Instance& instance, const ImageViewInfo& info
// When sampling D32 texture from shader, the T# specifies R32 Float format so adjust it.
vk::Format format = info.format;
vk::ImageAspectFlags aspect = image.aspect_mask;
if (image.aspect_mask & vk::ImageAspectFlagBits::eDepth && format == vk::Format::eR32Sfloat) {
if (image.aspect_mask & vk::ImageAspectFlagBits::eDepth &&
(format == vk::Format::eR32Sfloat || format == vk::Format::eD32Sfloat)) {
format = image.info.pixel_format;
aspect = vk::ImageAspectFlagBits::eDepth;
}