From 72812a7b47f90f9460e54e8149ba9199a7841244 Mon Sep 17 00:00:00 2001 From: chai Date: Tue, 2 Nov 2021 19:44:01 +0800 Subject: ! Text mesh done --- Runtime/Graphics/OpenGL.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'Runtime/Graphics/OpenGL.h') diff --git a/Runtime/Graphics/OpenGL.h b/Runtime/Graphics/OpenGL.h index b1b777e..d93fb5a 100644 --- a/Runtime/Graphics/OpenGL.h +++ b/Runtime/Graphics/OpenGL.h @@ -15,6 +15,14 @@ if(true){ \ } \ } +#define WipeGLError() \ +if(true){\ + GLenum error; \ + while ((error = glGetError()) != GL_NO_ERROR) { \ + throw GLException(error); \ + } \ +} + extern std::string g_sharedGLErrorMsg; class GLException : public std::exception -- cgit v1.1-26-g67d0