Search Unity

Question Partially Render a model

Discussion in 'General Graphics' started by SEPPEL007, Feb 5, 2021.

  1. SEPPEL007

    SEPPEL007

    Joined:
    Dec 11, 2020
    Posts:
    2
    Hi, i am very new to Unity and graphics in general.

    I need to render a model and be able to "slice" it in real time.
    For example i need to see the front 80% of the model (rest should be invisible) and than change it so i can see more or less of the model. And i need to see edge between the visible and the invisible part.

    I already tried something with DepthMasks, but that just makes everthing behind it invisible, so not exactly what i need.

    I thought about editing the mesh in real time, but i dont think that is possible with a complex model.

    Any help is appreciated.
     
  2. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,352
    The term you'll want to search for is "cross section shader".
     
    SEPPEL007 likes this.
  3. SEPPEL007

    SEPPEL007

    Joined:
    Dec 11, 2020
    Posts:
    2
    thank you, thats exactly what i need!