Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feature] implement multithreaded renderrer #2058

Open
elf-alchemist opened this issue Nov 29, 2024 · 10 comments
Open

[feature] implement multithreaded renderrer #2058

elf-alchemist opened this issue Nov 29, 2024 · 10 comments

Comments

@elf-alchemist
Copy link
Contributor

Certainly a big ask to make, but I'd like to see Woof able to run with even greater performance, allowing for higher resolution, higher framerate, lower frametime, smoother experience on any WAD's maps of basically any size and complexity. I will understand if the devs deem this out of scope for Woof, but I believe it would be of great value to have great performance without sacrificing the vanilla renderer tricks and the tools and behaviors that were built on top of it, for example, any custom Boom TRANMAP tricks are (and correct me if I'm wrong) effectively useless in truecolor and hardware renderers.

https://doomwiki.org/wiki/Multithreaded_renderer

@rfomin
Copy link
Collaborator

rfomin commented Nov 30, 2024

Yes, we have plans for a multi-threaded renderer, similar to the KEX port or Rum and Raisin Doom.

smoother experience on any WAD's maps of basically any size and complexity.

Multi-threaded renderer improves performance at high resolutions. If WAD is slow at 100% resolution scale (320x200), it won't improve. Just to keep expectations in check.

@elf-alchemist
Copy link
Contributor Author

Multi-threaded renderer improves performance at high resolutions. If WAD is slow at 100% resolution scale (320x200), it won't improve. Just to keep expectations in check.

Ah, I see, thank you for the FYI.

@Kappa971
Copy link

I think this should be a high priority (gamer opinion). Currently performance is unsatisfactory compared to dsda-doom's hardware renderer or Eternity Engine's multi-threaded software renderer (CPU AMD R7 5700x).
In this scene from Eviternity, there are noticeable performance drops with Woof with Resolution Scale set to Max (is Max the native resolution?):

Image

@elf-alchemist
Copy link
Contributor Author

I think this should be a high priority (gamer opinion). Currently performance is unsatisfactory compared to dsda-doom's hardware renderer or Eternity Engine's multi-threaded software renderer (CPU AMD R7 5700x). In this scene from Eviternity, there are noticeable performance drops with Woof with Resolution Scale set to Max (is Max the native resolution?):

Funny you should say this, just now, I had recently arrived on MAP25 on my own Eviternity playthrough 😛. When looking in that particular direction, full of the tree Things, my T480 struggles to maintain a consistent >50FPS without lowering the resolution and turning off translucency and smooth pixel scaling.

Also, can you send in some performance numbers on that same area in DSDA's and EE's plain software renderer, as well as their hardware and multilthreaded ones, if possible? For future reference reference's sake, that is.

@rfomin
Copy link
Collaborator

rfomin commented Jan 21, 2025

In this scene from Eviternity, there are noticeable performance drops with Woof with Resolution Scale set to Max (is Max the native resolution?):

It's not native, but it's the closest. Due to aspect ratio correction, it is not feasible to get perfect 1:1 square pixels (see https://doomwiki.org/wiki/Aspect_ratio). It's not necessary to set the resolution to MAX, try 400% or 300% - you'll get better performance with not so noticeable difference.

my T480 struggles to maintain a consistent >50FPS without lowering the resolution and turning off translucency and smooth pixel scaling.

There is not much translucency in Eviternity, it should not affect the performance. You don't have a dedicated GPU? Smooth pixel scaling is done on the GPU and is usually almost free.

There are plans to implement a multithreaded renderer, but it will probably take a while.

@elf-alchemist
Copy link
Contributor Author

There is not much translucency in Eviternity, it should not affect the performance. You don't have a dedicated GPU? Smooth pixel scaling is done on the GPU and is usually almost free.

No, my ThinkPad T480 is running on a Intel i5 8350U, with integrated UHD 620 graphics. I'm not quite sure why, but yes, disable both smooth pixel scaling and translucency helped the framerate on Max resolution in that specific scene on Eviternity MAP25.

@Kappa971
Copy link

Also, can you send in some performance numbers on that same area in DSDA's and EE's plain software renderer, as well as their hardware and multilthreaded ones, if possible? For future reference reference's sake, that is.

DSDA-Doom (OpenGL) in the same scene does 128 fps, before it did fixed 144 fps, I don't know why now it goes slower (probably depends on some Windows update or AMD video drivers that have improved the performance 😒).

Eternity Engine 165 fps with 8 thread (I don't know why it crashes if I try to change the number of threads from the game menu instead of the config file).

@elf-alchemist
Copy link
Contributor Author

I'm not quite sure why, but yes, disable both smooth pixel scaling and translucency helped the framerate on Max resolution in that specific scene on Eviternity MAP25.

Forgive me, I was mistaken and remembered incorrectly, translucency, did not affect my performance. And smooth scaling only affected me in non-Max resolution settings, i.e. 300%, 400%, etc.

DSDA-Doom (OpenGL) in the same scene does 128 fps, before it did fixed 144 fps, I don't know why now it goes slower (probably depends on some Windows update or AMD video drivers that have improved the performance 😒).

Eternity Engine 165 fps with 8 thread (I don't know why it crashes if I try to change the number of threads from the game menu instead of the config file).

Thank you! Can you check how they perform on the normal software renderer?

@Kappa971
Copy link

Kappa971 commented Jan 21, 2025

Thank you! Can you check how they perform on the normal software renderer?

Comparing the same scene from fastest to slowest:

  1. Eternity Engine (Software 8 thread) 165 fps
  2. DSDA-Doom (OpenGL) 128 fps
  3. Woof (Software) 104 fps
  4. DSDA-Doom (software) 84 fps

@Kappa971
Copy link

If DSDA-Doom could use multi-threaded rendering in OpenGL, performance would improve dramatically by taking advantage of the graphics card's power even more (surely those 128 fps are a symptom of a CPU bottleneck).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants