Added SetFPS() and SetWindowVSync()
This commit is contained in:
@@ -79,11 +79,11 @@ void rc_preUpdate()
|
||||
|
||||
bool rc_update()
|
||||
{
|
||||
if(rc_window_vsync)
|
||||
if(rc_window_setfps)
|
||||
{
|
||||
int frame_delay = 1000/rc_vsync_refresh_rate;
|
||||
while( (SDL_GetTicks()-rc_vsync_timer) < frame_delay ){}
|
||||
rc_vsync_timer = SDL_GetTicks();
|
||||
int frame_delay = 1000/rc_setfps_refresh_rate;
|
||||
while( (SDL_GetTicks()-rc_setfps_timer) < frame_delay ){}
|
||||
rc_setfps_timer = SDL_GetTicks();
|
||||
}
|
||||
|
||||
if(!device->run())
|
||||
|
||||
Reference in New Issue
Block a user