Settings: add option to enable / disable reactive flushing

This commit is contained in:
Fernando Sahmkow 2023-05-04 02:34:49 +02:00
parent 0f4f18265f
commit 92da86290c
11 changed files with 38 additions and 5 deletions

View file

@ -26,7 +26,8 @@ ImageViewBase::ImageViewBase(const ImageViewInfo& info, const ImageInfo& image_i
ASSERT_MSG(VideoCore::Surface::IsViewCompatible(image_info.format, info.format, false, true),
"Image view format {} is incompatible with image format {}", info.format,
image_info.format);
if (image_info.forced_flushed) {
const bool preemptive = !Settings::values.use_reactive_flushing.GetValue() && image_info.type == ImageType::Linear;
if (image_info.forced_flushed || preemptive) {
flags |= ImageViewFlagBits::PreemtiveDownload;
}
if (image_info.type == ImageType::e3D && info.type != ImageViewType::e3D) {