delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/10/11/07:56:31

From: "Henrik Rydgård" <henrik DOT rydgard AT alvesta DOT mail DOT telia DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: vsync
Date: Sun, 11 Oct 1998 13:55:22 +0200
Organization: Telia Internet Services
Lines: 22
Message-ID: <36209c73.0@d2o63.telia.com>
References: <6vp6lh$g71$2 AT otis DOT netspace DOT net DOT au>
NNTP-Posting-Host: d2o63.telia.com
X-Newsreader: Microsoft Outlook Express 4.72.2106.4
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.2106.4
X-NNTP-Posting-Host: t1o63p491.telia.com
X-Complaints-To: abuse AT internet DOT telia DOT com
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Mark Tsui skrev i meddelandet <6vp6lh$g71$2 AT otis DOT netspace DOT net DOT au>...
>when I use vsync in my program, the maximum frame rate is only about 60
>frames per second. when I remove the vsync, the program runs at 3000 and
>something frames per second, however, the graphics looked all flickered,
how
>do I solve this problem?
>
>Any help will be appreciated.
>
>
60 FPS is about as fast as your eyes can percieve, so that shoulnd't be a
problem. If your program goes in 3000 FPS it has to be a quite simple
program, right? Which means that when you start adding more stuff the frame
rate will plunge, and so the vsync() won't gobble up so much time. But when
the framerate goes below 60 FPS, then you're in trouble. vsync waits for the
next refresh, and if your program hasn't finished drawing early enough the
framerate goes straight down to 30 FPS. And if your program can't cope with
that, it will go down to 15. And the program will go four times as slow.
Does anyone know how to maintain a constant speed?


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019