I am getting 3 angles from another system that I need to convert into a 3x3 rotation matrix.
Here is the diagram:
P is the point where all angles are 0.
A is the tilt angle limited to the angles 0 to 90 degrees.
B is the angle that A is applied in. Note B does not rotate the object itself. If A's value is zero then this angle does nothing. Range is 0 to 180 anticlockwise and 0 to -180 clockwise.
C is the rotation around P. Same ranges as B. This rotation is applied first.
In short, rotate object around P by C, then tilt by A in the direction of B.
Let me know if you need more info.
Edit: I'll start off with what I have got already and that is the C rotation. Pretty easy for that one as it is just the rotation around the Z axis.
$\begin{pmatrix} \cos(C)&-\sin(C)&0\\ \sin(C)&\cos(C)&0\\ 0&0&1\end{pmatrix}$
That works for my purposes but I am unsure of how to convert the other angles to a matrix so I can multiply the two together.