From 3a90f93507a344d2b6eb3ae631371348ff977047 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Foucault?= Date: Sat, 5 Feb 2022 23:07:53 +0100 Subject: GPU: Debug: Avoid double printing of compilation issues To avoid that, we simply filter using a debug group. --- source/blender/gpu/opengl/gl_debug.cc | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source/blender/gpu/opengl') diff --git a/source/blender/gpu/opengl/gl_debug.cc b/source/blender/gpu/opengl/gl_debug.cc index 4b78f20824b..fe558677f56 100644 --- a/source/blender/gpu/opengl/gl_debug.cc +++ b/source/blender/gpu/opengl/gl_debug.cc @@ -108,6 +108,11 @@ static void APIENTRY debug_callback(GLenum UNUSED(source), GPU_debug_get_groups_names(sizeof(debug_groups), debug_groups); CLG_Severity clog_severity; + if (GPU_debug_group_match(GPU_DEBUG_SHADER_COMPILATION_GROUP)) { + /** Do not duplicate shader compilation error/warnings. */ + return; + } + switch (type) { case GL_DEBUG_TYPE_ERROR: case GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR: -- cgit v1.2.3