From fc641a450b92712dfec2cf8f17e5a65cae0e79d5 Mon Sep 17 00:00:00 2001 From: wheremyfoodat <44909372+wheremyfoodat@users.noreply.github.com> Date: Sat, 12 Aug 2023 18:25:49 +0300 Subject: [PATCH] Add a shut up counter to GL::TextureCopy --- src/core/renderer_gl/renderer_gl.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/core/renderer_gl/renderer_gl.cpp b/src/core/renderer_gl/renderer_gl.cpp index 4535c9e2..3eb36de5 100644 --- a/src/core/renderer_gl/renderer_gl.cpp +++ b/src/core/renderer_gl/renderer_gl.cpp @@ -667,7 +667,7 @@ void RendererGL::textureCopy(u32 inputAddr, u32 outputAddr, u32 totalBytes, u32 inputAddr, outputAddr, totalBytes, inputWidth, inputGap, outputWidth, outputGap); if (inputGap != 0 || outputGap != 0) { - //Helpers::warn("Strided texture copy\n"); + // Helpers::warn("Strided texture copy\n"); } if (inputWidth != outputWidth) { Helpers::warn("Input width does not match output width, cannot accelerate texture copy!"); @@ -695,7 +695,12 @@ void RendererGL::textureCopy(u32 inputAddr, u32 outputAddr, u32 totalBytes, u32 // Find the source surface. auto srcFramebuffer = getColourBuffer(inputAddr, PICA::ColorFmt::RGBA8, copyStride, copyHeight, false); if (!srcFramebuffer) { - printf("TextureCopy failed to locate src framebuffer!\n"); + static int shutUpCounter = 0; // Don't want to spam the console too much, so shut up after 5 times + + if (shutUpCounter < 5) { + shutUpCounter++; + printf("RendererGL::TextureCopy failed to locate src framebuffer!\n"); + } return; }