Hello, I have been trying to learn CG shaders, my goal is to set up a additive shader that has a detail texture.
I have made the modifications for a separate Detail texture property. And have the detail multiplied by the particle texture… This works fine, except both the detail and the particle textures have the same coordinates.
Here is the line of code that I changed in the default additive shader:
return 2.0f * i.color * _TintColor * tex2D(_MainTex, i.texcoord) * tex2D(_Detail, i.texcoord);
I am guessing the problem is because both the detail and the particle texture use “i.texcoord”.
Thanks