[SDL] refresh issue, "skipping"

Jonathan Dearborn grimfang4 at hotmail.com
Sun May 18 14:25:44 PDT 2008


Hey,

Is it also possible that your computer doesn't like your program to be a CPU-hog?  Are you throttling your frame rate?  If you aren't, you should look into it.  Your program might get a hiccup whenever the OS needs to do something else.  If you are controlling the frame rate, then it could possibly be due to SDL_Delay's precision.  I had a similar effect in my program that I fixed by measuring the time SDL_Delay takes to delay 1ms and then in my loop I delay for DELAYTIME minus that number.  Then I burn the rest in a loop for precise timing control.

Jonny D



> To: sdl at lists.libsdl.org
> From: slouken at devolution.com
> Date: Sat, 17 May 2008 21:13:52 -0700
> Subject: Re: [SDL] refresh issue, "skipping"
> 
> > I'm seeing a dropped frame (a "hiccup" in my continuously moving stimulus) 
> > once every 22 to 33 seconds or so ... though for a while yesterday it was 
> > happening only once every 60 seconds.  Perhaps system processes are hogging 
> > CPU and causing this to happen.  Is there a way to increase SDL's priority so 
> > that all background processes are stopped while my program is running?
> 
> This is very likely some other processes taking time.  This is typically
> anti-virus software or windows update.  Try shutting down all other processes
> and disabling these services temporarily.
> 
> See ya!
> 	-Sam Lantinga, Lead Software Engineer, Blizzard Entertainment
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

_________________________________________________________________
Make every e-mail and IM count. Join the i’m Initiative from Microsoft.
http://im.live.com/Messenger/IM/Join/Default.aspx?source=EML_WL_ MakeCount
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20080518/de24ba06/attachment.htm>


More information about the SDL mailing list