summaryrefslogtreecommitdiff
path: root/src/graphicsmanager.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-12-08 21:48:20 +0300
committerAndrei Karas <akaras@inbox.ru>2015-12-11 18:15:54 +0300
commit5f23fe21b29083922dab55feb33258f3f855ca9e (patch)
tree09637f98663093435066a6436b931612c4a53d82 /src/graphicsmanager.cpp
parent167fe73b9dde166cc84927262cdd8c20ed2f4ac4 (diff)
downloadmv-5f23fe21b29083922dab55feb33258f3f855ca9e.tar.gz
mv-5f23fe21b29083922dab55feb33258f3f855ca9e.tar.bz2
mv-5f23fe21b29083922dab55feb33258f3f855ca9e.tar.xz
mv-5f23fe21b29083922dab55feb33258f3f855ca9e.zip
Add nacl gl init and nacl defines and includes in most files.
Diffstat (limited to 'src/graphicsmanager.cpp')
-rw-r--r--src/graphicsmanager.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/graphicsmanager.cpp b/src/graphicsmanager.cpp
index 70c4346bf..83be30964 100644
--- a/src/graphicsmanager.cpp
+++ b/src/graphicsmanager.cpp
@@ -33,6 +33,7 @@
#endif // USE_SDL2
#elif defined(__native_client__)
#include <GL/Regal.h>
+#include "render/naclgles.h"
#else // ANDROID
#include <GL/glx.h>
#endif // ANDROID
@@ -893,6 +894,10 @@ void GraphicsManager::deleteFBO(FBOInfo *const fbo)
void GraphicsManager::initOpenGLFunctions()
{
+#ifdef __native_client__
+ NaclGles::initGles();
+ emulateFunction(glTextureSubImage2D);
+#else
const bool is10 = checkGLVersion(1, 0);
const bool is11 = checkGLVersion(1, 1);
const bool is12 = checkGLVersion(1, 2);
@@ -1263,6 +1268,7 @@ void GraphicsManager::initOpenGLFunctions()
#ifdef WIN32
assignFunctionARB(wglGetExtensionsString);
#endif
+#endif
}
void GraphicsManager::updateLimits()