From 735a20bc923d0a7bf4b0ca0e4d005413ca8de0f8 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 25 Aug 2013 15:36:23 +0300 Subject: add code for image creation/deletion. --- src/resources/atlasmanager.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/resources/atlasmanager.cpp') diff --git a/src/resources/atlasmanager.cpp b/src/resources/atlasmanager.cpp index a5d7c2ccc..01ea66233 100644 --- a/src/resources/atlasmanager.cpp +++ b/src/resources/atlasmanager.cpp @@ -123,6 +123,9 @@ void AtlasManager::loadImages(const StringVect &files, if (image) { image->mIdPath = str; +#ifdef DEBUG_IMAGES + logger->log("set name %p, %s", image, image->mIdPath.c_str()); +#endif images.push_back(image); } } @@ -268,6 +271,9 @@ void AtlasManager::convertAtlas(TextureAtlas *const atlas) return; image->mIdPath = atlas->name; +#ifdef DEBUG_IMAGES + logger->log("set name %p, %s", image, image->mIdPath.c_str()); +#endif image->incRef(); FOR_EACH (std::vector::iterator, it, atlas->items) @@ -282,6 +288,9 @@ void AtlasManager::convertAtlas(TextureAtlas *const atlas) if (image2) { image2->mIdPath = item->name; +#ifdef DEBUG_IMAGES + logger->log("set name %p, %s", image2, image2->mIdPath.c_str()); +#endif image2->incRef(); } } -- cgit v1.2.3-60-g2f50