Search Unity

Question 2D shader doesn't have a main texture when using a render texture?

Discussion in 'Shader Graph' started by Shack_Man, Aug 13, 2020.

  1. Shack_Man

    Shack_Man

    Joined:
    Jun 7, 2017
    Posts:
    372
    I've been following a couple of tutorials about make a water shader, where a render texture is sampled and applied to the input. In both videos that alone works, but when I try to recreate it, the sprite renderer complains that there is no main texture assigned.
    I know the usual workflow of making a 2D texture and setting the reference to _MainTex, but in this case I want to disregard the original anyway and only use the color etc. from the render texture.

    Any idea why this isn't working? I've tied a bunch of Unity versions and the error is the same