0

I am trying to create two clipping planes so that a cube is visually reduced in size from both ends when I change two floats. Currently no matter what I try it clips from the inside out.

Here is the current method of clipping:(https://i.stack.imgur.com/Uooe2.png) [I took it and modified it slightly from this video: https://www.youtube.com/watch?v=EweVg3hXRQk] I've tried every combination of node positioning (flipping inputs around at the subtract node), multiplying the floats by -1 in different combinations, a final add node before the alpha input, a final subtract node before the alpha input, different outputs from the split node. All I've succeeded in is getting two different planes to clip (eg XZ and YZ) and clipping from the inside out, rather than the outside in I need. I've also tried two different scripting methods not related to shader graph, but the ones I could find were written with an older version of unity in mind, and I can't get too work since my coding is not as strong as I would like, so I've gotten the closest to my desired result with this shader graph method.

  • There is something similar in [this](https://www.youtube.com/watch?v=szsWx9IQVDI) video using _custom renderers_ without code. –  Nov 24 '22 at 23:52

0 Answers0