* Report SDL driver used on GLimp initialisation

This commit is contained in:
Tim Angus 2008-08-03 21:37:51 +00:00
parent 00e790ce00
commit d56c53abb4

View file

@ -412,13 +412,16 @@ static qboolean GLimp_StartDriverAndSetMode( int mode, qboolean fullscreen )
if (!SDL_WasInit(SDL_INIT_VIDEO)) if (!SDL_WasInit(SDL_INIT_VIDEO))
{ {
ri.Printf( PRINT_ALL, "SDL_Init( SDL_INIT_VIDEO )... "); char driverName[ 64 ];
if (SDL_Init(SDL_INIT_VIDEO) == -1) if (SDL_Init(SDL_INIT_VIDEO) == -1)
{ {
ri.Printf( PRINT_ALL, "FAILED (%s)\n", SDL_GetError()); ri.Printf( PRINT_ALL, "SDL_Init FAILED (%s)\n", SDL_GetError());
return qfalse; return qfalse;
} }
ri.Printf( PRINT_ALL, "OK\n");
SDL_VideoDriverName( driverName, sizeof( driverName ) - 1 );
ri.Printf( PRINT_ALL, "SDL using driver \"%s\"\n", driverName );
} }
if (fullscreen && Cvar_VariableIntegerValue( "in_nograb" ) ) if (fullscreen && Cvar_VariableIntegerValue( "in_nograb" ) )