- Home /
Cross Section Shader
I am currently trying to use the cross section shader that was discussed here (bilke's clip.shader) to create a sort of cross section of underground topography.
Currently the shader will cut off one side of a mesh, and replace the inside with a flat colour (1)
I have made a few tweaks to cut off the back-side texture using a new property "depth2" (2)
What I am needing to do, is to also cut off the inner texture as shown in the third picture (edited in paint) (3)
This is the shader I am currently using
I have tried various things, Culling the back, culling the front, various tweaks with the fragment_shader disposing of parts where the normal is facing away from worldview (not shown in this code)
I guess what I am needing to do is have a way to cull the outside, but show the inside (only through the exposed hole)