diff --git a/include/GLDebug.h b/include/GLDebug.h index eb13bfc..6f02079 100644 --- a/include/GLDebug.h +++ b/include/GLDebug.h @@ -92,6 +92,11 @@ openglDebugCallback(GLenum source, if (id == 131185) return; +#ifdef TANGERINE_GL_DEBUG_QUIET + if (type != GL_DEBUG_TYPE_ERROR) + return; +#endif + std::cout << "message id: " << id << ", " << ((type == GL_DEBUG_TYPE_ERROR) ? "Error" : "Debug") << (type == GL_DEBUG_TYPE_ERROR ? "** GL Error **" : "") diff --git a/include/tangerine.h b/include/tangerine.h index 7eb2570..34527ef 100644 --- a/include/tangerine.h +++ b/include/tangerine.h @@ -86,6 +86,13 @@ #include "util.h" +// NOTE: can set TANGERINE_GL_DEBUG_QUIET in your application to disable extra +// debug messages from openGL +#ifndef TANGERINE_GL_DEBUG_QUIET + #define TANGERINE_GL_DEBUG_NOISY +#endif + + struct SDLHandles { SDL_Window* window; @@ -94,9 +101,6 @@ struct SDLHandles u32 SDL_flags; }; -// TODO: node/tree structure for entities -struct Node; - struct RenderGroup { ShaderProgram* shader; @@ -106,7 +110,10 @@ struct RenderGroup char* name; }; +// TODO: node/tree structure for entities #if 0 +struct Node; + struct Scene { MemoryArena* rg_arena;