cross - chung-leong/qb GitHub Wiki

cross - Cross product

float[3] cross( float[3] $x, float[3] $y )

float[2] cross( float[3] $x, float[3] $y )

float[4] cross( float[3] $x, float[3] $y, float[4] $z )

cross() calculates the cross product of x and y.

Parameters:

x - The first vector. It can be one three-element array or an array of three-element arrays.

y - The second vector. It can be one three-element array or an array of three-element arrays.

Return Value:

The cross product of x and y. The size of the return value will match that of the larger of x and y.

Version

1.0 and above.