mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-05-14 08:12:16 +00:00
shader_recompiler: Fixups from stencil changes (#1776)
This commit is contained in:
parent
cafd40f2c2
commit
e752f04cde
2 changed files with 3 additions and 2 deletions
|
@ -13,7 +13,7 @@ void Translator::EmitExport(const GcnInst& inst) {
|
||||||
|
|
||||||
const auto& exp = inst.control.exp;
|
const auto& exp = inst.control.exp;
|
||||||
const IR::Attribute attrib{exp.target};
|
const IR::Attribute attrib{exp.target};
|
||||||
if (attrib == IR::Attribute::Depth && exp.en != 1) {
|
if (attrib == IR::Attribute::Depth && exp.en != 0 && exp.en != 1) {
|
||||||
LOG_WARNING(Render_Vulkan, "Unsupported depth export");
|
LOG_WARNING(Render_Vulkan, "Unsupported depth export");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
@ -131,7 +131,8 @@ ImageView::ImageView(const Vulkan::Instance& instance, const ImageViewInfo& info
|
||||||
format = image.info.pixel_format;
|
format = image.info.pixel_format;
|
||||||
aspect = vk::ImageAspectFlagBits::eDepth;
|
aspect = vk::ImageAspectFlagBits::eDepth;
|
||||||
}
|
}
|
||||||
if (image.aspect_mask & vk::ImageAspectFlagBits::eStencil && format == vk::Format::eR8Uint) {
|
if (image.aspect_mask & vk::ImageAspectFlagBits::eStencil &&
|
||||||
|
(format == vk::Format::eR8Uint || format == vk::Format::eR8Unorm)) {
|
||||||
format = image.info.pixel_format;
|
format = image.info.pixel_format;
|
||||||
aspect = vk::ImageAspectFlagBits::eStencil;
|
aspect = vk::ImageAspectFlagBits::eStencil;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue