[Added] Merge in SVN commit 8551

Moderator: Raze Developers

Merge in SVN commit 8551

Postby mjr4077au » Wed Feb 05, 2020 1:27 am

As discussed here, SVN commit 8551 provided EDuke32 with the biggest uplift in input lag since the dawn of time. Testing between builds 8534 and 8572 will highlight the improvement.

Playing through 0.4.0, while it feels amazing, it's just not at GZDoom level in terms of performance with vsync enabled. I beleive this will remediate that last remnant of input lag I detect in Duke 3D games.

I don't know enough about the game to say what the 'smoothRatio' integer does in the rest of the file, but it's mentioned 40 times and is redefined at multiple points throughout the code. Whether it can be removed entirely or not, I'm not sure.

Code: Select allExpand view
int const smoothRatio = calc_smoothratio(totalclock, ototalclock)

Code: Select allExpand view
smoothRatio = 65536
User avatar
mjr4077au
 
Joined: 17 Jun 2019
Location: Gosford NSW, Australia
Discord: mjr4077au#1027
Github ID: mjr4077au
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby Graf Zahl » Wed Feb 05, 2020 1:45 am

I would have already if that commit didn't need some major work. The input logic is where I made a lot of changes myself while hooking up the games with GZDoom's backend so the entire merge has to be done manually. That's why I put it off until I have more time available. Of course this will eventually have to be ported to all the games. NBlood already started with it but it seems incomplete. I'll also have to investigate what this code does precisely, not that it ultimately gets in the way of future work.

The 'smoothratio' value is for visual frame interpolation.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: Merge in SVN commit 8551

Postby mjr4077au » Wed Feb 05, 2020 1:54 am

Graf Zahl wrote:I would have already if that commit didn't need some major work. The input logic is where I made a lot of changes myself while hooking up the games with GZDoom's backend so the entire merge has to be done manually. That's why I put it off until I have more time available. Of course this will eventually have to be ported to all the games. NBlood already started with it but it seems incomplete. I'll also have to investigate what this code does precisely, not that it ultimately gets in the way of future work.

The 'smoothratio' value is for visual frame interpolation.

Yeah that makes sense, I'm trying to experiment locally on the work laptop now that I have a full toolchain here to compile with but I'm no expert.
User avatar
mjr4077au
 
Joined: 17 Jun 2019
Location: Gosford NSW, Australia
Discord: mjr4077au#1027
Github ID: mjr4077au
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby mjr4077au » Wed Feb 05, 2020 2:30 am

As an FYI, I tried to convert this:
Code: Select allExpand view
            CAMERA(q16ang)   = pPlayer->oq16ang
                             + mulscale16(((pPlayer->q16ang + F16(1024) - pPlayer->oq16ang) & 0x7FFFFFF) - F16(1024), smoothRatio)
                             + fix16_from_int(pPlayer->look_ang);
            CAMERA(q16horiz) = pPlayer->oq16horiz + pPlayer->oq16horizoff
                             + mulscale16((pPlayer->q16horiz + pPlayer->q16horizoff - pPlayer->oq16horiz - pPlayer->oq16horizoff), smoothRatio);

to:
Code: Select allExpand view
            CAMERA(q16ang)   = pPlayer->q16ang + fix16_from_int(pPlayer->look_ang);
            CAMERA(q16horiz) = pPlayer->q16horiz + pPlayer->q16horizoff;

from the first part of the commit to see how much it all went hand in hand, and yeah the outcome was pretty shit. When moving the mouse around, the world becomes very stuttery (no smoothRatio, right? :wink:). Will definitely need a better look than my hack job.
User avatar
mjr4077au
 
Joined: 17 Jun 2019
Location: Gosford NSW, Australia
Discord: mjr4077au#1027
Github ID: mjr4077au
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby mjr4077au » Thu Mar 12, 2020 11:29 pm

So, because I was at home and bored, I've had a go at merging this commit, and a few others that pertain to the main change in 8551. Effectively, these patches merge 8551, 8552, 8554, 8555, 8565, 8605 & 8619.

The mouse handles amazingly and the game feels exactly like GZDoom now in terms of mouse input.

During testing, I get some weird stuttering when moving forward, backwards or sideways (mouse input was never affected) that seems to be something to do with the FPS limiter in the engine. Setting it from 200 or uncapped and to say, 60Hz (my refresh rate) seems to make it go away. I need to have a further look but welcome extra eyes as I'm reaching a knowledge cap.
Last edited by mjr4077au on Fri Mar 13, 2020 10:52 pm, edited 1 time in total.
User avatar
mjr4077au
 
