owlboy / greatpug-public

A Bar in the Metaverse (VRChat)
http://thegreatpug.com
53 stars 6 forks source link

Bloom bugged in Post Processing Stack v2 #14

Closed morerokk closed 5 years ago

morerokk commented 5 years ago

The Great Pug was recently updated to use Post Processing Stack v2. However, the bloom function in PPS v2 seems to be bugged in VRChat, causing weird reflections of your screen on loading avatars and player capsules. Sometimes these textures can align in a way that causes blinding lights, especially in VR.

Example 1

Example 2

Unfortunately, the only ways for world creators to fix this seems to be either switching back to v1, disabling the bloom, or waiting for the VRC devs to fix this.

KorroBravin commented 5 years ago

This can be mitigated by using the clamping feature for the bloom

owlboy commented 5 years ago

I have that turned on, but I guess I need to be much more aggressive.

Also, does that address the weird broken shaders on selection capsules and the loading avatar. Just the bloom response to them.

I also have the NaN protection turned on.

hackspanner commented 5 years ago

What layers does the PP volume affect? Make sure UI and local players are off.

owlboy commented 5 years ago

What layers does the PP volume affect? Make sure UI and local players are off.

Where do you set what layers it affects? Is it not a camera effect that happens in screen space?

I have the objects on the Player Local Layer so that the player can hit the volumes. I assume the camera is on this layer too, and that is the object running into the volumes.

Also, my main one is Global.

owlboy commented 5 years ago

Oh I see.

screen shot 2018-12-30 at 3 25 12 pm

So do I have to use a totally separate new layer? I thought this was just for detecting collision. Not for what is actually changed by the effect. Why does this cause the shaders to break?

owlboy commented 5 years ago

A comment from Discord about the shaders that are able to make ridiculous bloom amounts:

Silent Today at 12:38 AM

Yeah, as far as I can tell, the shader used for player capsule/blue man is bugged somehow If it was a NaN error it would be filtered out. I think it's more likely some bad math in the shader, like the highlight is being done using a fresnel calculation but the input isn't normalised or something like that

owlboy commented 5 years ago

Bloom is now very clamped/limited.

The shader used for loading avatars and selection capsules needs to be fixed by VRChat. It collides with the post-processing behavior and has collided or had similar issues over the past few years in various edge cases. The shader is in their control to adjust so that it is more resilient.

owlboy commented 5 years ago

I’ve received word that this is will likely be fixed in a coming update! This means it will be fixed for all worlds too.

morerokk commented 5 years ago

This has indeed been fixed in one of the latest VRChat updates, although it was not mentioned in the patch notes.