int sound_local = base + nr;
#if 0
- printf("::: %d, %d, %d: %d ['%s'], %d ['%s']\n",
- nr, initial, is_image,
- sound_global, getSoundListEntry(sound_global)->filename,
- sound_local, getSoundListEntry(sound_local)->filename);
+ Debug("screens:getTitleSound", "%d, %d, %d: %d ['%s'], %d ['%s']",
+ nr, initial, is_image,
+ sound_global, getSoundListEntry(sound_global)->filename,
+ sound_local, getSoundListEntry(sound_local)->filename);
#endif
if (!strEqual(getSoundListEntry(sound_local)->filename, UNDEFINED_FILENAME))
int music_local = base + nr;
#if 0
- printf("::: %d, %d, %d: %d ['%s'], %d ['%s']\n",
- nr, initial, is_image,
- music_global, getMusicListEntry(music_global)->filename,
- music_local, getMusicListEntry(music_local)->filename);
+ Debug("screens:getTitleMusic", "%d, %d, %d: %d ['%s'], %d ['%s']",
+ nr, initial, is_image,
+ music_global, getMusicListEntry(music_global)->filename,
+ music_local, getMusicListEntry(music_local)->filename);
#endif
if (!strEqual(getMusicListEntry(music_local)->filename, UNDEFINED_FILENAME))
int rect_y = ALIGNED_TEXT_YPOS(rect);
#if 0
- printf("::: insideTextPosRect: (%d, %d), (%d, %d) [%d, %d] (%d, %d) => %d\n",
- x, y, rect_x, rect_y, rect->x, rect->y, rect->width, rect->height,
- (x >= rect_x && x < rect_x + rect->width &&
- y >= rect_y && y < rect_y + rect->height));
+ Debug("screens:insideTextPosRect",
+ "(%d, %d), (%d, %d) [%d, %d] (%d, %d) => %d",
+ x, y, rect_x, rect_y, rect->x, rect->y, rect->width, rect->height,
+ (x >= rect_x && x < rect_x + rect->width &&
+ y >= rect_y && y < rect_y + rect->height));
#endif
return (x >= rect_x && x < rect_x + rect->width &&
// screen rendering mode may have changed at this point
SDLSetScreenRenderingMode(setup.screen_rendering_mode);
+ int setup_vsync_mode = VSYNC_MODE_STR_TO_INT(setup.vsync_mode);
+ int video_vsync_mode = video.vsync_mode;
+
// screen vsync mode may have changed at this point
ChangeVsyncModeIfNeeded();
+
+ // check if setting vsync mode to selected value failed
+ if (setup_vsync_mode != video_vsync_mode &&
+ setup_vsync_mode != video.vsync_mode)
+ {
+ // changing vsync mode to selected value failed -- reset displayed value
+ execSetupGraphics_setVsyncModes(TRUE);
+
+ Request("Setting VSync failed!", REQ_CONFIRM);
+
+ DrawSetupScreen();
+ }
}
static void execSetupChooseWindowSize(void)
static void execSetupArtwork(void)
{
#if 0
- printf("::: '%s', '%s', '%s'\n",
- artwork.gfx_current->subdir,
- artwork.gfx_current->fullpath,
- artwork.gfx_current->basepath);
+ Debug("screens:execSetupArtwork", "'%s', '%s', '%s'",
+ artwork.gfx_current->subdir,
+ artwork.gfx_current->fullpath,
+ artwork.gfx_current->basepath);
#endif
setup.graphics_set = artwork.gfx_current->identifier;
#if DEBUG_JOYSTICKS
// print info about the joystick we are watching
- Error(ERR_DEBUG, "watching joystick %d: (%s)\n",
+ Debug("joystick", "watching joystick %d: (%s)",
SDL_JoystickInstanceID(joystick), name);
- Error(ERR_DEBUG, "joystick has %d axes, %d hats, %d balls, and %d buttons\n",
+ Debug("joystick", "joystick has %d axes, %d hats, %d balls, and %d buttons",
SDL_JoystickNumAxes(joystick), SDL_JoystickNumHats(joystick),
SDL_JoystickNumBalls(joystick), SDL_JoystickNumButtons(joystick));
#endif
if (success)
{
#if DEBUG_JOYSTICKS
- Error(ERR_DEBUG, "New game controller mapping:\n\n%s\n\n", mapping);
+ Debug("joystick", "New game controller mapping:\n\n%s\n\n", mapping);
#endif
// activate mapping for this game
GameActions(); // main game loop
if (tape.auto_play && !tape.playing)
- AutoPlayTape(); // continue automatically playing next tape
+ AutoPlayTapes(); // continue automatically playing next tape
}
GDI_END);
if (gi == NULL)
- Error(ERR_EXIT, "cannot create gadget");
+ Fail("cannot create gadget");
screen_gadget[id] = gi;
}
GDI_END);
if (gi == NULL)
- Error(ERR_EXIT, "cannot create gadget");
+ Fail("cannot create gadget");
screen_gadget[id] = gi;
}
GDI_END);
if (gi == NULL)
- Error(ERR_EXIT, "cannot create gadget");
+ Fail("cannot create gadget");
screen_gadget[id] = gi;
}
GDI_END);
if (gi == NULL)
- Error(ERR_EXIT, "cannot create gadget");
+ Fail("cannot create gadget");
screen_gadget[id] = gi;
}