GLBasic forum

Main forum => GLBasic - en => Topic started by: Qedo on 2020-May-29

Title: How to check Vsync screen
Post by: Qedo on 2020-May-29
On my system this work. Output 60 Hz
Can you try on your?
Ad maiora

LIMITFPS -1,TRUE
cicli%=100
dt%=GETTIMERALL()
FOR i=0 TO cicli-1
   CLEARSCREEN RGB(120,345,56)
   SHOWSCREEN
NEXT
dt=1000/((GETTIMERALL()-dt)/cicli)
PRINT "refresh Rate = "+dt+"Hz",10,100
SHOWSCREEN
MOUSEWAIT
END
Title: Re: How to check Vsync screen
Post by: MrPlow on 2020-May-29
506 Hz
Title: Re: How to check Vsync screen
Post by: dreamerman on 2020-May-29
60Hz monitor, code mostly outputs 60, sometime 59hz happens.
Title: Re: How to check Vsync screen
Post by: Qedo on 2020-May-29
506 Hz? It seems too high to me.
On my system I get 500 Hz but only by disabling vsync i.e. with the command "LIMITFPS -1,FALSE"
But with LIMITFPS -1,TRUE the rate should drop.
Otherwise the check doesn't work.
You can check?
Thanks
Ad maiora
Title: Re: How to check Vsync screen
Post by: MrPlow on 2020-May-29
Same on both 506
Title: Re: How to check Vsync screen
Post by: Qedo on 2020-May-29
very strange
But how is the graphics card set on the system?
Title: Re: How to check Vsync screen
Post by: Heiko on 2020-May-30
With LIMITFPS -1,TRUE  50hz
with LIMITFPS -1,FALSE 504hz

Maybe you force vsync off in the driver settings.
Title: Re: How to check Vsync screen
Post by: spacefractal on 2020-May-30
500fps is maximum set by code in the flip screen code seen in source code when vsync is disabled (even im wanted that to been skipped completly).

Its a area that require some update and tweeks as its could been better. Etc there is no way to detect the user screen at all. Should check possible to detect the screen settings by a api.

Sometimes a monitor does not sync extracly as 60hz, but can sometimes been 59 or something like that.

Title: Re: How to check Vsync screen
Post by: MrPlow on 2020-May-31
At present only using my laptop screen - maybe that is why...my office with my screen is getting redecorated atm