guycalledfrank / bakery-issues

Bug tracker for Bakery
4 stars 0 forks source link

Bakery adding red light on light probes #41

Closed Zurigan closed 3 years ago

Zurigan commented 3 years ago

After Bakery 'Render': image

After Progressive 'Generate Lighting': image

Zurigan commented 3 years ago

This only seems to happen on one of the 3 point lights I have in the scene, makes probes completely unusable.

guycalledfrank commented 3 years ago

If you're in L1 light probe mode, the cause is ringing (colors being inverted from the opposite side). Progressive fixes it by partially losing directionality (blurring the probe further). But you can: a) Use Legacy light probe mode instead of L1: https://geom.io/bakery/wiki/index.php?title=Manual#Light_probe_mode b) Use Bakery Shader with "Non-linear light probe SH" option which reads the probes in a different way, fixing the ringing: https://geom.io/bakery/wiki/index.php?title=Manual#Bakery_shaders c) Use Volumes instead of the probes: https://geom.io/bakery/wiki/index.php?title=Manual#Bakery_Volume

Zurigan commented 3 years ago

Thanks for the insight ...

a) Isn't usable (throws errors) b) I'm using URP, I found the option you mentioned on the Standard Bakery shader ... Is there a URP / ShaderGraph equivalent? Assuming there is a way to do this, the reason for using probes was for performance on mobile platforms - would this be suitable still? c) Volumes look neat but the 'medium' GPU level of complexity & (presumably) higher texture storage space reqs were putting me off using them for my target devices/platforms.

guycalledfrank commented 3 years ago

a) Just fixed (see the issue) b) Hmm, yeah, I don't have this option for URP for now. But since it's not that hard to add... here you go, try it (BakeryURPNonLinearLightProbe): https://drive.google.com/file/d/14gKWpEl_adF0euOMHLbGBcF7Fqm310Jb/view?usp=sharing c) "Medium" is a very coarse estimate, they are still pretty cheap. I'd recommend benchmarking on the actual device. Modern mobiles will have no problems with them.

BTW, if you're not using lots of dynamic point/spot lights and dynamic shadows, there is no performance benefit of using URP over standard RP.

Zurigan commented 3 years ago

Much improved with the BakeryURPNonLinearLightProbe shader.

Before with probes showing: image

Before with probes hidden: image

After: image

Still a little more pink than she should be but, again, probably below the level where anyone notices!