From 7bb66421a08ee4c061d7336efc20c69f70e97cd9 Mon Sep 17 00:00:00 2001 From: bunnei Date: Thu, 22 May 2014 20:01:04 -0400 Subject: lcd: added thread wait after (faked) vblank interrupt (would have) occurred --- src/core/hw/lcd.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/core/hw/lcd.cpp b/src/core/hw/lcd.cpp index 6468053f2..b57563a73 100644 --- a/src/core/hw/lcd.cpp +++ b/src/core/hw/lcd.cpp @@ -11,6 +11,8 @@ #include "video_core/video_core.h" +#include "core/hle/kernel/thread.h" + namespace LCD { Registers g_regs; @@ -130,9 +132,11 @@ template void Write(u32 addr, const u8 data); void Update() { u64 current_ticks = Core::g_app_core->GetTicks(); + // Fake a vertical blank if ((current_ticks - g_last_ticks) >= kFrameTicks) { g_last_ticks = current_ticks; VideoCore::g_renderer->SwapBuffers(); + Kernel::WaitCurrentThread(WAITTYPE_VBLANK); } } -- cgit v1.2.3