MantisBT - Zandronum
View Issue Details
0000896Zandronum[All Projects] Bugpublic2012-06-24 15:092012-07-07 19:18
Bloax 
 
normaltweakalways
closedno change required 
MicrosoftWindowsXP/Vista/7
98d 
 
0000896: Additive rendering erronously handles pure colors
When an actor with the "Add"itive Renderstyle has a sprite with a pure color range (Eg. The RGB(0,0,0)-RGB(0,255,0) range) - they are handled incorrectly.

Or rather, they may be handled "correctly" - but the result is VERY ugly.

(And yes, I labeled this "Tweak" because the fix would quite literally be a tweak.)
Run AdditiveTest2.pk3, and summon "Testshot" for an example with the pure green range, and "Testshot2" for one with the red one.

They will both clip at the maximum of their color range (Eg. With green at RGB(0,255,0)) And stop increasing in "optical" brightness, since pure red, green or blue aren't the brightest colors one can see. (That is pure white.)

This is most likely a problem with the algorithm (I guess?) that handles the addition of the colors.
Fixing this may very well slow down additive rendering (IFs aren't the lightest of operations), but it'd make things less ugly.

As for how fixing this might work, -I THINK- that having an If (AddColor == OldColor && AddColor != White) and then somehow add the OldColor value to the OTHER colors (Instead of adding x Green to 255 Green, add it to Red/Blue).

Of course I'm silly and I have no idea how this stuff works. But in my little fantasyland bubble of joy, that somehow makes sense.
No tags attached.
? AdditiveTest2.pk3 (3,276) 2012-06-24 15:09
/tracker/file_download.php?file_id=635&type=bug
Issue History
2012-06-24 15:09BloaxNew Issue
2012-06-24 15:09BloaxFile Added: AdditiveTest2.pk3
2012-06-24 15:27Torr SamahoNote Added: 0003840
2012-06-24 15:28Torr SamahoStatusnew => feedback
2012-06-24 22:28BloaxNote Added: 0003848
2012-06-24 22:28BloaxStatusfeedback => new
2012-06-26 20:41Torr SamahoNote Added: 0003857
2012-06-27 00:23BloaxNote Added: 0003861
2012-06-29 23:56Edward-sanNote Added: 0003869
2012-07-06 04:54BloaxNote Added: 0003904
2012-07-07 19:18Torr SamahoNote Added: 0003908
2012-07-07 19:18Torr SamahoStatusnew => closed
2012-07-07 19:18Torr SamahoResolutionopen => no change required

Notes
(0003840)
Torr Samaho   
2012-06-24 15:27   
Is this any different in GZDoom 323?
(0003848)
Bloax   
2012-06-24 22:28   
It's exactly the same. And my best guess is that it's caused by the way the addition is done.
(0003857)
Torr Samaho   
2012-06-26 20:41   
Is it still the same in the latest (G)ZDoom version?
(0003861)
Bloax   
2012-06-27 00:23   
Exactly the same still.
(0003869)
Edward-san   
2012-06-29 23:56   
What about latest gzdoom build?
(0003904)
Bloax   
2012-07-06 04:54   
Boo, slow reply.

But yes, it's exactly the same all around the house.
And even outside of it. (Photoshop, despite its' usually weird, hacky ways - also has this issue.)
(0003908)
Torr Samaho   
2012-07-07 19:18   
Well, if it's the same in Photoshop, I'm pretty sure it's working as intended. If you still think it's a bug, please report it at the ZDoom/GZDoom forum.