Fix linking issues
This commit is contained in:
@@ -80,10 +80,13 @@ TFB_InitGraphics (int driver, int flags, int width, int height)
|
|||||||
result = TFB_Pure_InitGraphics (driver, flags, width, height);
|
result = TFB_Pure_InitGraphics (driver, flags, width, height);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if SDL_MAJOR_VERSION == 1
|
||||||
|
/* Other versions do this when setting up the window */
|
||||||
sprintf (caption, "The Ur-Quan Masters v%d.%d.%d%s",
|
sprintf (caption, "The Ur-Quan Masters v%d.%d.%d%s",
|
||||||
UQM_MAJOR_VERSION, UQM_MINOR_VERSION,
|
UQM_MAJOR_VERSION, UQM_MINOR_VERSION,
|
||||||
UQM_PATCH_VERSION, UQM_EXTRA_VERSION);
|
UQM_PATCH_VERSION, UQM_EXTRA_VERSION);
|
||||||
SDL_WM_SetCaption (caption, NULL);
|
SDL_WM_SetCaption (caption, NULL);
|
||||||
|
#endif
|
||||||
|
|
||||||
if (flags & TFB_GFXFLAGS_FULLSCREEN)
|
if (flags & TFB_GFXFLAGS_FULLSCREEN)
|
||||||
SDL_ShowCursor (SDL_DISABLE);
|
SDL_ShowCursor (SDL_DISABLE);
|
||||||
|
|||||||
@@ -98,7 +98,6 @@ sint32
|
|||||||
mixSDL_Init (audio_Driver *driver, sint32 flags)
|
mixSDL_Init (audio_Driver *driver, sint32 flags)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
char devicename[256];
|
|
||||||
SDL_AudioSpec desired, obtained;
|
SDL_AudioSpec desired, obtained;
|
||||||
mixer_Quality quality;
|
mixer_Quality quality;
|
||||||
TFB_DecoderFormats formats =
|
TFB_DecoderFormats formats =
|
||||||
@@ -162,12 +161,19 @@ mixSDL_Init (audio_Driver *driver, sint32 flags)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
SDL_AudioDriverName (devicename, sizeof (devicename));
|
{
|
||||||
log_add (log_Info, " using %s at %d Hz 16 bit %s, "
|
#if SDL_MAJOR_VERSION == 1
|
||||||
"%d samples audio buffer",
|
char devicename[256];
|
||||||
devicename, obtained.freq,
|
SDL_AudioDriverName (devicename, sizeof (devicename));
|
||||||
obtained.channels > 1 ? "stereo" : "mono",
|
#else
|
||||||
obtained.samples);
|
const char *devicename = SDL_GetCurrentAudioDriver ();
|
||||||
|
#endif
|
||||||
|
log_add (log_Info, " using %s at %d Hz 16 bit %s, "
|
||||||
|
"%d samples audio buffer",
|
||||||
|
devicename, obtained.freq,
|
||||||
|
obtained.channels > 1 ? "stereo" : "mono",
|
||||||
|
obtained.samples);
|
||||||
|
}
|
||||||
|
|
||||||
log_add (log_Info, "Initializing mixer.");
|
log_add (log_Info, "Initializing mixer.");
|
||||||
if (!mixer_Init (obtained.freq, MIX_FORMAT_MAKE (2, obtained.channels),
|
if (!mixer_Init (obtained.freq, MIX_FORMAT_MAKE (2, obtained.channels),
|
||||||
|
|||||||
Reference in New Issue
Block a user