T3D 1.1 Beta 3 - ScatterSky banding with HDR enabled
by Daniel Buckmaster · in Torque 3D Professional · 03/09/2011 (7:54 pm) · 10 replies
Build: 1.1 Beta 3
Platform: Windows 7 64 bit (OSX...?)
Target: World Editor, PostFx manager, ScatterSky, HDR
Issue: when HDR is enabled by default in a PostFx preset, a ScatterSky will show banding artefacts.
Steps to repeat:
(Just in the process of double-checking this report...)
Original message:
Not sure if this is a bug or just something I'm doing wrong. I've been playing around with the PostFx manager, enabling HDR and stuff. I saved my new settings over the default.postfxpreset.cs file in core/scripts/client/postfx, and reloaded the level. Now the ScatterSky in the default Empty Terrain level (from the Full template) is displaying a strange sort of colour banding:

If I go into the PostFx manager and toggle HDR, the sky goes back to normal. I'll be doing some more investigating over the weekend; just thought I'd ask if I was doing anything blatantly wrong first.
Platform: Windows 7 64 bit (OSX...?)
Target: World Editor, PostFx manager, ScatterSky, HDR
Issue: when HDR is enabled by default in a PostFx preset, a ScatterSky will show banding artefacts.
Steps to repeat:
- New project, Full template
- Open World Editor in Empty Terrain level, open PostFx manager, select HDR tab, check enable
- Save PostFx presets over core/scripts/client/postfx/default.postfxpreset.cs
- Reload mission
- (Optional) Go back to HDR tab of PostFx manager, uncheck and check enabled, ScatterSky should return to normal
(Just in the process of double-checking this report...)
Original message:
Not sure if this is a bug or just something I'm doing wrong. I've been playing around with the PostFx manager, enabling HDR and stuff. I saved my new settings over the default.postfxpreset.cs file in core/scripts/client/postfx, and reloaded the level. Now the ScatterSky in the default Empty Terrain level (from the Full template) is displaying a strange sort of colour banding:

If I go into the PostFx manager and toggle HDR, the sky goes back to normal. I'll be doing some more investigating over the weekend; just thought I'd ask if I was doing anything blatantly wrong first.
About the author
Studying mechatronic engineering and computer science at the University of Sydney. Game development is probably my most time-consuming hobby!
#2
Sadly on my Mac here I get no HDR (or any PostFX) so I can't test/fix much, nor am I all that familiar with the postfx shader chain but...what precision are all of the buffers stored in? If you're taking a RGBA8888 buffer and doing a bunch of math on it you end up capping values until you get nasty banding similar to that...
03/10/2011 (10:15 am)
Looks like a precision issue in the HDR shader...Sadly on my Mac here I get no HDR (or any PostFX) so I can't test/fix much, nor am I all that familiar with the postfx shader chain but...what precision are all of the buffers stored in? If you're taking a RGBA8888 buffer and doing a bunch of math on it you end up capping values until you get nasty banding similar to that...
#3
03/11/2011 (10:17 pm)
The strange thing is each band seems to have a gradient... it's just that the gradient is applied in the wrong direction.
#5
03/12/2011 (12:26 am)
Since others have seen this, I'm going to edit it into a proper bug report.
#7
03/12/2011 (2:52 am)
Nope, no idea :P. I know very little about the shader pipeline.
#9
$pref::PostEffect::PreferedHDRFormat = "GFXFormatR16G16B16A16F";
10/28/2011 (1:13 am)
Not sure if it works for your issue but try setting:$pref::PostEffect::PreferedHDRFormat = "GFXFormatR16G16B16A16F";
#10
Still you will get some banding with HDR in extreme cases... i can see it even in like Battlefield 3.
11/01/2011 (11:52 pm)
I suspect this is a subtle bug in the scatter sky shader calculations that is really apparent when HDR is enabled.Still you will get some banding with HDR in extreme cases... i can see it even in like Battlefield 3.
Torque Owner deepscratch
DeepScratchStudios
quite distracting,
never found a way to correct it.
its realy bad in a night scene.