Search Unity

Gradient transparency doesn't hide self backward polygons

Discussion in 'General Graphics' started by Entretoize, Nov 3, 2020.

  1. Entretoize

    Entretoize

    Joined:
    Feb 27, 2015
    Posts:
    59
    Hello, I'm building a VR game and I need to display the hands but not the arm, and I don't want to have just "flying hands" like in Alyx, then I want to have a gradient transparency along the forearms.
    I'm using the "Standard (specular setup)" shader with a semii transparent png, it works except that the backward polygons (not backface) are visible.
    Can I correct the issue with that shader or must I use a custom one ?
    I tried to enable zwrite and disable ztest like that :

    m.SetInt("_ZWrite", 1);
    m.DisableKeyword("_ALPHATEST_ON");

    But that doesn't help.

    Thanks