Реферат: Трехмерная графика Теория
res.x [0][0] = axis.x * axis.x + ( 1 - axis.x * axis.x ) * Cosine;
res.x [0][1] = axis.x * axis.y * ( 1 - Cosine ) + axis.z * Sine;
res.x [0][2] = axis.x * axis.z * ( 1 - Cosine ) - axis.y * Sine;
res.x [0][3] = 0;
res.x [1][0] = axis.x * axis.y * ( 1 - Cosine ) - axis.z * Sine;
res.x [1][1] = axis.y * axis.y + ( 1 - axis.y * axis.y ) * Cosine;
res.x [1][2] = axis.y * axis.z * ( 1 - Cosine ) + axis.x * Sine;
res.x [1][3] = 0;
res.x [2][0] = axis.x * axis.z * ( 1 - Cosine ) + axis.y * Sine;
res.x [2][1] = axis.y * axis.z * ( 1 - Cosine ) - axis.x * Sine;
res.x [2][2] = axis.z * axis.z + ( 1 - axis.z * axis.z ) * Cosine;
res.x [2][3] = 0;
res.x [3][0] = 0;
res.x [3][1] = 0;
res.x [3][2] = 0;
res.x [3][3] = 1;
return res;
};
Matrix MirrorX ()
{
Matrix res ( 1 );
res.x [0][0] = -1;
return res;
};
Matrix MirrorY ()
{
Matrix res ( 1 );
res.x [1][1] = -1;
return res;