summaryrefslogtreecommitdiffstats
path: root/src/video_core/texture_cache
diff options
context:
space:
mode:
authorLiam <byteslice@airmail.cc>2024-01-22 18:40:50 +0100
committerLiam <byteslice@airmail.cc>2024-02-09 15:20:53 +0100
commit962c82540c304f909957776908aabcd261f2a7ba (patch)
tree707ab34565e8309b5ede21acebf36975da7718e7 /src/video_core/texture_cache
parentnvservices: unmap only on last container free (diff)
downloadyuzu-962c82540c304f909957776908aabcd261f2a7ba.tar
yuzu-962c82540c304f909957776908aabcd261f2a7ba.tar.gz
yuzu-962c82540c304f909957776908aabcd261f2a7ba.tar.bz2
yuzu-962c82540c304f909957776908aabcd261f2a7ba.tar.lz
yuzu-962c82540c304f909957776908aabcd261f2a7ba.tar.xz
yuzu-962c82540c304f909957776908aabcd261f2a7ba.tar.zst
yuzu-962c82540c304f909957776908aabcd261f2a7ba.zip
Diffstat (limited to 'src/video_core/texture_cache')
-rw-r--r--src/video_core/texture_cache/texture_cache.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/video_core/texture_cache/texture_cache.h b/src/video_core/texture_cache/texture_cache.h
index a20c956ff..3a1cc060e 100644
--- a/src/video_core/texture_cache/texture_cache.h
+++ b/src/video_core/texture_cache/texture_cache.h
@@ -746,7 +746,13 @@ std::pair<typename P::ImageView*, bool> TextureCache<P>::TryFindFramebufferImage
}();
const auto GetImageViewForFramebuffer = [&](ImageId image_id) {
- const ImageViewInfo info{ImageViewType::e2D, view_format};
+ ImageViewInfo info{ImageViewType::e2D, view_format};
+ if (config.blending == Tegra::BlendMode::Opaque) {
+ info.x_source = static_cast<u8>(SwizzleSource::R);
+ info.y_source = static_cast<u8>(SwizzleSource::G);
+ info.z_source = static_cast<u8>(SwizzleSource::B);
+ info.w_source = static_cast<u8>(SwizzleSource::OneFloat);
+ }
return std::make_pair(&slot_image_views[FindOrEmplaceImageView(image_id, info)],
slot_images[image_id].IsRescaled());
};