mirror of
				https://git.suyu.dev/suyu/suyu
				synced 2025-11-03 16:39:01 -06:00 
			
		
		
		
	renderer_opengl: Only enable DEBUG_OUTPUT when graphics debugging is enabled
Avoids logging when it's not relevant. This can potentially reduce driver's internal thread overhead.
This commit is contained in:
		@@ -751,11 +751,9 @@ void RendererOpenGL::RenderScreenshot() {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
bool RendererOpenGL::Init() {
 | 
			
		||||
    if (GLAD_GL_KHR_debug) {
 | 
			
		||||
    if (Settings::values.renderer_debug && GLAD_GL_KHR_debug) {
 | 
			
		||||
        glEnable(GL_DEBUG_OUTPUT);
 | 
			
		||||
        if (Settings::values.renderer_debug) {
 | 
			
		||||
            glEnable(GL_DEBUG_OUTPUT_SYNCHRONOUS);
 | 
			
		||||
        }
 | 
			
		||||
        glEnable(GL_DEBUG_OUTPUT_SYNCHRONOUS);
 | 
			
		||||
        glDebugMessageCallback(DebugHandler, nullptr);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user