mirror of
https://github.com/kanjitalk755/macemu.git
synced 2024-06-02 13:41:37 +00:00
add pref item "mag_rate"
BII: JIT
This commit is contained in:
parent
6f87eaca84
commit
3861177919
|
@ -1089,6 +1089,7 @@
|
||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
ENABLE_MACOSX_ETHERHELPER,
|
ENABLE_MACOSX_ETHERHELPER,
|
||||||
"BINCUE=1",
|
"BINCUE=1",
|
||||||
|
"USE_JIT=1",
|
||||||
);
|
);
|
||||||
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
|
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
|
||||||
GCC_USE_STANDARD_INCLUDE_SEARCHING = YES;
|
GCC_USE_STANDARD_INCLUDE_SEARCHING = YES;
|
||||||
|
@ -1150,6 +1151,7 @@
|
||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
ENABLE_MACOSX_ETHERHELPER,
|
ENABLE_MACOSX_ETHERHELPER,
|
||||||
"BINCUE=1",
|
"BINCUE=1",
|
||||||
|
"USE_JIT=1",
|
||||||
);
|
);
|
||||||
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
|
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
|
||||||
GCC_USE_STANDARD_INCLUDE_SEARCHING = YES;
|
GCC_USE_STANDARD_INCLUDE_SEARCHING = YES;
|
||||||
|
|
|
@ -705,6 +705,12 @@ static void shutdown_sdl_video()
|
||||||
delete_sdl_video_window();
|
delete_sdl_video_window();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int get_mag_rate()
|
||||||
|
{
|
||||||
|
int m = PrefsFindInt32("mag_rate");
|
||||||
|
return m < 1 ? 1 : m > 4 ? 4 : m;
|
||||||
|
}
|
||||||
|
|
||||||
static SDL_Surface * init_sdl_video(int width, int height, int bpp, Uint32 flags)
|
static SDL_Surface * init_sdl_video(int width, int height, int bpp, Uint32 flags)
|
||||||
{
|
{
|
||||||
if (guest_surface) {
|
if (guest_surface) {
|
||||||
|
@ -751,12 +757,13 @@ static SDL_Surface * init_sdl_video(int width, int height, int bpp, Uint32 flags
|
||||||
window_flags |= SDL_WINDOW_RESIZABLE;
|
window_flags |= SDL_WINDOW_RESIZABLE;
|
||||||
*/
|
*/
|
||||||
if (!sdl_window) {
|
if (!sdl_window) {
|
||||||
|
int m = get_mag_rate();
|
||||||
sdl_window = SDL_CreateWindow(
|
sdl_window = SDL_CreateWindow(
|
||||||
"Basilisk II",
|
"Basilisk II",
|
||||||
SDL_WINDOWPOS_UNDEFINED,
|
SDL_WINDOWPOS_UNDEFINED,
|
||||||
SDL_WINDOWPOS_UNDEFINED,
|
SDL_WINDOWPOS_UNDEFINED,
|
||||||
window_width,
|
m * window_width,
|
||||||
window_height,
|
m * window_height,
|
||||||
window_flags);
|
window_flags);
|
||||||
if (!sdl_window) {
|
if (!sdl_window) {
|
||||||
shutdown_sdl_video();
|
shutdown_sdl_video();
|
||||||
|
@ -1044,7 +1051,7 @@ void driver_base::init()
|
||||||
|
|
||||||
// set default B/W palette
|
// set default B/W palette
|
||||||
sdl_palette = SDL_AllocPalette(256);
|
sdl_palette = SDL_AllocPalette(256);
|
||||||
sdl_palette->colors[1] = (SDL_Color){ .r = 0, .g = 0, .b = 0 };
|
sdl_palette->colors[1] = (SDL_Color){ .r = 0, .g = 0, .b = 0, .a = 255 };
|
||||||
SDL_SetSurfacePalette(s, sdl_palette);
|
SDL_SetSurfacePalette(s, sdl_palette);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1626,7 +1633,8 @@ static void do_toggle_fullscreen(void)
|
||||||
display_type = DISPLAY_WINDOW;
|
display_type = DISPLAY_WINDOW;
|
||||||
SDL_SetWindowFullscreen(sdl_window, 0);
|
SDL_SetWindowFullscreen(sdl_window, 0);
|
||||||
const VIDEO_MODE &mode = drv->mode;
|
const VIDEO_MODE &mode = drv->mode;
|
||||||
SDL_SetWindowSize(sdl_window, VIDEO_MODE_X, VIDEO_MODE_Y);
|
int m = get_mag_rate();
|
||||||
|
SDL_SetWindowSize(sdl_window, m * VIDEO_MODE_X, m * VIDEO_MODE_Y);
|
||||||
SDL_SetWindowGrab(sdl_window, SDL_FALSE);
|
SDL_SetWindowGrab(sdl_window, SDL_FALSE);
|
||||||
} else {
|
} else {
|
||||||
display_type = DISPLAY_SCREEN;
|
display_type = DISPLAY_SCREEN;
|
||||||
|
|
|
@ -77,6 +77,7 @@ prefs_desc common_prefs_items[] = {
|
||||||
{"scale_integer",TYPE_BOOLEAN,false,"integer scaling"},
|
{"scale_integer",TYPE_BOOLEAN,false,"integer scaling"},
|
||||||
{"yearofs", TYPE_INT32, 0, "year offset"},
|
{"yearofs", TYPE_INT32, 0, "year offset"},
|
||||||
{"dayofs", TYPE_INT32, 0, "day offset"},
|
{"dayofs", TYPE_INT32, 0, "day offset"},
|
||||||
|
{"mag_rate", TYPE_INT32, 0, "rate of magnification"},
|
||||||
{NULL, TYPE_END, false, NULL} // End of list
|
{NULL, TYPE_END, false, NULL} // End of list
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -65,6 +65,7 @@ prefs_desc common_prefs_items[] = {
|
||||||
{"cpuclock", TYPE_INT32, 0, "CPU clock [MHz] of system info"},
|
{"cpuclock", TYPE_INT32, 0, "CPU clock [MHz] of system info"},
|
||||||
{"yearofs", TYPE_INT32, 0, "year offset"},
|
{"yearofs", TYPE_INT32, 0, "year offset"},
|
||||||
{"dayofs", TYPE_INT32, 0, "day offset"},
|
{"dayofs", TYPE_INT32, 0, "day offset"},
|
||||||
|
{"mag_rate", TYPE_INT32, 0, "rate of magnification"},
|
||||||
{NULL, TYPE_END, false, NULL} // End of list
|
{NULL, TYPE_END, false, NULL} // End of list
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user