summaryrefslogtreecommitdiffstats
path: root/opengl/libs/EGL/egl_tls.h
diff options
context:
space:
mode:
Diffstat (limited to 'opengl/libs/EGL/egl_tls.h')
-rw-r--r--opengl/libs/EGL/egl_tls.h13
1 files changed, 9 insertions, 4 deletions
diff --git a/opengl/libs/EGL/egl_tls.h b/opengl/libs/EGL/egl_tls.h
index a7989ef..78b0b2f 100644
--- a/opengl/libs/EGL/egl_tls.h
+++ b/opengl/libs/EGL/egl_tls.h
@@ -41,7 +41,8 @@ class egl_tls_t {
egl_tls_t();
static void validateTLSKey();
- static void setErrorEtcImpl(const char* caller, int line, EGLint error);
+ static void setErrorEtcImpl(
+ const char* caller, int line, EGLint error, bool quiet);
public:
static egl_tls_t* getTLS();
@@ -55,13 +56,17 @@ public:
template<typename T>
static T setErrorEtc(const char* caller,
- int line, EGLint error, T returnValue) {
- setErrorEtcImpl(caller, line, error);
+ int line, EGLint error, T returnValue, bool quiet = false) {
+ setErrorEtcImpl(caller, line, error, quiet);
return returnValue;
}
};
-#define setError(_e, _r) egl_tls_t::setErrorEtc(__FUNCTION__, __LINE__, _e, _r)
+#define setError(_e, _r) \
+ egl_tls_t::setErrorEtc(__FUNCTION__, __LINE__, _e, _r)
+
+#define setErrorQuiet(_e, _r) \
+ egl_tls_t::setErrorEtc(__FUNCTION__, __LINE__, _e, _r, true)
// ----------------------------------------------------------------------------