Distance-based dyn light fading - performance improvement?

Discuss anything ZDoom-related that doesn't fall into one of the other categories.
Post Reply
User avatar
Nash
 
 
Posts: 17433
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Distance-based dyn light fading - performance improvement?

Post by Nash »



Start at 17:45. Apparently fading dynamic lights in and out this way helps improve performance for UE4. Would a similar approach have any benefits to GZDoom?
User avatar
Rachael
Posts: 13530
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: Distance-based dyn light fading - performance improvemen

Post by Rachael »

I'm not Graf so I don't know as much about GZDoom's lighting system as he does, but I am tempted to say no.

The curse of GZDoom's lighting system, in my opinion, comes from the very thing that was meant to optimize it in the first place: and that's its light list system. Where, instead of processing the entire level for lights in every pixel, it instead has a light list for each surface and only processes those specific lights. The performance chokes when you have to constantly move these lights around, especially if there are a lot of surfaces to move these lights through.

Now, for ye olde Doom and Heretic levels of yore, that's not an issue. The limitations of Vanilla executables were so low that it was impossible to create a level detailed enough to truly tax GZDoom's light system - and these performance optimizations actually 100% make sense. However, with Tormentor667-esque style mapping in the fold, and with surfaces literally everywhere, you're honestly probably just better off doing a completely different system, i.e. linking the lights to a level grid, instead. If such a system were introduced, then it would make far more sense to consider distance fading, but even then, no level has ever used enough dynlights for that to be a problem (unless they were absolutely ape-shit crazy like ibm5155's LOS checker for the fake shadows - but that's obviously an exception more than it is a rule).
Post Reply

Return to “General”