Matrix3D Matrix3D::_CreateTranslateAlongWorldForward(double fAmt) { Matrix3D result; result._SetIdentityMatrix(); // Camera space points down negative Z axis result._POSITION_Z = -fAmt; return result; }
Matrix3D Matrix3D::_CreateRotationAroundWorldForwardVector(double fAmt) { Matrix3D result; result._SetIdentityMatrix(); result.r0c0 = cos(fAmt); result.r0c1 = -sin(fAmt); result.r1c0 = sin(fAmt); result.r1c1 = cos(fAmt); return result; }
Matrix3D Matrix3D::_CreateRotationAroundWorldRightVector(double fAmt) { Matrix3D result; result._SetIdentityMatrix(); result.r1c1 = cos(fAmt); result.r1c2 = -sin(fAmt); result.r2c1 = sin(fAmt); result.r2c2 = cos(fAmt); return result; }
Matrix3D Matrix3D::_CreateRotationAroundWorldUpVector(double fAmt) { Matrix3D result; result._SetIdentityMatrix(); result.r0c0 = cos(fAmt); result.r0c2 = sin(fAmt); result.r2c0 = -sin(fAmt); result.r2c2 = cos(fAmt); return result; }
Matrix3D Matrix3D::_CreateTranslateAlongWorldRight(double fAmt) { Matrix3D result; result._SetIdentityMatrix(); result._POSITION_X = fAmt; return result; }