- DALI_LOG_ERROR("Failed to create an atlas of %i x %i blocksize: %i x %i.\n",
- mNewAtlasSize.mWidth,
- mNewAtlasSize.mHeight,
- mNewAtlasSize.mBlockWidth,
- mNewAtlasSize.mBlockHeight );
- return created;
+ foundAtlas = CreateAtlas( mNewAtlasSize, pixelFormat ); // Creating atlas with mNewAtlasSize, may not be the needed size!
+ if ( 0u == foundAtlas )
+ {
+ DALI_LOG_ERROR("Failed to create an atlas of %i x %i blocksize: %i x %i.\n",
+ mNewAtlasSize.mWidth,
+ mNewAtlasSize.mHeight,
+ mNewAtlasSize.mBlockWidth,
+ mNewAtlasSize.mBlockHeight );
+ return false;
+ }
+ else
+ {
+ created = true;
+ }