summaryrefslogtreecommitdiff
path: root/src/render/mobileopengl2graphics.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-12-10 16:45:36 +0300
committerAndrei Karas <akaras@inbox.ru>2015-12-10 16:45:36 +0300
commit18808109d12835d18d9d1ada96ed394a082a7740 (patch)
tree605807d7d6b2c240a41307f457693346ae39c9ed /src/render/mobileopengl2graphics.cpp
parent57c4153a8ba211741b5f8fa87f262eefd3a837e9 (diff)
downloadmanaplus-18808109d12835d18d9d1ada96ed394a082a7740.tar.gz
manaplus-18808109d12835d18d9d1ada96ed394a082a7740.tar.bz2
manaplus-18808109d12835d18d9d1ada96ed394a082a7740.tar.xz
manaplus-18808109d12835d18d9d1ada96ed394a082a7740.zip
Dont use VAO in mobileopengl2graphics in nacl.
Diffstat (limited to 'src/render/mobileopengl2graphics.cpp')
-rw-r--r--src/render/mobileopengl2graphics.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/render/mobileopengl2graphics.cpp b/src/render/mobileopengl2graphics.cpp
index 6cb88c34d..8a07dc9a2 100644
--- a/src/render/mobileopengl2graphics.cpp
+++ b/src/render/mobileopengl2graphics.cpp
@@ -95,7 +95,9 @@ MobileOpenGL2Graphics::MobileOpenGL2Graphics() :
mTextureColorUniform(0U),
mScreenUniform(0U),
mDrawTypeUniform(0U),
+#ifndef __native_client__
mVao(0U),
+#endif
mVbo(0U),
mVboBinded(0U),
mAttributesBinded(0U),
@@ -125,8 +127,10 @@ void MobileOpenGL2Graphics::deleteGLObjects()
// logger->log("delete buffer vbo: %u", mVbo);
mglDeleteBuffers(1, &mVbo);
}
+#ifndef __native_client__
if (mVao)
mglDeleteVertexArrays(1, &mVao);
+#endif
}
void MobileOpenGL2Graphics::initArrays(const int vertCount)
@@ -148,8 +152,10 @@ void MobileOpenGL2Graphics::initArrays(const int vertCount)
void MobileOpenGL2Graphics::postInit()
{
+#ifndef __native_client__
mglGenVertexArrays(1, &mVao);
mglBindVertexArray(mVao);
+#endif
mglGenBuffers(1, &mVbo);
// logger->log("gen vbo buffer: %u", mVbo);
bindArrayBuffer(mVbo);