]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - matrixlib.c
add a helper function to release all keys "properly"
[xonotic/darkplaces.git] / matrixlib.c
index e15fb995f3248de63a8d35b7985ee533d4b09125..f84e922d506dce80ac34ed6e69f081b59d1b56eb 100644 (file)
@@ -1648,6 +1648,7 @@ void Matrix4x4_Transform3x3 (const matrix4x4_t *in, const float v[3], float out[
 #endif
 }
 
+// transforms a positive distance plane (A*x+B*y+C*z-D=0) through a rotation or translation matrix
 void Matrix4x4_TransformPositivePlane(const matrix4x4_t *in, float x, float y, float z, float d, float *o)
 {
        float scale = sqrt(in->m[0][0] * in->m[0][0] + in->m[0][1] * in->m[0][1] + in->m[0][2] * in->m[0][2]);
@@ -1665,6 +1666,7 @@ void Matrix4x4_TransformPositivePlane(const matrix4x4_t *in, float x, float y, f
 #endif
 }
 
+// transforms a standard plane (A*x+B*y+C*z+D=0) through a rotation or translation matrix
 void Matrix4x4_TransformStandardPlane(const matrix4x4_t *in, float x, float y, float z, float d, float *o)
 {
        float scale = sqrt(in->m[0][0] * in->m[0][0] + in->m[0][1] * in->m[0][1] + in->m[0][2] * in->m[0][2]);