From 0a87a9b6949b3b23b3dd6989970d0165de233782 Mon Sep 17 00:00:00 2001 From: Miquel Angel Quinones Garcia Date: Tue, 19 Feb 2013 22:17:32 +0100 Subject: [PATCH] [engine]Issue #116: Use debug log tag for warning header --- IndieLib/common/src/IND_SurfaceManager.cpp | 8 ++++---- .../src/render/directx/DirectXTextureBuilder.cpp | 8 ++++---- .../common/src/render/opengl/OpenGLTextureBuilder.cpp | 10 +++++----- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/IndieLib/common/src/IND_SurfaceManager.cpp b/IndieLib/common/src/IND_SurfaceManager.cpp index 43ea7a50..76ee4284 100644 --- a/IndieLib/common/src/IND_SurfaceManager.cpp +++ b/IndieLib/common/src/IND_SurfaceManager.cpp @@ -646,10 +646,10 @@ void IND_SurfaceManager::convertImage(IND_Image* pImage ,IND_Type pType, IND_Qua //Ignore quality specifier (we assume is IND_16) if (IND_ALPHA == pType) { pImage->convert(IND_RGBA, 32); - g_debug->header("Image type converted to IND_RGBA implicitly" , 4); + g_debug->header("Image type converted to IND_RGBA implicitly" , DebugApi::LogHeaderWarning); } else { pImage->convert(IND_RGB, 16); - g_debug->header("Image type converted to IND_RGB implicitly" , 4); + g_debug->header("Image type converted to IND_RGB implicitly" , DebugApi::LogHeaderWarning); } } @@ -681,8 +681,8 @@ void IND_SurfaceManager::convertImage(IND_Image* pImage ,IND_Type pType, IND_Qua } break; default: - g_debug->header("No good Quality specified when creating surface" , 4); - g_debug->header("Image type converted to 32-bit RGB implicitly." , 4); + g_debug->header("No good Quality specified when creating surface" , DebugApi::LogHeaderWarning); + g_debug->header("Image type converted to 32-bit RGB implicitly." , DebugApi::LogHeaderWarning); pImage->convert(pImage->getFormatInt(), 32); break; } diff --git a/IndieLib/common/src/render/directx/DirectXTextureBuilder.cpp b/IndieLib/common/src/render/directx/DirectXTextureBuilder.cpp index 02828f76..53342a6e 100644 --- a/IndieLib/common/src/render/directx/DirectXTextureBuilder.cpp +++ b/IndieLib/common/src/render/directx/DirectXTextureBuilder.cpp @@ -337,13 +337,13 @@ void DirectXTextureBuilder::getSourceAndDestinationFormat(IND_Image *pImage, D3D *pSrcFormat = D3DFMT_R5G6B5; } else { *pSrcFormat = D3DFMT_UNKNOWN; - g_debug->header("Not supported format of image! texture not loaded" , 4); + g_debug->header("Not supported format of image! texture not loaded" , DebugApi::LogHeaderWarning); } } else if (32 == bpp) { *pSrcFormat = D3DFMT_A8B8G8R8; } else { *pSrcFormat = D3DFMT_UNKNOWN; - g_debug->header("The pixel format for the image could not be resolved correctly!" , 4); + g_debug->header("The pixel format for the image could not be resolved correctly!" , DebugApi::LogHeaderWarning); } } break; @@ -354,7 +354,7 @@ void DirectXTextureBuilder::getSourceAndDestinationFormat(IND_Image *pImage, D3D *pSrcFormat = D3DFMT_A8R8G8B8; } else { *pSrcFormat = D3DFMT_UNKNOWN; - g_debug->header("The pixel format for the image could not be resolved correctly!" , 4); + g_debug->header("The pixel format for the image could not be resolved correctly!" , DebugApi::LogHeaderWarning); } } @@ -362,7 +362,7 @@ void DirectXTextureBuilder::getSourceAndDestinationFormat(IND_Image *pImage, D3D //FIXME: IND_LUMINANCE ignored? default: { *pSrcFormat = D3DFMT_UNKNOWN; - g_debug->header("The pixel format for the image could not be resolved correctly!" , 4); + g_debug->header("The pixel format for the image could not be resolved correctly!" , DebugApi::LogHeaderWarning); } } diff --git a/IndieLib/common/src/render/opengl/OpenGLTextureBuilder.cpp b/IndieLib/common/src/render/opengl/OpenGLTextureBuilder.cpp index ad182e06..ffaa991d 100644 --- a/IndieLib/common/src/render/opengl/OpenGLTextureBuilder.cpp +++ b/IndieLib/common/src/render/opengl/OpenGLTextureBuilder.cpp @@ -303,7 +303,7 @@ void OpenGLTextureBuilder::getGLFormat(IND_Surface *pNewSurface, IND_Image* pIma *pGLInternalFormat = GL_NONE; *pGLFormat = GL_NONE; *pGLType = GL_NONE; - g_debug->header("Not supported format of image! texture not loaded" , 4); + g_debug->header("Not supported format of image! texture not loaded" , DebugApi::LogHeaderWarning); } break; @@ -322,7 +322,7 @@ void OpenGLTextureBuilder::getGLFormat(IND_Surface *pNewSurface, IND_Image* pIma *pGLInternalFormat = GL_NONE; *pGLFormat = GL_NONE; *pGLType = GL_NONE; - g_debug->header("Not supported format of image! texture not loaded" , 4); + g_debug->header("Not supported format of image! texture not loaded" , DebugApi::LogHeaderWarning); } } else if (32 == bpp) { //FreeImage loads channel order differently depending on processor endianess (24 and 32 bits). @@ -336,7 +336,7 @@ void OpenGLTextureBuilder::getGLFormat(IND_Surface *pNewSurface, IND_Image* pIma *pGLInternalFormat = GL_NONE; *pGLFormat = GL_NONE; *pGLType = GL_NONE; - g_debug->header("Not supported format of image! texture not loaded" , 4); + g_debug->header("Not supported format of image! texture not loaded" , DebugApi::LogHeaderWarning); } break; case (IND_RGBA): @@ -357,7 +357,7 @@ void OpenGLTextureBuilder::getGLFormat(IND_Surface *pNewSurface, IND_Image* pIma *pGLInternalFormat = GL_NONE; *pGLFormat = GL_NONE; *pGLType = GL_NONE; - g_debug->header("Not supported format of image! texture not loaded" , 4); + g_debug->header("Not supported format of image! texture not loaded" , DebugApi::LogHeaderWarning); } break; @@ -366,7 +366,7 @@ void OpenGLTextureBuilder::getGLFormat(IND_Surface *pNewSurface, IND_Image* pIma *pGLInternalFormat = GL_NONE; *pGLFormat = GL_NONE; *pGLType = GL_NONE; - g_debug->header("Not supported format of image! texture not loaded" , 4); + g_debug->header("Not supported format of image! texture not loaded" , DebugApi::LogHeaderWarning); break; } }