mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-11-27 01:02:48 +01:00
Presentation: Fix turning FSR on and off in settings
This commit is contained in:
parent
4ad22c7d2b
commit
7506ac4118
1 changed files with 11 additions and 0 deletions
|
@ -362,6 +362,17 @@ void VKBlitScreen::CreateDynamicResources() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void VKBlitScreen::RefreshResources(const Tegra::FramebufferConfig& framebuffer) {
|
void VKBlitScreen::RefreshResources(const Tegra::FramebufferConfig& framebuffer) {
|
||||||
|
if (Settings::values.scaling_filter.GetValue() == Settings::ScalingFilter::Fsr) {
|
||||||
|
if (!fsr) {
|
||||||
|
const auto& layout = render_window.GetFramebufferLayout();
|
||||||
|
fsr = std::make_unique<FSR>(
|
||||||
|
device, memory_allocator, image_count,
|
||||||
|
VkExtent2D{.width = layout.screen.GetWidth(), .height = layout.screen.GetHeight()});
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
fsr.reset();
|
||||||
|
}
|
||||||
|
|
||||||
if (framebuffer.width == raw_width && framebuffer.height == raw_height && !raw_images.empty()) {
|
if (framebuffer.width == raw_width && framebuffer.height == raw_height && !raw_images.empty()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue