void Java_org_deadc0de_apple2ix_Apple2View_nativeGraphicsInitialized(JNIEnv *env, jclass cls, jint width, jint height) { // WANRING : this needs to happen on the GL thread only LOG("width:%d height:%d", width, height); video_shutdown(); video_backend->reshape(width, height); video_backend->init((void *)0); }
int main(int argc, char *argv[]) { video_init(0); audio_init(argc, argv); game_init(); double last = glfwGetTime(); while (running) { double current = glfwGetTime(); int delta = (current - last) * 1000; if (delta < MIN_DELTA) { glfwSleep((MIN_DELTA-delta)/1000.0); continue; } last = current; now += delta; if (delta > MAX_DELTA) continue; game_tick(delta); } audio_shutdown(); video_shutdown(); return EXIT_SUCCESS; }
/*** * Cleans up the long-lived memory we've allocated. */ void vita_cleanup() { free(pad); vita2d_fini(); audio_shutdown(); video_shutdown(); }
void quit(int sig) { if (sig != -1) { script_call("shutdown", NULL); } base_shutdown(); video_shutdown(); audio_shutdown(); common_shutdown(); exit(0); }
void emulator_shutdown(void) { video_shutdown(); timing_stopCPU(); _shutdown_threads(); }
void machine_shutdown(void) { file_system_detach_disk_shutdown(); machine_specific_shutdown(); autostart_shutdown(); #ifdef HAS_JOYSTICK joystick_close(); #endif sound_close(); printer_shutdown(); gfxoutput_shutdown(); fliplist_shutdown(); file_system_shutdown(); fsdevice_shutdown(); tape_shutdown(); traps_shutdown(); kbdbuf_shutdown(); keyboard_shutdown(); monitor_shutdown(); console_close_all(); cmdline_shutdown(); resources_shutdown(); drive_shutdown(); machine_maincpu_shutdown(); video_shutdown(); ui_shutdown(); sysfile_shutdown(); log_close_all(); event_shutdown(); network_shutdown(); autostart_resources_shutdown(); fsdevice_resources_shutdown(); disk_image_resources_shutdown(); machine_resources_shutdown(); sysfile_resources_shutdown(); zfile_shutdown(); ui_resources_shutdown(); log_resources_shutdown(); fliplist_resources_shutdown(); romset_resources_shutdown(); #ifdef HAVE_NETWORK monitor_network_resources_shutdown(); #endif archdep_shutdown(); lib_debug_check(); }
void all_shutdown(int signal) { video_shutdown(signal); audio_shutdown(signal); kill(getpid(), SIGKILL); exit(0); }