Raymarching + Z Buffer [SOLVED]

Hi,

I wonder how can i render Raymarched objects to Z Buffer?
I use forward rendering.
I have a cube with a raymarching shader on it. So there’re some shapes rendered inside that cube.
How can I make an additional pass and render the depth of those shapes into Z Buffer that everything will fit into scene geometry ?

Best,
Vladimir.

ok, I found lol

Thanks for answering your own question, I also needed this! Perfect :slight_smile: