Matrix in Houdini
Matrix in houdini is still just a collection of numbers, the only different is :How you apply this data determines what kind of matrix it is.
There is always 3x3 or 4x4 or QxQ matrix in houdini.
0.3x3 Matrix is:
1.Main type of matrix in houdini.
2.If you want to rotate some points using matrix......
3.If you want to translate something......
The meaning of this matrix is:
4.Identity matrix is a matrix which keeps your positions the same
5.Example rotate geometry using wrangle node.
.In the wrangle node ,the vex script is:
1 //create a identity matrix 'rotY' 2 matrix3 rotY = ident(); 3 4 //Applies a rotation value to the given matrix, here is rotY. 5 //Channel 'rotY_value' is the rotation degree. 6 rotate(rotY, radians(chf('rotY_value')), {0,1,0}); 7 8 @P *= rotY;
6. Set a component of a matrix.
. We can use 'setcomp' in VEX to modify a single component of a exist matrix.
X.* is the X Axis direction vector of this Axis.
Y.* is the Y Axis direction vector of this Axis.
Z.* is the Z Axis direction vector of this Axis.
P.* is the position of this Axis.