From 7cee3d981f6c14f630fb614b51f65a3f0151ece5 Mon Sep 17 00:00:00 2001 From: Ilari Liusvaara Date: Sat, 8 Sep 2012 15:15:59 +0300 Subject: [PATCH] lsnes-dumpavi: Don't hold back on emulation speed --- src/core/framerate.cpp | 4 +++- src/dummy/graphics.cpp | 2 ++ src/platform/sdl/main.cpp | 1 + src/platform/wxwidgets/main.cpp | 2 ++ 4 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/core/framerate.cpp b/src/core/framerate.cpp index 33d31303..965af5d7 100644 --- a/src/core/framerate.cpp +++ b/src/core/framerate.cpp @@ -14,6 +14,8 @@ #define HISTORY_FRAMES 10 +extern bool dummy_interface; + namespace { uint64_t last_time_update = 0; @@ -189,7 +191,7 @@ void ack_frame_tick(uint64_t usec) throw() uint64_t to_wait_frame(uint64_t usec) throw() { auto target = targetfps.read(); - if(!frame_number || target.first || turboed) + if(!frame_number || target.first || turboed || dummy_interface) return 0; uint64_t lintime = get_time(usec, true); uint64_t frame_lasted = lintime - frame_start_times[0]; diff --git a/src/dummy/graphics.cpp b/src/dummy/graphics.cpp index 95ececdc..28dc5588 100644 --- a/src/dummy/graphics.cpp +++ b/src/dummy/graphics.cpp @@ -3,6 +3,8 @@ #include #include +bool dummy_interface = true; + namespace { uint64_t next_message_to_print = 0; diff --git a/src/platform/sdl/main.cpp b/src/platform/sdl/main.cpp index 270f2e51..49104046 100644 --- a/src/platform/sdl/main.cpp +++ b/src/platform/sdl/main.cpp @@ -23,6 +23,7 @@ #include "SDL_main.h" #endif +bool dummy_interface = false; struct moviefile generate_movie_template(std::vector cmdline, loaded_rom& r) { diff --git a/src/platform/wxwidgets/main.cpp b/src/platform/wxwidgets/main.cpp index f8926259..f16139f2 100644 --- a/src/platform/wxwidgets/main.cpp +++ b/src/platform/wxwidgets/main.cpp @@ -46,6 +46,8 @@ wxwin_messages* msg_window; wxwin_mainwindow* main_window; std::string our_rom_name; +bool dummy_interface = false; + namespace { thread_id* ui_thread;