diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-08-26 16:09:58 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-08-26 16:52:08 +0300 |
commit | 929aeb1591e739588cd8cf629e7d7ac5a95261b1 (patch) | |
tree | 2b61b477d0e0ffed31a90ba2d6c019da926282aa /src/resources/atlasmanager.cpp | |
parent | b661524e8b7b41cec237492ecd52fdda7b9be394 (diff) | |
download | manaverse-929aeb1591e739588cd8cf629e7d7ac5a95261b1.tar.gz manaverse-929aeb1591e739588cd8cf629e7d7ac5a95261b1.tar.bz2 manaverse-929aeb1591e739588cd8cf629e7d7ac5a95261b1.tar.xz manaverse-929aeb1591e739588cd8cf629e7d7ac5a95261b1.zip |
add surface allocation debug code.
Diffstat (limited to 'src/resources/atlasmanager.cpp')
-rw-r--r-- | src/resources/atlasmanager.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/resources/atlasmanager.cpp b/src/resources/atlasmanager.cpp index 01ea66233..80b0ad253 100644 --- a/src/resources/atlasmanager.cpp +++ b/src/resources/atlasmanager.cpp @@ -31,6 +31,7 @@ #include "utils/mathutils.h" #include "utils/physfsrwops.h" +#include "utils/sdlcheckutils.h" #include "resources/dye.h" #include "resources/fboinfo.h" @@ -79,7 +80,7 @@ AtlasResource *AtlasManager::loadTextureAtlas(const std::string &name, convertAtlas(atlas); // free SDL atlas surface - SDL_FreeSurface(surface); + MSDL_FreeSurface(surface); resource->atlases.push_back(atlas); } @@ -226,7 +227,7 @@ SDL_Surface *AtlasManager::createSDLAtlas(TextureAtlas *const atlas) const int width = atlas->width; const int height = atlas->height; // temp SDL surface for atlas - SDL_Surface *const surface = SDL_CreateRGBSurface(SDL_SWSURFACE, + SDL_Surface *const surface = MSDL_CreateRGBSurface(SDL_SWSURFACE, width, height, 32, rmask, gmask, bmask, amask); if (!surface) return nullptr; |