- Home /
How SetTexture and [matrix] works in surface shaders
How I can translate this line to surface shaders?
SetTexture[_ReflectionTex] { matrix [_ProjMatrix] combine texture * previous }
I know I can pass the _ProjMatrix from a script using mat.SetMatrix( "_ProjMatrix", mtx);
But I am not sure if the right code in my shader should be this: v.texcoord = mul(_ProjMatrix , v.texcoord );
What exactly do internaly SetTexture with the matrix?
Thanks
Answer by A.Wayne · Apr 22, 2014 at 01:30 PM
you need declare the _ProjMatrix in your shader as a uniform type.
Your answer

Follow this Question
Related Questions
accessing inverse view matrix 1 Answer
UnityObjectToClipPos is inverted? 0 Answers
Shader graph transformation matrix node missing options 1 Answer
Getting the forward position of an object in a vertex shader 0 Answers
How to swap out RGB colors of a sprite using ShaderGraph? (Like in Among Us) 3 Answers