diff --git a/src/video_core/rasterizer_cache/rasterizer_cache.h b/src/video_core/rasterizer_cache/rasterizer_cache.h index f46e5ef9b..020f5017d 100644 --- a/src/video_core/rasterizer_cache/rasterizer_cache.h +++ b/src/video_core/rasterizer_cache/rasterizer_cache.h @@ -278,9 +278,9 @@ bool RasterizerCache::BlitSurfaces(const Surface& src_surface, Common::Rectan dst_surface->InvalidateAllWatcher(); - // Prefer texture copy over blit if possible. This is possible when the following is true: - // 1. No scaling (the dimentions of src and dest rect are the same - // 2. No flipping (if the bottom value is bigger than the top this indicates texture flip + // Prefer texture copy over blit when possible. This can happen when the following is true: + // 1. No scaling (the dimentions of src and dest rect are the same) + // 2. No flipping (if the bottom value is bigger than the top this indicates texture flip) if (src_rect.GetWidth() == dst_rect.GetWidth() && src_rect.GetHeight() == dst_rect.GetHeight() && src_rect.bottom < src_rect.top) { diff --git a/src/video_core/renderer_opengl/gl_driver.cpp b/src/video_core/renderer_opengl/gl_driver.cpp index 14d6c7064..f7584957b 100644 --- a/src/video_core/renderer_opengl/gl_driver.cpp +++ b/src/video_core/renderer_opengl/gl_driver.cpp @@ -79,10 +79,8 @@ Driver::Driver(bool gles, bool enable_debug) : is_gles{gles} { * Qualcomm has some spammy info messages that are marked as errors but not important * https://developer.qualcomm.com/comment/11845 */ - if (enable_debug) { - glEnable(GL_DEBUG_OUTPUT_SYNCHRONOUS); - glDebugMessageCallback(DebugHandler, nullptr); - } + glEnable(GL_DEBUG_OUTPUT_SYNCHRONOUS); + glDebugMessageCallback(DebugHandler, nullptr); #endif ReportDriverInfo(); diff --git a/src/video_core/renderer_opengl/gl_texture_runtime.cpp b/src/video_core/renderer_opengl/gl_texture_runtime.cpp index 0f565913f..a6bd52ab8 100644 --- a/src/video_core/renderer_opengl/gl_texture_runtime.cpp +++ b/src/video_core/renderer_opengl/gl_texture_runtime.cpp @@ -243,7 +243,19 @@ bool TextureRuntime::ClearTexture(Surface& surface, const VideoCore::TextureClea } bool TextureRuntime::CopyTextures(Surface& source, Surface& dest, const VideoCore::TextureCopy& copy) { - return true; + // Emulate texture copy with blit for now + const VideoCore::TextureBlit blit = { + .src_level = copy.src_level, + .dst_level = copy.dst_level, + .src_layer = copy.src_layer, + .dst_layer = copy.dst_layer, + .src_rect = {copy.src_offset.x, copy.extent.height, + copy.extent.width, copy.src_offset.x}, + .dst_rect = {copy.dst_offset.x, copy.extent.height, + copy.extent.width, copy.dst_offset.x} + }; + + return BlitTextures(source, dest, blit); } bool TextureRuntime::BlitTextures(Surface& source, Surface& dest, const VideoCore::TextureBlit& blit) {