Code cleanup, found that rendering of openGL graphics are limiting the max frame speed to 60 hz. Have not solution for it yet.
This commit is contained in:
parent
b4b2cca9ec
commit
a1c0e86026
|
@ -75,9 +75,13 @@ SpeedThrottle()
|
|||
else
|
||||
InFrame = 0;
|
||||
|
||||
/*fprintf(stderr, "attempting to sleep %Ld ms, frame complete=%s\n",
|
||||
time_left, InFrame?"no":"yes");*/
|
||||
SDL_Delay(time_left);
|
||||
//fprintf(stderr, "attempting to sleep %Ld ms, frame complete=%s\n",
|
||||
// time_left, InFrame?"no":"yes");
|
||||
|
||||
if ( time_left > 0 )
|
||||
{
|
||||
SDL_Delay(time_left);
|
||||
}
|
||||
|
||||
if(!InFrame)
|
||||
{
|
||||
|
|
|
@ -911,11 +911,18 @@ int main(int argc, char *argv[])
|
|||
while(1)
|
||||
{
|
||||
if(GameInfo)
|
||||
{
|
||||
DoFun(frameskip, periodic_saves);
|
||||
}
|
||||
else
|
||||
{
|
||||
SDL_Delay(1);
|
||||
}
|
||||
|
||||
while(gtk_events_pending())
|
||||
gtk_main_iteration_do(FALSE);
|
||||
{
|
||||
gtk_main_iteration_do(FALSE);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue