Thanks for testing. We are aware of both issues and are working on it.
The FM-PAC issue should be fixed. Can you please confirm? (And do some testing for unintended side effects?)
It looks like it works now.
I don’t know about what unintended side-effects I should be looking for, but if I understand the change correctly it is no longer possible to get the OPLL register write corruption when accessing it too fast even when running at normal speed emulation. That’s too bad because it was one of the benefits of the Nuke.YKT core.
But I read in the commit comment that “For now solved/worked-around/hacked by detecting too fast-access and then inserting extra YM2413 synthesis calls (but ignore the sound generated by that call). After the release we should probably revisit this. At this point it's not clear yet what the proper solution should be.” — so I assume this will be restored later.
Thinking forward a bit towards a proper solution… The throttle function never had this issue. What was different there? Does throttle speed up the sound chip emulation as well, but discard the majority of the audio frames in the same way it discards video frames?
Can’t the same method be applied here as well? At 20x speed at least, there’s not much difference in how it sounds. The current feature where the sound chip is kept running at 100% to improve the audio during fast-forward seems to mostly make sense when running at speeds of around 2x or 3x (or below 1x)… beyond that I don’t think it matters much. I think personally I would be totally fine with using the discard-buffers approach throughout.
< Quibus> mth: are you saying the issue wouldn't occur with throttle off?
< mth> but it would have been there
< mth> afaik throttle off just discards most of the audio; it doesn't try to adjust for speed because it has no defined speed
< pgimeno> < wouterv> but why does "set throttle off" have a different effect than "set fastforward on"?
< pgimeno> < wouterv> i may have found it: SDLSoundDriver.cc:138
< pgimeno> < wouterv> we explicitly check for throttle=on before pausing on audio-buffer overrun
One of the reasons things are done as they are now, is that openMSX always tried to play the sound at the normal pitch, even at higher speeds. This workaround keeps that property.
I think ideally the sound emulation cores should match the emulation speed increase, decoupling them is not ideal. Decoupling the timing between the CPU and audio could cause issues when the CPU relies on the sound chip’s timing like through interrupts, flags or uses timing-sensitive sound effects. Also it only really works for FM sounds with a quick attack.
Given an audio core which runs faster than real-time, I see two possible ways to preserve pitch;
- Either discard or repeat audio frames based on the speed of the emulation relative to real-time (like throttle).
- Or go extra fancy by resampling the sound in the frequency domain so that the spectrum and thus the pitch and general timbre stay intact, but sped up or slowed down.
Anyway, this is going to be a great release, I look forward to it .
When I record, fast-forward does not work. Is that intentional?
(I can use throttle instead, but it’s uncapped so it whizzes by anything that I want to record.)
When you record all frames are rendered, at least. Obviously. But maybe I'm misunderstanding...
I think you’re misunderstanding. Previously I could throttle off during recording to speed up the process. It’s useful so you don’t have to wait in real-time while recording every take. The fast forward behaves differently (probably is disabled to avoid sound clock desync in the recorded footage).
You might know this, but openmsx-0.15.0-885 Windows version of Catapult is broken.
What is broken about it?