Hacker News new | ask | show | jobs
by AnIdiotOnTheNet 1277 days ago
As I recall, at least in mode 13h on VGA cards you can poll a register for vsync status, so a simple way is to just busywait on that.

Alternatively you can install your own timer interrupt for a higher precision counter you can monitor.

Typically we wrote directly to the sound hardware back then, but if you're looking to have all that complexity abstracted (it isn't really that bad, there's good documentation out there and these are pretty simple devices), you could use the old DOS version of the Allegro library.