Unity Products:Amplify Shader Editor/Vertex Position
Vertex Position Node
The Vertex Position node outputs the vertices position in object space. This data is extracted directly from the mesh and contains the vertex position relative to the object origin, this means the position values don't change whatever transform value your gameobject has. This is usually useful to use in the Local Vertex Offset output or to create effects that are bound to the object and stay exactly the same even if your gameobject changes position, rotation or size.
Depending on where this node is being used ( vertex or fragment/surface function ) it will either return a direct value ( on vertex functions ) or an interpolated value between vertices( on fragment/surface functions ).
NOTE: Do not confuse with World Position node.
Nodes used:
Texture Sample,
Vertex Position,
Saturate,
Lerp
Input Port | Description | Type |
---|---|---|
Size | The size of the position vector.
|
XYZ |
Output Port | Description | Type |
---|---|---|
XYZ(W) | Returns the vertex position in object space | Float3(4) |
X | Returns only the X component of the vertex position | Float |
Y | Returns only the Y component of the vertex position | Float |
Z | Returns only the Z component of the vertex position | Float |
W | Returns only the W component of the vertex position (By default set to 1). Only visible if Size is set to XYZW. | Float |