SDL: Add debugging code to output SDL video driver name being used.

This commit is contained in:
D G Turner 2014-02-12 12:05:48 +00:00
parent a4ad32c5d9
commit 2589228329

View file

@ -274,6 +274,14 @@ void OSystem_SDL::initSDL() {
if (SDL_Init(sdlFlags) == -1)
error("Could not initialize SDL: %s", SDL_GetError());
const int maxNameLen = 20;
char sdlDriverName[maxNameLen];
sdlDriverName[0] = '\0';
SDL_VideoDriverName(sdlDriverName, maxNameLen);
// Using printf rather than debug() here as debug()/logging
// is not active by this point.
printf("Using SDL Video Driver \"%s\" ...\n", sdlDriverName);
_initedSDL = true;
}
}