Module indigo::math[][src]

Structs

Matrix4

A 4x4 matrix of T.

Vector2

A two-dimensional vector.

Vector3

A three-dimensional vector.

Vector4

A four-dimensional vector.

Traits

AsPrimitive

A generic interface for casting between machine scalars with the as operator, which admits narrowing and precision loss. Implementers of this trait AsPrimitive should behave like a primitive numeric type (e.g. a newtype around another primitive), and the intended conversion must never fail.

Number

A trait for types that implement all the basic operations of a number.

One

Defines a multiplicative identity element for Self.

Zero

Defines an additive identity element for Self.

Functions

clamp

Clamps a number so that it is between a minimum and maximum bound.

clamp_mut

Clamps a number in-place so that it is between a minimum and maximum bound.

one

Returns the multiplicative identity, 1.

zero

Returns the additive identity, 0.