ApplyMatrix

Multiplies a vector by matrix

VECTOR* ApplyMatrix (
        MATRIX* m,
        SVECTOR* v0,
        VECTOR* v1
)

Arguments

m Pointer to input matrix
v0 Pointer to input short vector
v1 Pointer to result vector

Return Value

The vector product v1 is returned.

Explanation

The short vector v0 is multiplied by the matrix m beginning with the rightmost end.
The product is stored in vector v1.
The argument format is as follows:


    m->m[i][j] : (1,3,12)
    v0->vx,vy,vz : (1,15,0)
    v1->vx,vy,vz : (1,31,0)

Notes

This function destroys the rotation matrix.

See Also

MATRIX, SVECTOR, VECTOR