Struct siege_math::matrix::Mat2 [] [src]

#[repr(C)]
pub struct Mat2<F> { pub x: Vec2<F>, pub y: Vec2<F>, }

A 2x2 matrix.

This matrix is internally stored column-major (as that is better for GPU compatibility and possibly other reasons), but the API (e.g. the order of function parameters to the new() function) is row-major, since that is how people write matrices on paper.

Fields

Methods

impl<F: FullFloat> Mat2<F>
[src]

[src]

Create a new 2x2 Matrix. Specify parameters in row-major order (as typically written on paper and in math texts)

[src]

impl<F: FullFloat> Mat2<F>
[src]

[src]

impl<F: FullFloat> Mat2<F>
[src]

[src]

impl<F: FullFloat> Mat2<F>
[src]

[src]

impl<F: FullFloat> Mat2<F>
[src]

[src]

[src]

impl<F: FullFloat> Mat2<F>
[src]

[src]

impl<F: FullFloat> Mat2<F>
[src]

[src]

impl<F: FullFloat> Mat2<F>
[src]

[src]

impl<F: FullFloat> Mat2<F>
[src]

[src]

Trait Implementations

impl<F: Debug> Debug for Mat2<F>
[src]

[src]

Formats the value using the given formatter. Read more

impl<F: Clone> Clone for Mat2<F>
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl<F: Copy> Copy for Mat2<F>
[src]

impl<F: PartialEq> PartialEq for Mat2<F>
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

[src]

This method tests for !=.

impl<F: Eq> Eq for Mat2<F>
[src]

impl<F: Hash> Hash for Mat2<F>
[src]

[src]

Feeds this value into the given [Hasher]. Read more

1.3.0
[src]

Feeds a slice of this type into the given [Hasher]. Read more

impl<F: FullFloat> Index<(usize, usize)> for Mat2<F>
[src]

The returned type after indexing.

[src]

Performs the indexing (container[index]) operation.

impl<F: FullFloat> IndexMut<(usize, usize)> for Mat2<F>
[src]

[src]

Performs the mutable indexing (container[index]) operation.

impl<F: FullFloat> Default for Mat2<F>
[src]

[src]

Returns the "default value" for a type. Read more

impl<'a, 'b, F: FullFloat> Add<&'b Mat2<F>> for &'a Mat2<F>
[src]

The resulting type after applying the + operator.

[src]

Performs the + operation.

impl<'a, F: FullFloat> Mul<F> for &'a Mat2<F>
[src]

The resulting type after applying the * operator.

[src]

Performs the * operation.

impl<'a, 'b, F: FullFloat> Mul<&'b Mat2<F>> for &'a Mat2<F>
[src]

The resulting type after applying the * operator.

[src]

Performs the * operation.

impl<'a, 'b, F: FullFloat> Mul<&'a Vec2<F>> for &'b Mat2<F>
[src]

The resulting type after applying the * operator.

[src]

Performs the * operation.

impl<'a, 'b, F: FullFloat> Mul<&'a Mat2<F>> for &'a Vec2<F>
[src]

The resulting type after applying the * operator.

[src]

Performs the * operation.

impl<F: FullFloat> ApproxEq for Mat2<F>
[src]

[src]

This method tests for self and other values to be approximately equal using two methods: epsilon and ulps. If the values differ by less than the given epsilon, they will be considered equal. If the values differ by more than epsilon, but by less than the given ulps, they will also be considered equal. Otherwise they are unequal. Read more

[src]

This method tests for self and other values to be not approximately equal using two methods: epsilon and ulps. If the values differ by less than the given epsilon, they will be considered equal. If the values differ by more than epsilon, but by less than the given ulps, they will also be considered equal. Otherwise they are unequal. Read more

Auto Trait Implementations

impl<F> Send for Mat2<F> where
    F: Send

impl<F> Sync for Mat2<F> where
    F: Sync