| layout | stdlib-reference |
|---|
Flip vector to face forward, if needed.
vector<T, N> faceforward<T, N:int>( vector<T, N> n, vector<T, N> i, vector<T, N> ng) where T : __BuiltinFloatingPointType;
T: __BuiltinFloatingPointType {#typeparam-T}
The vector to orient.
The incident vector.
The geometric normal vector.
n if the dot product of ng and i is less than 0, otherwise -n.
Defined for the following targets:
Available in all stages.
Available in all stages.
Available in all stages.
Available in all stages.
Available in all stages.
Available in all stages.
Available in all stages.