mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-03-14 13:21:15 +00:00
BTEmu: Throttle prior to wii remote input update.
This commit is contained in:
parent
9675c90890
commit
aa624d8ba8
@ -347,10 +347,13 @@ void BluetoothEmuDevice::Update()
|
||||
wiimote->Update();
|
||||
|
||||
const u64 interval = GetSystem().GetSystemTimers().GetTicksPerSecond() / Wiimote::UPDATE_FREQ;
|
||||
const u64 now = GetSystem().GetCoreTiming().GetTicks();
|
||||
auto& core_timing = GetSystem().GetCoreTiming();
|
||||
const u64 now = core_timing.GetTicks();
|
||||
|
||||
if (now - m_last_ticks > interval)
|
||||
{
|
||||
// Throttle before Wii Remote update so input is taken just before needed. (lower input latency)
|
||||
core_timing.Throttle(now);
|
||||
g_controller_interface.SetCurrentInputChannel(ciface::InputChannel::Bluetooth);
|
||||
g_controller_interface.UpdateInput();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user