cancel
Showing results for 
Search instead for 
Did you mean: 

Can the FPS reported by VrApi be trusted if I disable vsync?

griffin1977
Explorer
I am trying to profile my application (on an S6), so I have  disabled vsync by setting minimum MinimumVsyncs to 0.

The values returned for framerate by VrApi appear to be correct, or at least plausible (if I render a lot it drops, if I render very little it goes up, capping out about 120FPS if do basically nothing). Except the value for stale frames per second seem really really high (if I am at 60FPS the number of stale frames is also about 60!)
09-18 17:52:30.541 32558-1027/com.oculus.SimpleBenchmark I/VrApi: FPS=85,Prd=10ms,Tear=0,Early=0,Stale=59,VSnc=0,Lat=0,CPU4/GPU=2/3,800/350MHz,OC=FF,TA=F0/F0/0,SP=F/F/N,Mem=836MHz,Free=424MB,PSM=0,PLS=0,Temp=34.3C/30.0C

This seems clearly wrong as I my application is clearly rendering some new frames not just 60 stale frames a second. If I re-enable Vsync by setting MinimumVsyncs to 1)
then the stale frames value goes down to 0 (but the FPS becomes clamped to 60FPS as you would expect)

Are these values, in fact correct? Or are the frame rate values I am see when MinimumVsyncs is 0 pretty much meaningless, is there another way to see the non-Vsync bound number of frames per second is getting? Or can I just ignore the stale frames count and use the FPS that VrApi is spitting out?
2 REPLIES 2

griffin1977
Explorer

The hardware can not display frames faster than 60 fps. Doing this (setting minimum vsync to 0) probably causes tearing (as a frame-in-progress is overwritten by another frame) and just burns battery / heat. There's no benefit to do doing this.



The reason for doing this is to profile my app, so I don't care that whether the resulting image is displayed correctly as long as the timing information is correct, and giving me a correct insight into the performance of my app.

So in the example I posted above where it reported 84FPS, is my actually app actually taking 11ms to render each frame, even though it's reporting 59 stale frames? (that 59 number seems implausible, that would mean I am only actually rendering 20 frames a second which I can clearly see is incorrect)


griffin1977
Explorer
Thanks for the info. So when I see FPS that is not clamped to Vsync intervals (such as the example above where it is reporting 83FPS) that is not a valid measurement?

Is there an example of off-screen rendering somewhere?