Unity Products:Amplify Shader Editor/Transform Direction
Jump to navigation
Jump to search
Transform Direction node
The Transform Direction node transforms a given direction vector between different spaces.
Nodes used:
Vertex Normal,
Transform Direction,
World Space Light Dir,
Dot,
Saturate
Node Parameter | Description | Default Value |
---|---|---|
From | Current space from which input vector is on.
|
Object Space |
To | Space for the position to be transformed to.
|
Object Space |
Inverse TBN | To transform from tangent to another space an inverse TBN matrix(Tangent,Binormal,Normal) must be calculated. Inverting matrices in an heavy operation but in this transforms case it can be simplified at the cost of some precision loss. (Only shown on when From is set to Tangent).
|
Fast |
Normalize | Do a Normalize operation over the final calculated vector. | False |
Input | Direction vector in selected input space to be transformed into selected output space. Only visible if the respective input port is not connected. | 0,0,0 |
Input Port | Description | Type |
---|---|---|
In | Direction vector in selected input space to be transformed into selected output space. | Float3 |
Output Port | Description | Type |
---|---|---|
XYZ | Returns the transformed vector in the specified space. | Float3 |
X | Returns only the X component of the transformed vector in the specified space. | Float |
Y | Returns only the Y component of the transformed vector in the specified space. | Float |
Z | Returns only the Z component of the transformed vector in the specified space. | Float |