• Advertisement

Archived

This topic is now archived and is closed to further replies.

The DOS Vsync

This topic is 6536 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have finally figured out how to check the DOS Vsync (for mode13h) so that there is no flicker. However, I think it is a tad slow, and would like some ASM code for it. I''m using DOS, w/ a Turbo C++ 3.0 from Borland. Thanks -- David Rogers.

Share this post


Link to post
Share on other sites
Advertisement
I can''t remember exactly how (it''s been almost a year since I did a graphics routine in asm). But you contact the video port, and request a VSYNC. If you search the net, looking for vidcaps.zip or something like that, you should find a doc that explains it. Or, goto www.programmerheaven.com.

Share this post


Link to post
Share on other sites
Hopefully this will be of help:


void wait_for_retrace(void)
{
_DX = 0x03DA;

l1: asm {
in al, dx
and al, 0x08
jnz l1
}

l2: asm {
in al, dx
and al, 0x08
jz l2
}
}

Share this post


Link to post
Share on other sites
Thanks for your help. The ASM version is alot smoother than the C version. I finally got good graphics going, so a game is SOOOO close!

-David [sponge99]

Share this post


Link to post
Share on other sites
hey, if you could, i''d like to see the game when you''re done, cuz im using turbo c++ 3.0 as well, and i''m doing almost exactly what you are. anyway, even if your not done with it, if you wanna email me what you have so far that''d be great. if not, though, i understand... thanks. o, btw, if you need anymore routines for 13h, i have a few laying around...

Share this post


Link to post
Share on other sites

  • Advertisement