Joined: 17 Jun 2019
Location: Gosford NSW, Australia
Discord: mjr4077au#1027
Github ID: mjr4077au
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby sinisterseed » Fri Mar 13, 2020 1:02 am

You're not alone experiencing stutters in the latest revisions, I've started experiencing that too with the fps limiter set to Auto.
User avatar
sinisterseed
GZDoom RO Translator & Raze Tester
 
Joined: 05 Nov 2019
Twitch ID: sixhundredsixteen
Github ID: sinisterseed
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby mjr4077au » Fri Mar 13, 2020 1:19 am

lowskill. wrote:You're not alone experiencing stutters in the latest revisions, I've started experiencing that too with the fps limiter set to Auto.

Then perhaps the stutters I'm experiencing here in Raze with the changes made are the same reason for the stuttering you're referring to in EDuke32? (There's no Auto in Raze, so only assuming).

It'd be a shame not to merge this (or merge something that has the same impact as this), the combination of GZDoom's OpenGL stuffs and the mouse handling from these commits makes the game feel incredible.
User avatar
mjr4077au
 
Joined: 17 Jun 2019
Location: Gosford NSW, Australia
Discord: mjr4077au#1027
Github ID: mjr4077au
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby sinisterseed » Fri Mar 13, 2020 4:07 am

mjr4077au wrote:
lowskill. wrote:You're not alone experiencing stutters in the latest revisions, I've started experiencing that too with the fps limiter set to Auto.

Then perhaps the stutters I'm experiencing here in Raze with the changes made are the same reason for the stuttering you're referring to in EDuke32? (There's no Auto in Raze, so only assuming).

It'd be a shame not to merge this (or merge something that has the same impact as this), the combination of GZDoom's OpenGL stuffs and the mouse handling from these commits makes the game feel incredible.

Ah what, you weren't talking about EDuke32 stuttering? I was referring to it when I mentioned that.

That wasn't happening in the Feb 12th build I used before, so something but have broken recently in it.
User avatar
sinisterseed
GZDoom RO Translator & Raze Tester
 
Joined: 05 Nov 2019
Twitch ID: sixhundredsixteen
Github ID: sinisterseed
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby Rachael » Fri Mar 13, 2020 4:18 am

mjr4077au wrote:So, because I was at home and bored, I've had a go at merging this commit, and a few others that pertain to the main change in 8551. Effectively, these patches merge 8551, 8552, 8554, 8555, 8565, 8605 & 8619.

The mouse handles amazingly and the game feels exactly like GZDoom now in terms of mouse input.

During testing, I get some weird stuttering when moving forward, backwards or sideways (mouse input was never affected) that seems to be something to do with the FPS limiter in the engine. Setting it from 200 or uncapped and to say, 60Hz (my refresh rate) seems to make it go away. I need to have a further look but welcome extra eyes as I'm reaching a knowledge cap.

Pre-compiled binary for testing is here.

Can you do this as a pull request instead of diffs?
User avatar
Rachael
Webmaster
 
Joined: 13 Jan 2004
Discord: Rachael#3767
Twitch ID: madamerachelle
Github ID: madame-rachelle
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby mjr4077au » Fri Mar 13, 2020 4:24 am

Last edited by mjr4077au on Sun Mar 15, 2020 2:32 pm, edited 1 time in total.
User avatar
mjr4077au
 
Joined: 17 Jun 2019
Location: Gosford NSW, Australia
Discord: mjr4077au#1027
Github ID: mjr4077au
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby Rachael » Fri Mar 13, 2020 5:52 am

Thank you.
User avatar
Rachael
Webmaster
 
Joined: 13 Jan 2004
Discord: Rachael#3767
Twitch ID: madamerachelle
Github ID: madame-rachelle
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Merge in SVN commit 8551

Postby mjr4077au » Fri Mar 13, 2020 10:39 pm

I've isolated the Raze-specific requirements for these SVN commits and adjusted the pull request accordingly. This works very nicely!

Download to pre-compiled binary to test out: https://drive.google.com/file/d/1yy7FDb8OsZQiVG9zqvolftbTh_6BrSOd/view?usp=sharing
Submitted pull request for those interested: https://github.com/coelckers/Raze/pull/14

All upstream code credits to Terminx, I've just merged his work.
User avatar
mjr4077au
 
Joined: 17 Jun 2019
Location: Gosford NSW, Australia
Discord: mjr4077au#1027
Github ID: mjr4077au
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support


Return to Closed Feature Suggestions

Who is online

Users browsing this forum: No registered users and 0 guests