Quote:
Originally Posted by Fabian
I'm thinking that the problem is that the blit is done in the gfx thread, which executes roughly 30 times per second.
|
Your summary of the behaviour is correct, but the gfx update rate isn’t the issue. The gfx are displayed significantly -before- the audio it should be in sync with (in the test setup, 70ms with the MIDI item open, 438ms when it’s closed). If the issue was the gfx update (with audio / midi events at the same time stamp rendered / processed simultaneously) you’d expect it to be late, not early, by between 0 and 33ms.
I’m guessing that the midi is being received by the plugin at the same time the audio at the same time stamp enters the audio pipeline. The plugin immediately (well, on next gfx update) draws the gfx, but the audio is delayed by whatever latency / PDC etc exists in the pipeline.
If the same midi was being used to drive an instrument the issue wouldn’t arise because it’s audio would be passing through the same pipeline, adjusted by PDC etc.
Not sure why the offset is smaller when the midi editor is open…