Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice
  3. Dismiss Notice

Question Transparent Issue with Graphics.DrawMeshInstanced

Discussion in 'General Graphics' started by ahmaderfani12, Jan 10, 2022.

  1. ahmaderfani12

    ahmaderfani12

    Joined:
    Nov 16, 2017
    Posts:
    3
    I have been working on a system that uses 'Graphics.DrawMeshInstancedProcedural' to generate many meshes. Everything is OK except for the issue with the transparent shaders. When I set the shader(shader graph) surface to transparent the orders get messed up. I used a technique with ForwardRenderer:


    with that the orders are Ok but some new issue appears on transparent parts:

     
    Last edited: Jan 10, 2022
  2. ahmaderfani12

    ahmaderfani12

    Joined:
    Nov 16, 2017
    Posts:
    3
    OK, I found it :) just use Alpha Clipping(threshold) to prevent rendering those areas.