glGetDebugMessageLog

glGetDebugMessageLog: man4/glGetDebugMessageLog.xml

glGetDebugMessageLog retrieves messages from the debug message log. A maximum of count messages are retrieved from the log. If sources is not null then the source of each message is written into up to count elements of the array. If types is not null then the type of each message is written into up to count elements of the array. If id is not null then the identifier of each message is written into up to count elements of the array. If severities is not null then the severity of each message is written into up to count elements of the array. If lengths is not null then the length of each message is written into up to count elements of the array. messageLog specifies the address of a character array into which the debug messages will be written. Each message will be concatenated onto the array starting at the first element of messageLog. bufSize specifies the size of the array messageLog. If a message will not fit into the remaining space in messageLog then the function terminates and returns the number of messages written so far, which may be zero. If glGetDebugMessageLog returns zero then no messages are present in the debug log, or there was not enough space in messageLog to retrieve the first message in the queue. If messageLog is null then no messages are written and the value of bufSize is ignored.

Although debug messages may be enabled in a non-debug context, the quantity and detail of such messages may be substantially inferior to those in a debug context. In particular, a valid implementation of the debug message queue in a non-debug context may produce no messages at all.

@OpenGL_Version(OGLIntroducedIn.V4P3)
@OpenGL_Extension("GL_KHR_debug")
fn_glGetDebugMessageLog glGetDebugMessageLog;

See Also

glDebugMessageInsert, glDebugMessageCallback, glDebugMessageControl.

Meta