From d5f9f4b5204ab212cbe995af0c3305f15563b479 Mon Sep 17 00:00:00 2001 From: GPUCode Date: Sat, 29 Apr 2023 00:33:12 +0300 Subject: [PATCH] rasterizer_cache: Log additional settings --- src/common/settings.cpp | 2 ++ src/video_core/rasterizer_cache/rasterizer_cache.h | 6 ++++-- src/video_core/renderer_opengl/gl_texture_runtime.cpp | 1 + 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/common/settings.cpp b/src/common/settings.cpp index 994655cb9..eea0a6f71 100644 --- a/src/common/settings.cpp +++ b/src/common/settings.cpp @@ -163,6 +163,8 @@ void LogSettings() { log_setting("Layout_LargeScreenProportion", values.large_screen_proportion.GetValue()); log_setting("Utility_DumpTextures", values.dump_textures.GetValue()); log_setting("Utility_CustomTextures", values.custom_textures.GetValue()); + log_setting("Utility_PreloadTextures", values.preload_textures.GetValue()); + log_setting("Utility_AsyncCustomLoading", values.async_custom_loading.GetValue()); log_setting("Utility_UseDiskShaderCache", values.use_disk_shader_cache.GetValue()); log_setting("Audio_Emulation", GetAudioEmulationName(values.audio_emulation.GetValue())); log_setting("Audio_OutputType", values.output_type.GetValue()); diff --git a/src/video_core/rasterizer_cache/rasterizer_cache.h b/src/video_core/rasterizer_cache/rasterizer_cache.h index 32a432cf1..2186515e7 100644 --- a/src/video_core/rasterizer_cache/rasterizer_cache.h +++ b/src/video_core/rasterizer_cache/rasterizer_cache.h @@ -701,10 +701,12 @@ void RasterizerCache::InvalidateFramebuffer(const Framebuffer& framebuffer) { const u32 size = boost::icl::length(interval); InvalidateRegion(addr, size, surface_id); }; - if (framebuffer.HasAttachment(SurfaceType::Color)) { + const bool has_color = framebuffer.HasAttachment(SurfaceType::Color); + const bool has_depth = framebuffer.HasAttachment(SurfaceType::DepthStencil); + if (has_color) { invalidate(render_targets.color_id); } - if (framebuffer.HasAttachment(SurfaceType::DepthStencil)) { + if (has_depth) { invalidate(render_targets.depth_id); } } diff --git a/src/video_core/renderer_opengl/gl_texture_runtime.cpp b/src/video_core/renderer_opengl/gl_texture_runtime.cpp index 8f33edc64..6cefcd060 100644 --- a/src/video_core/renderer_opengl/gl_texture_runtime.cpp +++ b/src/video_core/renderer_opengl/gl_texture_runtime.cpp @@ -240,6 +240,7 @@ bool TextureRuntime::Reinterpret(Surface& source, Surface& dest, const VideoCore::TextureBlit& blit) { const PixelFormat src_format = source.pixel_format; const PixelFormat dst_format = dest.pixel_format; + ASSERT_MSG(src_format != dst_format, "Reinterpretation with the same format is invalid"); if (src_format == PixelFormat::D24S8 && dst_format == PixelFormat::RGBA8) { blit_helper.ConvertDS24S8ToRGBA8(source, dest, blit); } else if (src_format == PixelFormat::RGBA4 && dst_format == PixelFormat::RGB5A1) {