QOpenGLDebugMessage Class

The QOpenGLDebugMessage class wraps an OpenGL debug message. More...

Header: #include <QOpenGLDebugMessage>
qmake: QT += gui
Since: Qt 5.1

This class was introduced in Qt 5.1.

Note: All functions in this class are reentrant.

Public Types

enum Severity { InvalidSeverity, HighSeverity, MediumSeverity, LowSeverity, NotificationSeverity, AnySeverity }
enum Source { InvalidSource, APISource, WindowSystemSource, ShaderCompilerSource, ThirdPartySource, …, AnySource }
enum Type { InvalidType, ErrorType, DeprecatedBehaviorType, UndefinedBehaviorType, PortabilityType, …, AnyType }

Detailed Description

Debug messages are usually created by the OpenGL server and then read by OpenGL clients (either from the OpenGL internal debug log, or logged in real-time). A debug message has a textual representation, a vendor-specific numeric id, a source, a type and a severity.

It's also possible for applications or third-party libraries and toolkits to create and insert messages in the debug log. In order to do so, you can use the createApplicationMessage() or the createThirdPartyMessage() static functions.

See also QOpenGLDebugLogger.

Member Type Documentation

enum QOpenGLDebugMessage::Severity

The Severity enum defines the severity of the debug message.

ConstantValueDescription
QOpenGLDebugMessage::InvalidSeverity0x00000000The severity of the message is invalid; this is the severity of a default-constructed QOpenGLDebugMessage object.
QOpenGLDebugMessage::HighSeverity0x00000001The message has a high severity.
QOpenGLDebugMessage::MediumSeverity0x00000002The message has a medium severity.
QOpenGLDebugMessage::LowSeverity0x00000004The message has a low severity.
QOpenGLDebugMessage::NotificationSeverity0x00000008The message is a notification.
QOpenGLDebugMessage::AnySeverity0xffffffffThis value corresponds to a mask of all possible message severities.

enum QOpenGLDebugMessage::Source

The Source enum defines the source of the debug message.

ConstantValueDescription
QOpenGLDebugMessage::InvalidSource0x00000000The source of the message is invalid; this is the source of a default-constructed QOpenGLDebugMessage object.
QOpenGLDebugMessage::APISource0x00000001The message was generated in response to OpenGL API calls.
QOpenGLDebugMessage::WindowSystemSource0x00000002The message was generated by the window system.
QOpenGLDebugMessage::ShaderCompilerSource0x00000004The message was generated by the shader compiler.
QOpenGLDebugMessage::ThirdPartySource0x00000008The message was generated by a third party, for instance an OpenGL framework a or debugging toolkit.
QOpenGLDebugMessage::ApplicationSource0x00000010The message was generated by the application itself.
QOpenGLDebugMessage::OtherSource0x00000020The message was generated by a source not included in this enumeration.
QOpenGLDebugMessage::AnySource0xffffffffThis value corresponds to a mask of all possible message sources.

enum QOpenGLDebugMessage::Type

The Type enum defines the type of the debug message.

ConstantValueDescription
QOpenGLDebugMessage::InvalidType0x00000000The type of the message is invalid; this is the type of a default-constructed QOpenGLDebugMessage object.
QOpenGLDebugMessage::ErrorType0x00000001The message represents an error.
QOpenGLDebugMessage::DeprecatedBehaviorType0x00000002The message represents an usage of deprecated behavior.
QOpenGLDebugMessage::UndefinedBehaviorType0x00000004The message represents an usage of undefined behavior.
QOpenGLDebugMessage::PortabilityType0x00000008The message represents an usage of vendor-specific behavior, that might pose portability concerns.
QOpenGLDebugMessage::PerformanceType0x00000010The message represents a performance issue.
QOpenGLDebugMessage::OtherType0x00000020The message represents a type not included in this enumeration.
QOpenGLDebugMessage::MarkerType0x00000040The message represents a marker in the debug log.
QOpenGLDebugMessage::GroupPushType0x00000080The message represents a debug group push operation.
QOpenGLDebugMessage::GroupPopType0x00000100The message represents a debug group pop operation.
QOpenGLDebugMessage::AnyType0xffffffffThis value corresponds to a mask of all possible message types.