Very bad performance with FX-heavy scenes
-
- Lead GZDoom+Raze Developer
- Posts: 49143
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Very bad performance with FX-heavy scenes
It contains a lot of checks. Some use ThinkerIterators, and with 14000 active thinkers on the map they are rather costly.
-
- Posts: 1337
- Joined: Tue Jul 15, 2003 4:18 pm
Re: Very bad performance with FX-heavy scenes
Looking at the FThinkerIterator code, it looks like if I assign a specific statnum to certain actor types, then only iterate over that statnum, then the iterator would have less to process... Is that correct?
-
- Lead GZDoom+Raze Developer
- Posts: 49143
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Very bad performance with FX-heavy scenes
Yes. You only have to be careful where to put stuff. Normally, anything between 80 and STAT_DEFAULT should be fine if it's actually thinking. Higher numbers than STAT_DEFAULT should be used with care, though. because the stuff in there depends on running after the game actors.
The numbers between STAT_DLIGHT and 80 should be left alone in case the engine needs to allocate new numbers.
The numbers between STAT_DLIGHT and 80 should be left alone in case the engine needs to allocate new numbers.
-
-
- Posts: 10773
- Joined: Sun Jul 20, 2003 12:15 pm
Re: Very bad performance with FX-heavy scenes
Hmm, this got me thinking -- is there a way in ZScript to limit visibility of an actor to a particular player? There's a map in The Adventures of Square (E1A6) with some annoyingly misperformant rain effects, and a multiplayer-safe way of limiting the spawns to a radius around the player sounds like it'd be worth exploring.Rachael wrote:A lot of what you want to do can be done simply with intense fog and at most 3 or 4 large sprites projected out in front of the player.
-
- Lead GZDoom+Raze Developer
- Posts: 49143
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Very bad performance with FX-heavy scenes
You cannot have actors spawn for one player and not the others and have it sync-safe.
-
- Posts: 2067
- Joined: Thu Jul 04, 2013 8:01 am
- Graphics Processor: nVidia with Vulkan support
- Location: Mount Olympus, Mars
Re: Very bad performance with FX-heavy scenes
Ok I have finally had the opportunity to test recent fixes done by AFA (yesterday ones) and I must admit that perfomance has increased a bit (on the old c2m5 map, Torm has already split it in 2 maps right now)...
Don't know if these would be of use for you, but here you are some crappy tests I did with stat think, stat rendertimes, stat fps and stat fps_accumulated on
I was even in the way to post becnhmarks, but while I am quite sure that these won't be of really use for you I thought it was good for comparison in general.
FYI here you are my specs:
Don't know if these would be of use for you, but here you are some crappy tests I did with stat think, stat rendertimes, stat fps and stat fps_accumulated on
I was even in the way to post becnhmarks, but while I am quite sure that these won't be of really use for you I thought it was good for comparison in general.
FYI here you are my specs:
- Windows 7 64bit sp1 Ultimate
- AMD Athlon X2 250 3ghz Dual Core
- GeForce GT-610 1024mb Palit (updated)
- 4gb Ram ddr3 1333mhz single bank
-
- Posts: 13548
- Joined: Wed Jul 16, 2003 3:52 am
Re: Very bad performance with FX-heavy scenes
I want to thank everyone involved in this for your help and technical support. Graf Zahl's improvement on the engine really gained a lot of speed and so do AFADoomer's and Virgilio's code changes according to the suggestions being made here. I also splitted the map now into two pieces which did the rest to it and making the map now run in a very reasonable speed.
Thanks kindly!
Thanks kindly!
-
- Posts: 13736
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: Very bad performance with FX-heavy scenes
I'm trying it out now - I played from the beginning shooting at the snipers until the transition from the train itself to the train depot in C2M5_B - and so far, the engine feels a lot smoother and a LOT more natural. I think you guys really hit it here - good job.
-
-
- Posts: 17456
- Joined: Mon Oct 27, 2003 12:07 am
- Location: Kuala Lumpur, Malaysia
Re: Very bad performance with FX-heavy scenes
The intro fly-by cutscene of Episode 2 still runs 18 - 30 FPS for me...
Seems like SSAO is the biggest drain for my computer. Turning off SSAO, I get 24 - 45 FPS for the Episode 2 intro cutscene.
Seems like SSAO is the biggest drain for my computer. Turning off SSAO, I get 24 - 45 FPS for the Episode 2 intro cutscene.
-
- Posts: 13736
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: Very bad performance with FX-heavy scenes
Here's an issue I discovered with the newly split maps: C2M5_B - at the player start, turn around and view the sky - this is pretty glaringly visible.
You do not have the required permissions to view the files attached to this post.
-
- Posts: 13548
- Joined: Wed Jul 16, 2003 3:52 am
Re: Very bad performance with FX-heavy scenes
Thanks, should be fixed now.
For the intro sequence in C2M1, I'd really like to know what could be done here. I mean, it's not only the intro, you play that part later...
For the intro sequence in C2M1, I'd really like to know what could be done here. I mean, it's not only the intro, you play that part later...
-
- Lead GZDoom+Raze Developer
- Posts: 49143
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Very bad performance with FX-heavy scenes
That intro looks mostly ok for me, the exception being the snow which really drags it down badly - very badly.
One other thing you may try is to assign some decoration actors that will definitely never, ever move, to STAT_INFO, that will also save some time, but be careful: Do this only when you are absolutely 100% sure that it's ok.
One other thing you may try is to assign some decoration actors that will definitely never, ever move, to STAT_INFO, that will also save some time, but be careful: Do this only when you are absolutely 100% sure that it's ok.
-
-
- Posts: 10773
- Joined: Sun Jul 20, 2003 12:15 pm
Re: Very bad performance with FX-heavy scenes
Uh, yeah. That's why I'm asking about visibility of actors -- the actors need to spawn, but the raindrops clustering around Player 1 need to not be visible by Player 2, and vice-versa.Graf Zahl wrote:You cannot have actors spawn for one player and not the others and have it sync-safe.
This may not be a thing that exists (yet?), but I was curious if there was some underlying ZScript-controllable stuff the "VisibleTo[x]" actor properties wrap that allow for fine-grained control.
-
- Lead GZDoom+Raze Developer
- Posts: 49143
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Very bad performance with FX-heavy scenes
That won't help you. It's not the rendering but the movement causing the problems.
-
- Posts: 1337
- Joined: Tue Jul 15, 2003 4:18 pm
Re: Very bad performance with FX-heavy scenes
I think you're essentially asking for DistanceCheck-like handling, but tied to player actors instead of a distance.
I don't think it's the visibility that's the problem... It's the fact that so many actors are spawning. Even if they're not visible (like when DistanceCheck keeps an actor from rendering), the actor is still present, and all of the internal actor mechanics are still firing, and that's what causes processing delay.
EDIT: ninja'd by Graf...
I don't think it's the visibility that's the problem... It's the fact that so many actors are spawning. Even if they're not visible (like when DistanceCheck keeps an actor from rendering), the actor is still present, and all of the internal actor mechanics are still firing, and that's what causes processing delay.
EDIT: ninja'd by Graf...