Jump to content
  • Advertisement

Archived

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

BeanDog

Vertical refresh troubles - probly simple

This topic is 6643 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 this problem. Recently we updated our graphix drivers for our 3d Banshee 16mb card. Since then whenever I run any of my DX7.0a DirectDraw progs or even Donuts or somesuch, it runs at about 600000fps (an exaggeration) despite the refresh rate. This doesn''t happen in other games (i.e. Worms 2, etc.), so they must have set it up somehow besides letting DX handle it. So, how do you wait until the next vertical refresh? Just like... do{}while( !CheckVerticalRefresh() ); where CheckVerticalRefresh() returns true if it''s at the next vertical refresh. thanks. ~BenDilts( void );

Share this post


Link to post
Share on other sites
Advertisement
Some time ago I had the same problem.

Now I use:
lpDD->WaitForVerticalBlank(DDWAITVB_BLOCKBEGIN, NULL);
where lpDD is of type:
LPDIRECTDRAW
Beware using this function! Windows is stopped while waiting for the retrace!

It''s also possible to use:
while(_inp(0x3DA)&0x08); // Wait if in verticle retrace.
while(!(_inp(0x3DA)&0x08)); // Wait for verticle retrace to begin.
But WinNT does not allow use of I/O this way. Last week I read about a special DLL that will do this for you in WinNT. But I don''t remember where I saw it...

Hope this is what you meant,
Bas.

Share this post


Link to post
Share on other sites
THANKS A LOT!

I''ve been reposting that question over and over again for days. You''re the first one to answer and YOU WERE RIGHT!

Well, now that that''s out of my system...

There is still a little flickering now and then. Do you get this, too?

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!