Resolve paths before loading images

This commit is contained in:
Glenn Maynard
2003-08-28 19:15:58 +00:00
parent 5dfbd1e0aa
commit 60d6625e33
+3 -2
View File
@@ -82,12 +82,13 @@ void RageBitmapTexture::Create()
/* Create (and return) a surface ready to be loaded to OpenGL */
/* Load the image into an SDL surface. */
SDL_Surface *img = IMG_Load( GetID().filename );
ResolvePath( actualID.filename );
SDL_Surface *img = IMG_Load( actualID.filename );
/* XXX: Wait, we don't want to throw for all images; in particular, we
* want to tolerate corrupt/unknown background images. */
if(img == NULL)
RageException::Throw( "RageBitmapTexture: Couldn't load %s: %s", GetID().filename.c_str(), SDL_GetError() );
RageException::Throw( "RageBitmapTexture: Couldn't load %s: %s", actualID.filename.c_str(), SDL_GetError() );
if(actualID.bHotPinkColorKey)
{