OpenEmu/OpenEmu — Issue #112: Audio based timing
Author: astrange
Created: 2012-02-29 09:12:09+00:00
State: open

Cycle accurate emulators don't have 60fps frame rates and 48khz sample rates independent of each other, rather they have a single system clock.

We should accommodate them by basing timing on the audio sample rate rather than the frameInterval (which is wrong in most of the cores anyway).

For cores too slow to run at 100% speed this will also mean the graphics slow down instead of the audio breaking up. (I think.) Frame skipping will no longer make sense, but it already didn't make sense for LLE cores.

Basically instead of having cores define frameInterval, have them define number of audio samples between video frames (EXACTLY, not a guess). Then run the core until it generates that much audio and draw a frame.