KiCad PCB EDA Suite
|
Go to the source code of this file.
Functions | |
int | checkGlError (const std::string &aInfo, const char *aFile, int aLine, bool aThrow) |
Check if a recent OpenGL operation has failed. | |
static void GLAPIENTRY | debugMsgCallback (GLenum aSource, GLenum aType, GLuint aId, GLenum aSeverity, GLsizei aLength, const GLchar *aMessage, const void *aUserParam) |
void | enableGlDebug (bool aEnable) |
Enable or disable OpenGL driver messages output. | |
Variables | |
static const wxChar *const | traceGalOpenGlError = wxT( "KICAD_GAL_OPENGL_ERROR" ) |
Flag to enable debug output of the GAL OpenGL error checking. | |
int checkGlError | ( | const std::string & | aInfo, |
const char * | aFile, | ||
int | aLine, | ||
bool | aThrow = true |
||
) |
Check if a recent OpenGL operation has failed.
If so, display the appropriate message starting with aInfo string to give more details.
aInfo | is the beginning of the error message. |
aFile | is the file where the error occurred defined by the C FILE variable. |
aLine | is the line in aFile where the error occurred defined by the C LINE variable. |
aThrow | an exception is thrown when true, otherwise only an error message is displayed. |
Definition at line 45 of file utils.cpp.
References DisplayErrorMessage(), and traceGalOpenGlError.
Referenced by KIGFX::OPENGL_GAL::BeginDrawing(), KIGFX::OPENGL_COMPOSITOR::bindFb(), KIGFX::CACHED_CONTAINER_GPU::CACHED_CONTAINER_GPU(), KIGFX::CACHED_CONTAINER_RAM::CACHED_CONTAINER_RAM(), KIGFX::OPENGL_COMPOSITOR::CreateBuffer(), KIGFX::CACHED_CONTAINER_GPU::defragmentResize(), KIGFX::CACHED_CONTAINER_GPU::defragmentResizeMemcpy(), KIGFX::OPENGL_COMPOSITOR::Initialize(), KIGFX::ANTIALIASING_SMAA::loadShaders(), KIGFX::CACHED_CONTAINER_GPU::Map(), KIGFX::ANTIALIASING_SMAA::Present(), KIGFX::OPENGL_COMPOSITOR::SetBuffer(), KIGFX::CACHED_CONTAINER_GPU::Unmap(), KIGFX::CACHED_CONTAINER_RAM::Unmap(), and KIGFX::ANTIALIASING_SMAA::updateUniforms().
|
static |
Definition at line 167 of file utils.cpp.
References traceGalOpenGlError.
Referenced by enableGlDebug().
void enableGlDebug | ( | bool | aEnable | ) |
Enable or disable OpenGL driver messages output.
aEnable | decides whether the message should be shown. |
Definition at line 188 of file utils.cpp.
References debugMsgCallback().
Referenced by KIGFX::OPENGL_GAL::init().