make the BMP load crash have a better explanation message.
This commit is contained in:
@@ -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 )
|
||||
|
||||
Reference in New Issue
Block a user