[RVGL] No interpolation between physics states

Report issues with v1.2 here.

Moderators: Huki, jigebren

[RVGL] No interpolation between physics states

Eliasvan
Sober
Joined: 20 May 2017, 20:34

20 May 2017, 20:56 #1

See video for evidence of the problem:
[youtube]WYIg_qTHx2w[/youtube]

Observations:
- Physics engine of cars and projectiles (rigid bodies) runs at ~125Hz,
and there is no interpolation between these physic steps, resulting in stuttering
- Particle system simulation is only limited to the refresh rate, and thus runs at 1000Hz in this case
- Rendering also runs at the refresh rate, 1000Hz, check the race timer at the right for evidence

Suggestions:
- Add interpolation between the physics states, e.g., linear interpolation; this will make this video much smoother

Info:
- RVGL version: 17.0327a 64-bit on Linux
- See description of above linked video for more info

Feel free to ask any question if something is not clear
Reply
Like

Abc
100% Proofer
Abc
100% Proofer
Joined: 07 Apr 2009, 18:43

21 May 2017, 02:53 #2

Hi, this is pretty well known but thanks!

The game is not supposed to be ran on such high speeds!

Please look other threads about this.
Yes, I'm the ABC block and you can find me in Toy World 1 track! ;)
Reborn as Juest Zungo :P PS: I prefer chatting and i have Steam, Skype, Google and Microsoft account, just ask for it via PM or rarely find me in RVHouse. Also check out my interests.
Reply
Like

speedwagon
Sober
Joined: 05 Sep 2016, 20:23

21 May 2017, 10:30 #3

Abc @ 21 May 2017, 03:53 AM wrote: Hi, this is pretty well known but thanks!

The game is not supposed to be ran on such high speeds!

Please look other threads about this.
It's kinda funny since it's hard to not run it at high speeds even with 10 year old computers that use onboard graphics.
Reply
Like

Abc
100% Proofer
Abc
100% Proofer
Joined: 07 Apr 2009, 18:43

21 May 2017, 16:53 #4

Again, its a very old game
in argentina for example, it was acceptable at 10-30-60 fps at the time
remember the engine is designed and runs at 125fps
plus it was shipped with bugs
Yes, I'm the ABC block and you can find me in Toy World 1 track! ;)
Reborn as Juest Zungo :P PS: I prefer chatting and i have Steam, Skype, Google and Microsoft account, just ask for it via PM or rarely find me in RVHouse. Also check out my interests.
Reply
Like

Eliasvan
Sober
Joined: 20 May 2017, 20:34

21 May 2017, 18:52 #5

Abc @ 21 May 2017, 05:53 PM wrote: Again, its a very old game
in argentina for example, it was acceptable at 10-30-60 fps at the time
remember the engine is designed and runs at 125fps
plus it was shipped with bugs
Hi Abc,

I do agree that 1000fps is a special use case and it might be tolerable that this doesn't work perfect.

However...
This video is interesting in the sense that it works a bit like a magnifying glass for the time domain, making it easy do to observations by, e.g., counting time (the "Race" timer advances by exactly 1 millisecond for each frame).
These observations, together with some background info from this post, revealed that RVGL suffers from temporal aliasing (perceived by humans as visually unpleasant stuttering).

I prefer 30fps with perfect frame-times (no stuttering) over 60fps with jitter/stuttering.
In fact, the reason most movies still play at 24fps without people complaining, is because there's no jitter (and because a shutter time of half a frame is used, creating some motion blur, but let's not take that into account now).

Long story short, when this bug is fixed (by linearly interpolating between physics states):
- one will be able to record smooth slow motion videos @ 1000fps (I'll redo the video once the fix is released ;) ), AND
- the temporal aliasing will be gone, so no stuttering anymore
Reply
Like

Abc
100% Proofer
Abc
100% Proofer
Joined: 07 Apr 2009, 18:43

26 May 2017, 12:27 #6

Are the original game and 1.2 also affected by this?
Yes, I'm the ABC block and you can find me in Toy World 1 track! ;)
Reborn as Juest Zungo :P PS: I prefer chatting and i have Steam, Skype, Google and Microsoft account, just ask for it via PM or rarely find me in RVHouse. Also check out my interests.
Reply
Like

Eliasvan
Sober
Joined: 20 May 2017, 20:34

28 May 2017, 15:41 #7

Abc @ 26 May 2017, 01:27 PM wrote: Are the original game and 1.2 also affected by this?
I cannot answer that question right now since my speedhack (using LD_PRELOAD) doesn't work on Wine yet (I'm using Linux);
I also tried with CheatEngine's speedhack, but that one also doesn't work on Wine.

Feel free to test for yourself if you've got RV1.2 running on Windows, using e.g. CheatEngine's speedhack:
simply slow down with a factor 20 (verify the "fps" counter is over 1000fps) and see whether there's more than one "Race" timer tick per movement of the car, if yes, it's also affected.

Edit: I modified my speedhack such that I can now run it on Wine as well,
and I saw that both the original (demo from: https://www.revoltrace.net/downloads.php) and a later version (from: https://archive.org/details/Re-Volt) are affected by this:
physics step is 8ms (125Hz) without interpolation between steps.
Reply
Like