Merging / Combining Depth passes #328
Replies: 3 comments 2 replies
-
Hi, I've updated the sandbox. Using multiple depth passes is possible but the trick is to make them render to the same internal frame buffer. Unfortunately, this isn't very intuitive at the moment: if there's a pass that swaps buffers in between two depth passes, the second one will render to the wrong buffer. This type of setup will become easier and more predictable when explicit buffer management gets implemented. |
Beta Was this translation helpful? Give feedback.
-
Thanks!
Anyways, thanks for the fast reply ! I think I can follow your instructions, and if it breaks, I know that I need to check inbetween passes for swapsBuffer. 👍 |
Beta Was this translation helpful? Give feedback.
-
There are no concrete concepts yet, but it's safe to assume that the concept of passes and effects will remain. Passes and effects will likely share the same API to specify input and output buffers, but built-in stuff will still configure this out of the box. The important part is that the user will be able to see and change the exact pipeline and all involved buffers without losing automatic functionality like SSAO's and DoF's access to a shared depth texture. With the new API you'll be able to declare a specific buffer as output for the depth passes and as input for other passes or effects. |
Beta Was this translation helpful? Give feedback.
-
Hi postprocessing community,
Im wandering if there is a way to combine or merge depth passes ?
I need multiple scene render with different selection sets of objects. One in this passes stack is also masked.
Is there a way I could combine each render depth pass into one texture in order to assign this depth texture on the final pass such as it is done in https://codesandbox.io/s/qxqff ( @vanruesc as this is your demo, could you update this codesandox with the missing dependency ? I already forked, but it could be nice for others. This demo was the perfect starting point in my case 👍 )
As the time of writing this question, Im wondering if multiple render pass that only ClearColor would simply do it ?
The multiple render passes im talking about are sorted from farest to nearest, so an overwrite would not be an issue I guess.
Beta Was this translation helpful? Give feedback.
All reactions