Fifo: Make g_bSkipCurrentFrame a TU-local variable

This is only ever queried, making it a global isn't necessary.
This commit is contained in:
Lioncash
2016-01-23 23:20:13 -05:00
parent 48e7e5b72e
commit 5ebd1e215b
9 changed files with 19 additions and 14 deletions

View File

@ -33,7 +33,7 @@ namespace Fifo
static constexpr u32 FIFO_SIZE = 2 * 1024 * 1024;
bool g_bSkipCurrentFrame = false;
static bool s_skip_current_frame = false;
static Common::BlockingLoop s_gpu_mainloop;
@ -82,7 +82,8 @@ void DoState(PointerWrap &p)
// We're good and paused, right?
s_video_buffer_seen_ptr = s_video_buffer_pp_read_ptr = s_video_buffer_read_ptr;
}
p.Do(g_bSkipCurrentFrame);
p.Do(s_skip_current_frame);
p.Do(s_last_sync_gpu_tick);
}
@ -129,7 +130,12 @@ void Shutdown()
void SetRendering(bool enabled)
{
g_bSkipCurrentFrame = !enabled;
s_skip_current_frame = !enabled;
}
bool WillSkipCurrentFrame()
{
return s_skip_current_frame;
}
// May be executed from any thread, even the graphics thread.