Go to: Synopsis. Return value. MEL examples.
float[] pointMatrixMult ( float $point[], float $matrix[] )
vector * matrix = result
Note: The matrix is assumed to be a single dimension
array of 16 elements.
Remember: That the arrays are 0-based.
e.g. [1][0] is matrix[4] element
None
Variable Name | Variable Type | Description |
---|---|---|
$point | float[] | Co-ordinates of the point. |
$matrix | float[] | The matrix to be used. |
float $p[] = {1,2,3}; float $m[] = {1,0,0,0,0,2,0,0,0,0,3,0,0,0,0,0}; pointMatrixMult($p, $m); // Results: 1 4 9 //