diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-07-17 21:08:56 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-07-17 22:31:22 +0300 |
commit | 932a7f3ca748f04448c72c5d31515bc3a8008144 (patch) | |
tree | cc8f8af7da04d8c1c724dde76c7f6e895293871f /src/graphicsvertexes.cpp | |
parent | 3293fb7b5df3c93b7b6cccf56feb4fa42fd1ea41 (diff) | |
download | manaverse-932a7f3ca748f04448c72c5d31515bc3a8008144.tar.gz manaverse-932a7f3ca748f04448c72c5d31515bc3a8008144.tar.bz2 manaverse-932a7f3ca748f04448c72c5d31515bc3a8008144.tar.xz manaverse-932a7f3ca748f04448c72c5d31515bc3a8008144.zip |
Optimisation in drawing map in opengl mode.
Diffstat (limited to 'src/graphicsvertexes.cpp')
-rw-r--r-- | src/graphicsvertexes.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/graphicsvertexes.cpp b/src/graphicsvertexes.cpp index 7a3077ce3..90a7bbf38 100644 --- a/src/graphicsvertexes.cpp +++ b/src/graphicsvertexes.cpp @@ -43,6 +43,7 @@ SDLGraphicsVertexes::~SDLGraphicsVertexes() #ifdef USE_OPENGL OpenGLGraphicsVertexes::OpenGLGraphicsVertexes() : + ptr(0), mFloatTexArray(0), mIntTexArray(0), mIntVertArray(0) @@ -82,6 +83,13 @@ void OpenGLGraphicsVertexes::clear() mIntTexPool.clear(); mVp.clear(); + if (ptr) + { + ptr = 0; + delete []mFloatTexArray; + delete []mIntTexArray; + delete []mIntVertArray; + } } void OpenGLGraphicsVertexes::init() |