summaryrefslogtreecommitdiff
path: root/src/resources/openglimagehelper.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-07-12 21:35:44 +0300
committerAndrei Karas <akaras@inbox.ru>2014-07-12 21:35:44 +0300
commitd9be27bba8941260500066cdd43ebb016356bc67 (patch)
tree884fa01ee78e6ed9a1c5ea526b1b5cd9e37df24b /src/resources/openglimagehelper.cpp
parent18b2da68d0ae157778bab38d6a90f71e5bb95da2 (diff)
downloadmv-d9be27bba8941260500066cdd43ebb016356bc67.tar.gz
mv-d9be27bba8941260500066cdd43ebb016356bc67.tar.bz2
mv-d9be27bba8941260500066cdd43ebb016356bc67.tar.xz
mv-d9be27bba8941260500066cdd43ebb016356bc67.zip
Add macro for checking OpenGL function is it null or not null.
Diffstat (limited to 'src/resources/openglimagehelper.cpp')
-rw-r--r--src/resources/openglimagehelper.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/resources/openglimagehelper.cpp b/src/resources/openglimagehelper.cpp
index 6187764e9..c830c6321 100644
--- a/src/resources/openglimagehelper.cpp
+++ b/src/resources/openglimagehelper.cpp
@@ -28,6 +28,7 @@
#include "logger.h"
#include "render/mgl.h"
+#include "render/mglcheck.h"
#include "render/mobileopenglgraphics.h"
#include "render/modernopenglgraphics.h"
#include "render/normalopenglgraphics.h"
@@ -276,7 +277,7 @@ Image *OpenGLImageHelper::glLoad(SDL_Surface *tmpImage,
#ifdef DEBUG_OPENGL
// disabled for now, because debugger cant show it
-// if (mglLabelObject)
+// if (isGLNotNull(mglLabelObject))
// {
// const char *const text = "image text";
// mglLabelObject(GL_TEXTURE, texture, strlen(text), text);
@@ -370,7 +371,7 @@ void OpenGLImageHelper::postInit()
void OpenGLImageHelper::invalidate(const GLuint textureId)
{
- if (mglInvalidateTexImage)
+ if (isGLNotNull(mglInvalidateTexImage))
{
logger->log("invalidate: %u", textureId);
mglInvalidateTexImage(textureId, 0);