Post Processing with oblique frustum
Hi everyone, I'm using 6 cameras with oblique frustums in order to display onto a 240° curved dome screen. I have a script attached to each of the cameras in order to set a custom oblique projection matrix every frame in LateUpdate - the script is the exact same as Unity camera.projectionMatrix.
This works great, though the oblique frustum is no longer applied upon using the Post Processing Stack 2.1.7 with Unity 2018.2.15f1. Adding a Post Process Layer to my cameras applies post processing but renders the final image without the oblique frustum. Here is a video showing a camera rendering with an oblique frustum and post processing - toggling post processing on/off toggles rendering the oblique frustum.
I've tried moving the code to set a custom projection matrix into Update, LateUpdate, and looked into Unity's execution order, but it seems I can't get the oblique projection matrix with post processing. Is this a limitation in the new post processing stack, or post processing in general? Is there a way to get both an oblique frustum and post processing together?
Thanks!
Answer by Tobymeadows · Sep 24, 2019 at 11:25 AM
Hey there! Did you ever get this working. Sounds like I'm in the same boat as you right now
Answer by Wabolas · Sep 24, 2019 at 06:49 PM
Unfortunately not. Judging by no answers or discussion here I was about to try the Unity-relevant Reddit threads.
If I find an answer I'll update here with a link.
Answer by Andrewleek · Feb 02, 2020 at 06:03 PM
This appears to have been a problem for a while. Apparently when using Post Processing effects the camera projection matrix gets reset every frame (OnPreCull). This seems to be necessary for TAA (Temporal Anti-Aliasing) but gets reset when using other forms of AA as well... So if you must use TAA then I dont know if there is a fix but if you are using another AA then you can edit the source to fix it.
I hope this helps...
Check out these links:
https://github.com/Unity-Technologies/PostProcessing/issues/546#issuecomment-528232076