Search Unity

Question How do I go about creating a shader that turns a pixel the oposite color of the pixel behind it?

Discussion in 'Shaders' started by alex101010000, Aug 20, 2022.

  1. alex101010000

    alex101010000

    Joined:
    Apr 12, 2021
    Posts:
    4
    I am working on a crosshair system and I want the crosshair to always be visible
    I thought a good way to do that would be to have the pixels of the crosshair always be the exact opposte color of what is behind the crosshair

    Using URP and not very used to shaders or HLSL code
     
  2. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,348
  3. alex101010000

    alex101010000

    Joined:
    Apr 12, 2021
    Posts:
    4