Replies: 6 comments 8 replies
-
Hi, thanks a lot for your input! That is really helpful. And I am glad it was of some use. 😊 If you are able to and you have the code ready anyways, it would be nice if you could start a pull request with these changes. And I will pick up on it. Either way I will try to find the time for this. The Unity API is unfortunately very different between the pipelines which makes it extra hard to get into it as I am currently not using it on a daily basis. |
Beta Was this translation helpful? Give feedback.
-
Hi I'll try to have a look at it in the coming days :) Also please bear with me as this would be my first pull request. |
Beta Was this translation helpful? Give feedback.
-
I've been trying to set it up here 0b3012b |
Beta Was this translation helpful? Give feedback.
-
By now I got it working on the feature branch, that's really nice. I will need to split the fullscreen shader into multiple shaders to still work with all of the pipelines though. Writing shaders for all pipelines is a pain at the moment. They are working on it, but it will take more time https://forum.unity.com/threads/block-shaders-surface-shaders-for-srps-and-more-public-demo-now-available.1350497/. Feeling good about getting this done at some point though. Thanks again for your input 😊 |
Beta Was this translation helpful? Give feedback.
-
Implemented with #22 |
Beta Was this translation helpful? Give feedback.
-
Hi!
First off thanks for the repo, it's been super useful to learn about OIT :)
I investigated a bit how to do fullscreen blit in URP and here's what I found, mind you I am currently on 2022.3.8.
In the Execute() function, cmd.Blit() should be replaced by Blitter.BlitCameraTexture().
I'm checking for null material because reopening the scene made it null for some reason. Checking for isPreviewCamera is used to avoid some asserts in the Blitter when selecting objects in the scene.
I also slightly changed OitFullscreenRender.shader to use the _CameraOpaqueTexture and by including Blit.hlsl. This also requires to remove the attributes, varyings, and vertex shader as they are already defined in Blit.hlsl.
which could later then be sampled as such
and that seemed to do the trick for me. Most of it comes from https://docs.unity3d.com/Packages/com.unity.render-pipelines.universal@14.0/manual/renderer-features/how-to-fullscreen-blit.html . Hopefully that applies to your version as well!
Beta Was this translation helpful? Give feedback.
All reactions