summaryrefslogtreecommitdiffhomepage
path: root/src/rlgl.c
diff options
context:
space:
mode:
authoruser <email>2017-12-14 11:44:48 +0100
committeruser <email>2017-12-14 11:44:48 +0100
commit0e18b146055efd18029c4ac5553fd1e53dfbbfc8 (patch)
treee43d13b1c3e0a5e56351f396e95b5437d3176e64 /src/rlgl.c
parent963551ee6e99e069fca8eed47151f4caf628507e (diff)
downloadraylib-0e18b146055efd18029c4ac5553fd1e53dfbbfc8.tar.gz
raylib-0e18b146055efd18029c4ac5553fd1e53dfbbfc8.zip
added debug-event-markers for opengl so that you're able to set markers for renderdoc or other gpu debuggers what your program is currently doing
Diffstat (limited to 'src/rlgl.c')
-rw-r--r--src/rlgl.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/rlgl.c b/src/rlgl.c
index 5db6f1cc..e34e48da 100644
--- a/src/rlgl.c
+++ b/src/rlgl.c
@@ -307,6 +307,8 @@ static PFNGLDELETEVERTEXARRAYSOESPROC glDeleteVertexArrays;
//static PFNGLISVERTEXARRAYOESPROC glIsVertexArray; // NOTE: Fails in WebGL, omitted
#endif
+static bool debugMarkerSupported = false;
+
// Compressed textures support flags
static bool texCompDXTSupported = false; // DDS texture compression support
static bool texNPOTSupported = false; // NPOT textures full support
@@ -1135,6 +1137,10 @@ void rlglInit(int width, int height)
glGetFloatv(0x84FF, &maxAnisotropicLevel); // GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT
}
+ if(strcmp(extList[i], (const char *)"GL_EXT_debug_marker") == 0) {
+ debugMarkerSupported = true;
+ }
+
// Clamp mirror wrap mode supported
if (strcmp(extList[i], (const char *)"GL_EXT_texture_mirror_clamp") == 0) texClampMirrorSupported = true;
}
@@ -1160,6 +1166,8 @@ void rlglInit(int width, int height)
if (texAnisotropicFilterSupported) TraceLog(LOG_INFO, "[EXTENSION] Anisotropic textures filtering supported (max: %.0fX)", maxAnisotropicLevel);
if (texClampMirrorSupported) TraceLog(LOG_INFO, "[EXTENSION] Clamp mirror wrap texture mode supported");
+ if (debugMarkerSupported) TraceLog(LOG_INFO, "[EXTENSION] Debug Marker supported");
+
// Initialize buffers, default shaders and default textures
//----------------------------------------------------------