Search Unity

Question Custom triplanar shader: texture changes color/value when rotating model?

Discussion in 'Shaders' started by merrymoogle27, Mar 7, 2023.

  1. merrymoogle27

    merrymoogle27

    Joined:
    Feb 14, 2016
    Posts:
    4
    Hello! So I'm creating a simple triplanar shader, and am having issues with the texture becoming darker/lighter depending on the rotation of the model. Each piece of this kit is intended to be rotated, but when it is, the piece of grass on the right, the color becomes lighter. But when rotated to the same rotation as the other pieces, it returns to the same color/value.

    Any sort of insight would be greatly appreciated!
    Triplanar shader 01.JPG Triplanar shader 02.JPG Triplanar shader 03.JPG
     
    Last edited: Mar 7, 2023
  2. merrymoogle27

    merrymoogle27

    Joined:
    Feb 14, 2016
    Posts:
    4
    Wow, okay. fixed it. I disconnected the normal stuff and it's fine now. I was following a tutorial that set the normals up this way
     
  3. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,352
    The Triplanar node Type was set to Default for the normal map sampling. It should be in the Normal mode.
     
  4. merrymoogle27

    merrymoogle27

    Joined:
    Feb 14, 2016
    Posts:
    4
    Oh wow, duh, can't believe I missed that. Thanks!