+1

Can't use _MainTex_ST in Code

ratking 8 years ago 0

I want to use a texture's scaling and offset, but it doesn't work in the Code block of ShaderForge. This is because "uniform sampler2D _MainTex; uniform float4 _MainTex_ST;" get written AFTER the function's code. If I move it just above the function, I can use it, but I lose the connection to ShaderForge