Search Unity

Question SpriteRenderer Flip

Discussion in 'Shader Graph' started by sanbox, Apr 22, 2019.

  1. sanbox

    sanbox

    Joined:
    Oct 22, 2018
    Posts:
    5
    Hello!

    I'm trying to get a shader to take in the SpriteRenderer's `_Flip` fixed2. In the past, just kinda hacking it by naming a property worked just fine, but just asking for a Vector2 named "_Flip" doesn't seem to get me anything, and writing my own custom node had some...weird issues.

    Trying just to do something as simple as

    Code (CSharp):
    1. #include "UnitySprites.cginc"
    gave me tons of errors saying "fixed4" not recognized as a token, which was weird.

    I could just do my own flip and pass it in with a property block, but it seems like redundant work!

    Thanks so much all!