From 22e43e0f0d16fc207e3d3b7df013c50e0bfb17d7 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 25 Dec 2015 01:48:51 +0300 Subject: Add restrict keyword in openglgraphicsdefadvanced.hpp --- src/render/mobileopengl2graphics.cpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'src/render/mobileopengl2graphics.cpp') diff --git a/src/render/mobileopengl2graphics.cpp b/src/render/mobileopengl2graphics.cpp index 5e05540ad..e3e6b960f 100644 --- a/src/render/mobileopengl2graphics.cpp +++ b/src/render/mobileopengl2graphics.cpp @@ -137,7 +137,7 @@ void MobileOpenGL2Graphics::deleteGLObjects() #endif } -void MobileOpenGL2Graphics::initArrays(const int vertCount) +void MobileOpenGL2Graphics::initArrays(const int vertCount) restrict2 { mMaxVertices = vertCount; if (mMaxVertices < 500) @@ -216,7 +216,7 @@ void MobileOpenGL2Graphics::deleteArrays() restrict2 deleteArraysInternal(); } -void MobileOpenGL2Graphics::deleteArraysInternal() +void MobileOpenGL2Graphics::deleteArraysInternal() restrict2 { delete [] mFloatArray; mFloatArray = nullptr; @@ -580,7 +580,8 @@ void MobileOpenGL2Graphics::drawRescaledPattern(const Image * } inline void MobileOpenGL2Graphics::drawVertexes(const - OpenGLGraphicsVertexes &ogl) + OpenGLGraphicsVertexes & + restrict ogl) restrict2 { const std::vector &vp = ogl.mVp; const std::vector &vbos = ogl.mVbo; @@ -1306,7 +1307,8 @@ void MobileOpenGL2Graphics::drawLineArrays(const int size) } #ifdef DEBUG_BIND_TEXTURE -void MobileOpenGL2Graphics::debugBindTexture(const Image *const image) +void MobileOpenGL2Graphics::debugBindTexture(const Image *restrict const image) + restrict2 { const std::string texture = image->getIdPath(); if (mOldTexture != texture) @@ -1322,7 +1324,8 @@ void MobileOpenGL2Graphics::debugBindTexture(const Image *const image) } } #else -void MobileOpenGL2Graphics::debugBindTexture(const Image *const image A_UNUSED) +void MobileOpenGL2Graphics::debugBindTexture(const Image *restrict const + image A_UNUSED) restrict2 { } #endif -- cgit v1.2.3-70-g09d2