Search Unity

Question How to remove unnecessary triangles inside mesh

Discussion in 'General Graphics' started by einoiisko, Nov 5, 2022.

  1. einoiisko

    einoiisko

    Joined:
    Dec 20, 2019
    Posts:
    1
    I have created a shader that creates a transparency effect based on vertex positions, but it looks pretty ugly because the mesh that I have is combined from smaller components. Is there a way to automatically get rid of these unnecessary triangles? I would highly appreciate any code examples. Thank you!

    Picture of unnecessary triangles:
    upload_2022-11-5_12-59-1.png

    Here's a picture of resulting artifact. The walls are not seamless when transparency is applied.
    upload_2022-11-5_13-0-49.png