I took interest lately in tear free and low latency gaming. I am not myself a progamer and I have laughable hardware at disposal, but I am the maintainer of a mod of Sauerbraten: Cube 2 (a Quake-like game, so I'm told), and there's a moderate demand in the community for a more low latency implementation of the engine.
I am posting here because I need some feedback on my work from people with some experience and good, varied hardware and OS. I need subjective impressions on mouse responsiveness, and maybe hints on how to objectively measure the lag, and any kind of feedback you feel like to give.
I am attempting just-in-time VSYNC ON. I prefer this instead of VSYNC OFF because it provides an implicit way to get good vsync timestamps, on all platform and with a well standardized API, and I suppose that being vsync a hotly requested feature it is probably well supported by most drivers. If a frame is late for vsync, I switch to VSYNC off on the fly to avoid discarding the frame in its entirety: I am not sure that this is well supported widely, so please test!
How to test the thing
To test, please install Sauerbraten, then install the mod (instructions in the archive). Start the game, press t (for chat/console), and type the following commands:
Code: Select all
/vsync 2
/showfps 1
/map ot
- fps: frames drawn (should match your monitor refresh rate)
- lag x(y): x measures the lag between game state read and frame display with VSYNC, y show the time wasted in waiting from VSYNC
- miss x(y): x is the number of VSYNC misses, y is the number of the just-in-time logic resyncs, which most probably cause microstutters.
Code: Select all
/jitvanticipate //shows the current value on the console, default 1500000 (1.5 ms)
/jitvanticipate 1000000 //set it to 1 ms
With
Code: Select all
/vsync 1
You can test /vsync 0 as a baseline VSYNC OFF implementation. You can limit the fps with "/maxfps <value>".