All dynamic lights are normal lights

Forum rules
Please construct and post a simple demo whenever possible for all bug reports. Please provide links to everything.

If you can include a wad demonstrating the problem, please do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.

Please make a new topic for every bug. Don't combine multiple bugs into a single topic. Thanks!

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: All dynamic lights are normal lights

Re: All dynamic lights are normal lights

by Rachael » Wed Feb 28, 2018 6:50 am

That's the only thing that makes sense. It feels way too hand-holdy to me, though, but hey I wasn't the one who designed them.

I would've done it so that a red subtractive light results in a proper cyan blob from the source.

Re: All dynamic lights are normal lights

by Graf Zahl » Wed Feb 28, 2018 6:47 am

Rachael wrote:I think you can, dpJudas. But remember one thing about subtractive lights:

No matter what colour they are, their hue is flipped 180 degrees. I don't know the exact design decisions behind that
I think Timmie did it so that the effect it generates corresponds to the given color, i.e. make a red subtractive light and you get a red shadow.

Re: All dynamic lights are normal lights

by Rachael » Wed Feb 28, 2018 6:39 am

I think you can, dpJudas. But remember one thing about subtractive lights:

No matter what colour they are, their hue is flipped 180 degrees. I don't know the exact design decisions behind that, it actually kind of frustrates me, but that is what it is. So a subtractive light of (255,0,0) actually renders as (0,255,255) in the engine. I can give some quicky math formulae if you need to preserve the luminosity and saturation values while flipping the hues, without actually breaking the colours down into HSV values.

Re: All dynamic lights are normal lights

by dpJudas » Wed Feb 28, 2018 4:50 am

Makes sense. I wonder if I could get away with desaturating the light color when building the light list for the drawer. And thinking about it, maybe I can support subtractive lights by making the light color a negative value.

Re: All dynamic lights are normal lights

by Graf Zahl » Wed Feb 28, 2018 4:30 am

I don't think that handling additive lights is necessary. But subtractive lights are better skipped entirely instead of rendering them additively - that only increases the perception of faulty behavior.

Regarding the desaturation that has been mentioned - that is related to the sector color desaturation feature. To make lights look right it also needs to apply to the light being emitted by objects whose color got desaturated. Having a grayed version of a BFG projectile emit bright green light just looks wrong.

Re: All dynamic lights are normal lights

by Xane123 » Sun Sep 17, 2017 5:00 pm

Hmm, maybe that should be a toggle-able option to enable/disable having additive/subtractive lights. I agree about how they look, though; The software renderer's idea of "fog" and how the lights look are totally different than the OpenGL renderer.

Maybe the fog should be altered for consistency too but this isn't a feature request thread, this is a bug report.

Re: All dynamic lights are normal lights

by dpJudas » Sat Sep 16, 2017 5:48 pm

This is a known limitation of the software renderer. It is technically trivial to fix, but I fear it will produce a measurable performance drop in doing so. At least it would require a second set of drawers to prevent that.

For what it is worth, I'm not even sure if the software lights are "normal" or "additive" compared to what the GL renderer does. There seems to be some kind of desaturation involved with normal dynlights, if I read the shader code right. The software renderer does not do that.

All dynamic lights are normal lights

by Xane123 » Sat Sep 16, 2017 3:17 pm

I noticed when going through my levels of my TC today that my second level, a city at nighttime, appeared to be bright instead of the buildings fading out into the darkness below. I went there again and it was fine...I then started suspecting the software render may be rendering the wrong type of light and saw that was what was happening.

I made a test map that has one of each light and saw it was worse than I thought; Normal, additive, and subtractive lights are all rendered as normal dynamic lights in the software renderer!
Software renderer (all lights are the normal type)
Software renderer (all lights are the normal type)
OpenGL (correct)
OpenGL (correct)
Here's the test WAD.
test_badlights.wad
Test WAD. A small room with SHAWN2 and three lights, one of each type.
(1.78 KiB) Downloaded 296 times

Top