CDROM: Add option to speed up double speed reads

This commit is contained in:
Connor McLaughlin
2020-10-05 00:05:14 +10:00
parent 51e8eb108e
commit 8ba93b36a0
8 changed files with 106 additions and 7 deletions

View File

@ -620,6 +620,10 @@ TickCount CDROM::GetAckDelayForCommand(Command command)
TickCount CDROM::GetTicksForRead()
{
const TickCount tps = System::GetTicksPerSecond();
if (g_settings.cdrom_read_speedup > 1 && !m_mode.cdda && !m_mode.xa_enable && m_mode.double_speed)
return tps / (150 * g_settings.cdrom_read_speedup);
return m_mode.double_speed ? (tps / 150) : (tps / 75);
}