From ad970b94ec9fdcc373aa6ddd70404442c33a1d32 Mon Sep 17 00:00:00 2001 From: Corey Richardson Date: Sun, 25 May 2014 14:35:46 -0700 Subject: [PATCH] Expand crate documentation --- src/cgmath/lib.rs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/cgmath/lib.rs b/src/cgmath/lib.rs index 98d85ac..e0a18a0 100644 --- a/src/cgmath/lib.rs +++ b/src/cgmath/lib.rs @@ -25,7 +25,16 @@ //! Computer graphics-centric math. //! //! This crate provides useful mathematical primitives and operations on them. -//! It is organized into one module per primitive. +//! It is organized into one module per primitive. The core structures are +//! vectors and matrices. A strongly-typed interface is provided, to prevent +//! mixing units or violating mathematical invariants. +//! +//! Transformations are not usually done directly on matrices, but go through +//! transformation objects that can be converted to matrices. Rotations go +//! through the `Basis` types, which are guaranteed to be orthogonal matrices. +//! Despite this, one can directly create a limited rotation matrix using the +//! `look_at`, `from_angle`, `from_euler`, and `from_axis_angle` methods. +//! These are provided for convenience. pub use array::Array;