bankp works fine here, I used the -syncrefresh option and got perfect scroll, no video artifacts, and constant 100% fps (100.17% actually).
Is that with default settings, "ddraw" enabled and "soundsync" disabled?
I tried it on another computer, default settings, and got much better results. The game speed was quite steady at 99% with occasional jumps to 92%, there were still audio and scroll glitches, but only once or twice per minute instead of every few seconds. Interestingly, jumps in game speed were more frequent and not occurring in the same time as audio and video glitches, just like with the first computer.
I then tried "d3d" instead of "ddraw", with the rest of default settings, and the game speed was very steady at 102% with occasional quick jumps to 104% and 101%, however scroll was perfectly smooth and I only maybe saw one or two glitches in about five or ten minutes all together. Unfortunately audio was still glitching every few seconds, only it was almost unnoticeable compared to the previous test, but this time when I enabled "soundsync" everything was finally working as it should.
Therefore, the answer, in my particular case, was to set "d3d" instead of "ddraw" and enable "soundsync", so perhaps you might want to consider changing GroovyMAME default settings to these ones, unless, I suppose, there is a good reason not to, but I believe this test alone provides quite enough reason to actually do so.
- Badly installed drivers, ddraw acceleration not working (check dxdiag).
DirectDraw is not part of video drivers. Acceleration in dxdiag is probably only about using VRAM instead of RAM for double and triple buffering, and there is nothing there about frame refresh and vsync. Dxdiag test run smoothly and everything is fine with other applications and emulators. If I disable ddraw acceleration I get maximum of 450% game speed instead of 500%, that's all, nothing else changes.
- Messing with video card control panel vsync options, those should be set so they don't override the application vsync operation.
That's a part of the video driver, but those options are only for DirectX and OpenGL. Depending on version and particular video card DirectDraw could probably exhibit different behavior, possibly completely unrelated to video driver settings. In my control panel vsync is set so application decides, and it works as it should once I switched from "ddraw" to "d3d", but even with "ddraw" I could not throttle to maximum speed with "syncrefresh" enabled, so there was some syncing going on, perhaps only subject to some unwanted interruptions, unstable timer, some multitasking lockouts, buffering overflow, or something, it remains a mystery.
- Whatever unknown reason that prevents directx from reporting the sync events properly.
I'd check if you can get a constant vsynced fps with any other application in your system (without forcing vsync from the control panel).
Yes, I can get good sync with other applications and emulators, vsync is not forced from my control panel and when I force it nothing changes except I can not throttle to maximum speed with F10 regardless of "syncrefresh" and "waitvsync" settings, as expected.
Solution was to enable "d3d" and "soundsync". However, with default GroovyMAME settings I had exact same problem on two different computers, and even with "d3d", when everything was smooth and fine, the game speed (F11) still fluctuated a bit, so I am very surprised you have not notice any of that, it's against the odds, it seems, so maybe you should try the test again (with default settings: "ddraw" enabled, "soundsync" disabled) and also with another computer too, but be more careful as scroll glitches may not repeat very often and sound problems may not be immediately recognizable.