diff --git a/crates/fj-math/src/coordinates.rs b/crates/fj-math/src/coordinates.rs index b56cc52c8..767bf7ddf 100644 --- a/crates/fj-math/src/coordinates.rs +++ b/crates/fj-math/src/coordinates.rs @@ -1,6 +1,14 @@ use super::Scalar; /// 1-dimensional curve coordinates +/// +/// One-dimensional [`Point`]s and [`Vector`]s dereference to this type (via +/// [`Deref`]). This allows you to access the `t` field, even though [`Point`] +/// and [`Vector`] do not have such a field themselves. +/// +/// [`Deref`]: std::ops::Deref +/// [`Point`]: crate::Point +/// [`Vector`]: crate::Vector #[repr(C)] pub struct T { /// The single coordinate of the 1-dimensional curve coordinates @@ -8,6 +16,14 @@ pub struct T { } /// 2-dimensional surface coordinates +/// +/// Two-dimensional [`Point`]s and [`Vector`]s dereference to this type (via +/// [`Deref`]). This allows you to access the `u`/`v` fields, even though +/// [`Point`] and [`Vector`] do not have such fields themselves. +/// +/// [`Deref`]: std::ops::Deref +/// [`Point`]: crate::Point +/// [`Vector`]: crate::Vector #[repr(C)] pub struct Uv { /// The first coordinate of the 2-dimensional surface coordinates @@ -18,6 +34,14 @@ pub struct Uv { } /// 3-dimensional model coordinates +/// +/// Three-dimensional [`Point`]s and [`Vector`]s dereference to this type (via +/// [`Deref`]). This allows you to access the `x`/`y`/`z` fields, even though +/// [`Point`] and [`Vector`] do not have such fields themselves. +/// +/// [`Deref`]: std::ops::Deref +/// [`Point`]: crate::Point +/// [`Vector`]: crate::Vector #[repr(C)] pub struct Xyz { /// The first coordinate of the 3-dimensional model coordinates