I'm new to shader, so please pardon my lack of knowledge. I am trying to understand what does UV node do in shader graph. I tried searching on google and in https://docs.unity3d.com/Packages/[email protected]/manual/UV-Node.html it was written:
Provides access to the mesh vertex or fragment's UV coordinates. The coordinate channel of the output value can be selected with the Channel dropdown parameter.
Ok so UV node provide access to mesh vertex UV coordinates, then i google what is UV coordinate and in https://docs.unity3d.com/ScriptReference/Mesh-uv.html it was written
Unity stores UVs in 0-1 space. [0,0] represents the bottom-left corner of the texture, and [1,1] represents the top-right. Values are not clamped; you can use values below 0 and above 1 if needed
Ok so UV coordinate is vector2 which represent the 2D coordinate between [0,0] and [1,1]. But in shader graph UV node output vector4 instead of vector2.
Where is the error of my understanding? If UV Node supposedly provide access to mesh vertex UV coordinate, then why did it output Vector4 instead of Vector2? can someone please help me clear this confusion ?