Skip to content

Commit

Permalink
Merge #195
Browse files Browse the repository at this point in the history
195: Fix typos in some doc comments r=Ogeon a=okaneco



Co-authored-by: okaneco <47607823+okaneco@users.noreply.github.com>
  • Loading branch information
bors[bot] and okaneco authored Dec 19, 2020
2 parents 91ff1d4 + 836f67d commit 92215de
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions palette/src/chromatic_adaptation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@ pub enum Method {
XyzScaling,
}

/// Holds the matrix coeffecients for the chromatic adaptation methods
/// Holds the matrix coefficients for the chromatic adaptation methods
pub struct ConeResponseMatrices<T: Float> {
///3x3 matrix for the cone response domains
pub ma: Mat3<T>,
///3x3 matrix for the inverse of the cone response domains
pub inv_ma: Mat3<T>,
}

/// Generates a conversion matrix to convert the Xyz trisitmilus values from
/// Generates a conversion matrix to convert the Xyz tristimulus values from
/// one illuminant to another (Swp -> Dwp)
pub trait TransformMatrix<Swp, Dwp, T>
where
Expand Down
2 changes: 1 addition & 1 deletion palette/src/white_point.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ use crate::{from_f64, FloatComponent, Xyz};
/// tristimulus values and can be used in place of the ones defined in this
/// library.
pub trait WhitePoint: 'static {
/// Get the Xyz chromacity co-ordinates for the white point.
/// Get the Xyz chromaticity co-ordinates for the white point.
fn get_xyz<Wp: WhitePoint, T: FloatComponent>() -> Xyz<Wp, T>;
}

Expand Down
4 changes: 2 additions & 2 deletions palette/src/xyz.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ where

/// Z is the scale of what can be seen as the blue stimulation. Its range
/// depends on the white point and goes from 0.0 to 1.08883 for the
/// defautl D65.
/// default D65.
pub z: T,

/// The white point associated with the color's illuminant and observer.
Expand Down Expand Up @@ -87,7 +87,7 @@ impl<T> Xyz<D65, T>
where
T: FloatComponent,
{
/// CIE XYZ with whtie point D65.
/// CIE XYZ with white point D65.
pub fn new(x: T, y: T, z: T) -> Xyz<D65, T> {
Xyz {
x,
Expand Down
8 changes: 4 additions & 4 deletions palette/src/yxy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ pub type Yxya<Wp = D65, T = f32> = Alpha<Yxy<Wp, T>, T>;
/// The CIE 1931 Yxy (xyY) color space.
///
/// Yxy is a luminance-chromaticity color space derived from the CIE XYZ
/// color space. It is widely used to define colors. The chromacity diagrams
/// for the color spaces are a plot of this color space's x and y coordiantes.
/// color space. It is widely used to define colors. The chromaticity diagrams
/// for the color spaces are a plot of this color space's x and y coordinates.
///
/// Conversions and operations on this color space depend on the white point.
#[derive(Debug, PartialEq, Pixel, FromColorUnclamped, WithAlpha)]
Expand All @@ -42,11 +42,11 @@ where
T: FloatComponent,
Wp: WhitePoint,
{
/// x chromacity co-ordinate derived from XYZ color space as X/(X+Y+Z).
/// x chromaticity co-ordinate derived from XYZ color space as X/(X+Y+Z).
/// Typical range is between 0 and 1
pub x: T,

/// y chromacity co-ordinate derived from XYZ color space as Y/(X+Y+Z).
/// y chromaticity co-ordinate derived from XYZ color space as Y/(X+Y+Z).
/// Typical range is between 0 and 1
pub y: T,

Expand Down

0 comments on commit 92215de

Please sign in to comment.