Add ability to disable main loop.
Useful to validate with valgrind. Signed-off-by: Andrea Odetti <mariofutire@gmail.com>
This commit is contained in:
parent
4fc2ee18f2
commit
fb708ca7b8
1 changed files with 4 additions and 1 deletions
|
@ -44,6 +44,8 @@
|
|||
#include "Riff.h"
|
||||
#include "Utilities.h"
|
||||
|
||||
// comment out to test / debug init / shutdown only
|
||||
#define EMULATOR_RUN
|
||||
|
||||
namespace
|
||||
{
|
||||
|
@ -260,7 +262,7 @@ void run_sdl(int argc, const char * argv [])
|
|||
|
||||
Emulator emulator(win, ren, tex, options.fixedSpeed);
|
||||
|
||||
|
||||
#ifdef EMULATOR_RUN
|
||||
if (options.benchmark)
|
||||
{
|
||||
// we need to switch off vsync, otherwise FPS is limited to 60
|
||||
|
@ -414,6 +416,7 @@ void run_sdl(int argc, const char * argv [])
|
|||
std::cerr << "Actual clock: " << actualClock << " Hz, " << timeInSeconds << " s" << std::endl;
|
||||
SDirectSound::stop();
|
||||
}
|
||||
#endif
|
||||
|
||||
uninitialiseEmulator();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue