Conversion functions for Direction3d
.
toVec3 : Direction3d coordinates -> Math.Vector3.Vec3
Convert a Direction3d
to a Vec3
.
Direction3d.toVec3 Direction3d.y
--> vec3 0 1 0
toVec4 : Direction3d coordinates -> Math.Vector4.Vec4
Convert a Direction3d
to a Vec4
. The resulting Vec4
will have a W
component of 0 so that it is not affected by translation
when performing matrix transformations.
Direction3d.toVec4 Direction3d.y
--> vec4 0 1 0 0