Archived

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

clock() & framerate

This topic is 5579 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

hi there...I''m implementing a framerate counter in my program, but I get some weird results using clock(). This function is supposed to return the number of ticks of the CPU. Though, the diff between end and start is always exactly 10 or 20. I''m glad my program is that fast, but I guess it''s not significant. And one more problem, when profiling my program, I realize that the most CPU costing function is gluSwapBuffers. My program isn''t CPU expensive yet. But it''s weird still. My first thought was that gluSwapBuffers was the one that was waiting for resync (making the framerate always under 60Hz). Am I right? tanx in advance...

Share this post


Link to post
Share on other sites