make the BMP load crash have a better explanation message.

This commit is contained in:
AJ Kelly
2012-01-09 13:10:55 -06:00
parent 46524e1b20
commit e9995e7e63
+2 -1
View File
@@ -41,7 +41,6 @@ static RageSurfaceUtils::OpenResult LoadBMP( RageFile &f, RageSurface *&img, RSt
uint32_t iDataOffset = read_u32_le( f, sError );
uint32_t iHeaderSize = read_u32_le( f, sError );
uint32_t iWidth, iHeight, iPlanes, iBPP, iCompression = COMP_BI_RGB, iColors = 0;
if( iHeaderSize == 12 )
{
@@ -100,6 +99,8 @@ static RageSurfaceUtils::OpenResult LoadBMP( RageFile &f, RageSurface *&img, RSt
Gmask = Swap32LE( 0x0000FF00 );
Bmask = Swap32LE( 0x000000FF );
break;
default:
FAIL_M( ssprintf("%iBPP color depth not handled by BMP loader!", iBPP) );
}
if( iCompression == COMP_BI_BITFIELDS )