Skip to main content

Point2

Struct Point2 

Source
#[repr(C)]
pub struct Point2<U: Unit = f32> { pub x: U::Scalar, pub y: U::Scalar, }
Expand description

2D point.

Alignment: Same as the scalar.

Fields§

§x: U::Scalar

X coordinate

§y: U::Scalar

Y coordinate

Implementations§

Source§

impl<T: Unit> Point2<T>

Source

pub const fn new(x: T::Scalar, y: T::Scalar) -> Self

New point.

Source

pub fn from_vector(vec: Vector2<T>) -> Self

Convert a vector to a point as-is.

Source

pub fn to_vector(self) -> Vector2<T>

Cast this point as-is to a vector.

Source

pub fn as_vector(&self) -> &Vector2<T>

Reinterpret as vector.

Source

pub fn as_vector_mut(&mut self) -> &mut Vector2<T>

Reinterpret as vector.

Source

pub fn translate(self, by: Vector2<T>) -> Self

Translate this point by vector.

Equivalent to self + by.

Source§

impl<T: Unit> Point2<T>

Source

pub fn splat(scalar: T::Scalar) -> Self

Set all elements to scalar.

Source

pub fn clamp(self, min: Self, max: Self) -> Self

Clamp all elements within min and max.

Source

pub fn min(self, other: Self) -> Self

Return by-element minimum.

Source

pub fn max(self, other: Self) -> Self

Return by-element maximum.

Source

pub fn min_element(self) -> T::Scalar

Min element.

Source

pub fn max_element(self) -> T::Scalar

Max element.

Source

pub fn write_to_slice(self, slice: &mut [T::Scalar])

Write this vector type to a slice.

Source

pub fn with_x(self, x: T::Scalar) -> Self

Replace x component.

Source

pub fn with_y(self, x: T::Scalar) -> Self

Replace y component.

Source

pub fn element_sum(self) -> T::Scalar

Sum of all elements.

Source

pub fn element_product(self) -> T::Scalar

Product of all elements.

Source

pub fn as_array(&self) -> &[T::Scalar; 2]

Reinterpret as array.

Source

pub fn as_array_mut(&mut self) -> &mut [T::Scalar; 2]

Reinterpret as mutable array.

Source

pub fn get(&self, index: usize) -> T::Scalar

Get component at index.

Source

pub fn set(&mut self, index: usize, value: T::Scalar)

Set component at index.

Source

pub fn const_get<const N: usize>(&self) -> T::Scalar

Get component at index N.

Source

pub fn const_set<const N: usize>(&mut self, value: T::Scalar)

Set component at index N.

Source

pub fn map<F: Fn(T::Scalar) -> T::Scalar>(self, f: F) -> Self

Returns a vector containing each element of self modified by a mapping function f.

Source

pub fn from_untyped(untyped: Point2<T::Scalar>) -> Point2<T>

Bitcast an untyped instance to self.

Source

pub fn to_untyped(self) -> Point2<T::Scalar>

Bitcast self to an untyped instance.

Source

pub fn as_untyped(&self) -> &Point2<T::Scalar>

Reinterpret cast self as the untyped variant.

Source

pub fn as_untyped_mut(&mut self) -> &mut Point2<T::Scalar>

Reinterpret cast self as the untyped variant.

Source

pub fn cast<T2>(self) -> Point2<T2>
where T2: Unit<Scalar = T::Scalar>,

Cast to a different coordinate space with the same underlying scalar type.

Source

pub fn cast_ref<T2>(&self) -> &Point2<T2>
where T2: Unit<Scalar = T::Scalar>,

Cast to a different coordinate space with the same underlying scalar type.

Source

pub fn cast_mut<T2>(&mut self) -> &mut Point2<T2>
where T2: Unit<Scalar = T::Scalar>,

Cast to a different coordinate space with the same underlying scalar type.

Source

pub fn as_<T2>(self) -> Point2<T2>
where T: Unit<Scalar: AsPrimitive<T2::Scalar>>, T2: Unit,

Cast to a different coordinate space with scalar type conversion through the as operator (potentially narrowing or losing precision).

Source

pub fn try_cast<T2>(self) -> Option<Point2<T2>>
where T2: Unit,

Cast to a different coordinate space with scalar type conversion. Returns None if any component could not be converted to the target scalar type.

Source

pub fn to_tuple(self) -> (T::Scalar, T::Scalar)

Convert this vector or point to a tuple.

Source

pub fn from_tuple((x, y): (T::Scalar, T::Scalar)) -> Self

Create from tuple.

Source§

impl<T: FloatUnit> Point2<T>

Source

pub fn ceil(self) -> Self

Round all components up.

Source

pub fn exp(self) -> Self

e^self by component

Source

pub fn floor(self) -> Self

Round all components down.

Source

pub fn fract(self) -> Self

Source

pub fn fract_gl(self) -> Self

Source

pub fn is_finite(self) -> bool

True if all components are non-infinity and non-NaN.

Source

pub fn is_nan(self) -> bool

True if any component is NaN.

Source

pub fn lerp(self, rhs: Self, s: T::Scalar) -> Self

Linear interpolation.

Source

pub fn powf(self, n: T::Scalar) -> Self

self^n by component

Source

pub fn recip(self) -> Self

1.0/self by component

Source

pub fn round(self) -> Self

Round all components.

Source

pub fn copysign(self, rhs: Self) -> Self

Returns a vector with signs of rhs and the magnitudes of self.

Source§

impl<T: SignedUnit> Point2<T>

Source

pub fn signum(self) -> Self

Returns a vector with elements representing the sign of self.

Source

pub fn abs(self) -> Self

Returns a vector containing the absolute value of each element of self.

Source

pub fn rem_euclid(self, rhs: Self) -> Self

Returns the element-wise remainder of Euclidean division of self`` by rhs`.

§Panics

This function will panic if any rhs element is 0 or the division results in overflow.

Source§

impl<T: IntUnit> Point2<T>

Source

pub fn saturating_add(self, rhs: Self) -> Self

Returns a vector containing the saturating addition of self and rhs.

Source

pub fn saturating_sub(self, rhs: Self) -> Self

Returns a vector containing the saturating subtraction of self and rhs.

Source

pub fn saturating_mul(self, rhs: Self) -> Self

Returns a vector containing the saturating multiplication of self and rhs.

Source

pub fn saturating_div(self, rhs: Self) -> Self

Returns a vector containing the saturating division of self and rhs.

Source

pub fn wrapping_add(self, rhs: Self) -> Self

Returns a vector containing the wrapping addition of self and rhs.

Source

pub fn wrapping_sub(self, rhs: Self) -> Self

Returns a vector containing the wrapping subtraction of self and rhs.

Source

pub fn wrapping_mul(self, rhs: Self) -> Self

Returns a vector containing the wrapping multiplication of self and rhs.

Source

pub fn wrapping_div(self, rhs: Self) -> Self

Returns a vector containing the wrapping division of self and rhs.

Source§

impl<T: Unit> Point2<T>

Source

pub fn swizzle<const X: usize, const Y: usize>(&self) -> Vector2<T>

Select components of this vector and return a new vector containing those components.

Source§

impl<T: Unit> Point2<T>

Source

pub const ZERO: Self

All zeroes.

Source

pub const ONE: Self

All ones.

Source

pub const X: Self

Unit vector in the direction of the X axis.

Source

pub const Y: Self

Unit vector in the direction of the Y axis.

Source

pub const AXES: [Self; 2]

The unit axes.

Source

pub fn to_raw(self) -> <T::Scalar as Scalar>::Vec2

Transparently cast this type to its underlying, bitwise compatible glam type.

Source

pub fn from_raw(vec: <T::Scalar as Scalar>::Vec2) -> Self

Convert a raw glam vector to this type. This is a zero-overhead cast.

Source§

impl<T: FloatUnit> Point2<T>

Source

pub const NAN: Self

All NaN.

Source

pub const INFINITY: Self

All positive infinity.

Source

pub const NEG_INFINITY: Self

All negative infinity.

Source

pub fn is_nan_mask(self) -> BVec2

Return a mask where each bit is set if the corresponding component is NaN.

Source

pub fn is_finite_mask(self) -> BVec2

Performs is_finite on each element of self, returning a vector mask of the results.

Source§

impl<T: SignedUnit> Point2<T>

Source

pub const NEG_ONE: Self

All negative one.

Source

pub const NEG_X: Self

(-1, 0)

Source

pub const NEG_Y: Self

(0, -1)

Source§

impl<T: Unit> Point2<T>

Source

pub fn from_array(array: [T::Scalar; 2]) -> Self

Creates a new vector from an array.

Source

pub fn to_array(&self) -> [T::Scalar; 2]

[x, y]

Source

pub fn extend(self, z: T::Scalar) -> Point3<T>

Creates a 3D vector from self and the given z value.

Source

pub fn cmpeq(self, rhs: Self) -> BVec2

Returns a vector mask containing the result of a == comparison for each element of self and rhs.

Source

pub fn cmpne(self, rhs: Self) -> BVec2

Returns a vector mask containing the result of a != comparison for each element of self and rhs.

Source

pub fn cmpge(self, rhs: Self) -> BVec2

Returns a vector mask containing the result of a >= comparison for each element of self and rhs.

Source

pub fn cmpgt(self, rhs: Self) -> BVec2

Returns a vector mask containing the result of a > comparison for each element of self and rhs.

Source

pub fn cmple(self, rhs: Self) -> BVec2

Returns a vector mask containing the result of a <= comparison for each element of self and rhs.

Source

pub fn cmplt(self, rhs: Self) -> BVec2

Returns a vector mask containing the result of a < comparison for each element of self and rhs.

Source

pub fn select(mask: BVec2, if_true: Self, if_false: Self) -> Self

Creates a vector from the elements in if_true and if_false, selecting which to use for each element of self.

A true element in the mask uses the corresponding element from if_true, and false uses the element from if_false.

Source§

impl<T: FloatUnit> Point2<T>

Source

pub fn distance_squared(self, other: Self) -> T::Scalar

Compute the squared euclidean distance between two points in space.

Source

pub fn distance(self, other: Self) -> T::Scalar

Computes the Euclidean distance between two points in space.

Source

pub fn midpoint(self, rhs: Self) -> Self

Calculates the midpoint between self and rhs.

See (e.g.) glam::Vec2::midpoint().

Source

pub fn move_towards(&self, rhs: Self, d: T::Scalar) -> Self

Moves towards rhs based on the value d.

See (e.g.) glam::Vec2::move_towards().

Source§

impl<T: IntUnit<Scalar: IntScalar>> Point2<T>

Source

pub fn manhattan_distance( self, other: Self, ) -> <T::Scalar as IntScalar>::Unsigned

Computes the manhattan distance between two points

Source

pub fn checked_manhattan_distance( self, other: Self, ) -> Option<<T::Scalar as IntScalar>::Unsigned>

Computes the manhattan distance between two points

Source

pub fn chebyshev_distance( self, other: Self, ) -> <T::Scalar as IntScalar>::Unsigned

Compute the chebyshev distance between two points.

Trait Implementations§

Source§

impl<T: FloatUnit> AbsDiffEq for Point2<T>

Source§

type Epsilon = <<T as Unit>::Scalar as AbsDiffEq>::Epsilon

Used for specifying relative comparisons.
Source§

fn default_epsilon() -> Self::Epsilon

The default tolerance to use when testing values that are close together. Read more
Source§

fn abs_diff_eq(&self, other: &Self, epsilon: Self::Epsilon) -> bool

A test for equality that uses the absolute difference to compute the approximate equality of two numbers.
Source§

fn abs_diff_ne(&self, other: &Self, epsilon: Self::Epsilon) -> bool

The inverse of AbsDiffEq::abs_diff_eq.
Source§

impl<T: Unit> Add for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit> Add<&Point2<T>> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Add<&Point2<T>> for &f32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Add<&Point2<T>> for &f64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Add<&Point2<T>> for &i16

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Add<&Point2<T>> for &i32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Add<&Point2<T>> for &i64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Add<&Point2<T>> for &u16

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Add<&Point2<T>> for &u32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Add<&Point2<T>> for &u64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit> Add<&Point2<T>> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Add<&Point2<T>> for f32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Add<&Point2<T>> for f64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Add<&Point2<T>> for i16

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Add<&Point2<T>> for i32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Add<&Point2<T>> for i64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Add<&Point2<T>> for u16

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Add<&Point2<T>> for u32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Add<&Point2<T>> for u64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit> Add<&Vector2<T>> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Vector2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit> Add<&Vector2<T>> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &Vector2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Add<&f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &f32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Add<&f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &f32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Add<&f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &f64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Add<&f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &f64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Add<&i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &i16) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Add<&i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &i16) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Add<&i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &i32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Add<&i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &i32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Add<&i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &i64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Add<&i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &i64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Add<&u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &u16) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Add<&u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &u16) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Add<&u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &u32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Add<&u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &u32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Add<&u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &u64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Add<&u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &u64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit> Add<Point2<T>> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Add<Point2<T>> for &f32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Add<Point2<T>> for &f64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Add<Point2<T>> for &i16

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Add<Point2<T>> for &i32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Add<Point2<T>> for &i64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Add<Point2<T>> for &u16

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Add<Point2<T>> for &u32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Add<Point2<T>> for &u64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Add<Point2<T>> for f32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Add<Point2<T>> for f64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Add<Point2<T>> for i16

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Add<Point2<T>> for i32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Add<Point2<T>> for i64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Add<Point2<T>> for u16

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Add<Point2<T>> for u32

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Add<Point2<T>> for u64

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Point2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit> Add<Vector2<T>> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Vector2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit> Add<Vector2<T>> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Vector2<T>) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Add<f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: f32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Add<f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: f32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Add<f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: f64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Add<f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: f64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Add<i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: i16) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Add<i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: i16) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Add<i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: i32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Add<i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: i32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Add<i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: i64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Add<i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: i64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Add<u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: u16) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Add<u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: u16) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Add<u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: u32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Add<u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: u32) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Add<u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: u64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Add<u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: u64) -> Point2<T>

Performs the + operation. Read more
Source§

impl<T: Unit> AddAssign for Point2<T>

Source§

fn add_assign(&mut self, rhs: Point2<T>)

Performs the += operation. Read more
Source§

impl<T: Unit> AddAssign<&Point2<T>> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &Point2<T>)

Performs the += operation. Read more
Source§

impl<T: Unit> AddAssign<&Vector2<T>> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &Vector2<T>)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = f32>> AddAssign<&f32> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &f32)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = f64>> AddAssign<&f64> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &f64)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = i16>> AddAssign<&i16> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &i16)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = i32>> AddAssign<&i32> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &i32)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = i64>> AddAssign<&i64> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &i64)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = u16>> AddAssign<&u16> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &u16)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = u32>> AddAssign<&u32> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &u32)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = u64>> AddAssign<&u64> for Point2<T>

Source§

fn add_assign(&mut self, rhs: &u64)

Performs the += operation. Read more
Source§

impl<T: Unit> AddAssign<Vector2<T>> for Point2<T>

Source§

fn add_assign(&mut self, rhs: Vector2<T>)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = f32>> AddAssign<f32> for Point2<T>

Source§

fn add_assign(&mut self, rhs: f32)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = f64>> AddAssign<f64> for Point2<T>

Source§

fn add_assign(&mut self, rhs: f64)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = i16>> AddAssign<i16> for Point2<T>

Source§

fn add_assign(&mut self, rhs: i16)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = i32>> AddAssign<i32> for Point2<T>

Source§

fn add_assign(&mut self, rhs: i32)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = i64>> AddAssign<i64> for Point2<T>

Source§

fn add_assign(&mut self, rhs: i64)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = u16>> AddAssign<u16> for Point2<T>

Source§

fn add_assign(&mut self, rhs: u16)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = u32>> AddAssign<u32> for Point2<T>

Source§

fn add_assign(&mut self, rhs: u32)

Performs the += operation. Read more
Source§

impl<T: Unit<Scalar = u64>> AddAssign<u64> for Point2<T>

Source§

fn add_assign(&mut self, rhs: u64)

Performs the += operation. Read more
Source§

impl<T: Unit> AsMut<[<T as Unit>::Scalar; 2]> for Point2<T>

Source§

fn as_mut(&mut self) -> &mut [T::Scalar; 2]

Converts this type into a mutable reference of the (usually inferred) input type.
Source§

impl<T: Unit> AsRef<[<T as Unit>::Scalar; 2]> for Point2<T>

Source§

fn as_ref(&self) -> &[T::Scalar; 2]

Converts this type into a shared reference of the (usually inferred) input type.
Source§

impl<T: Unit> Clone for Point2<T>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<T: Unit> Contains<Point2<T>> for Box2<T>

Source§

fn contains(&self, thing: &Point2<T>) -> bool

Returns true if thing is inside self.
Source§

impl<T: Unit> Contains<Point2<T>> for Rect<T>

Source§

fn contains(&self, point: &Point2<T>) -> bool

Returns true if thing is inside self.
Source§

impl<T: Unit> Copy for Point2<T>

Source§

impl<T: Unit> Debug for Point2<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<T: Unit> Default for Point2<T>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<T: Unit<Scalar = f32>> Div<&f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &f32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Div<&f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &f32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Div<&f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &f64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Div<&f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &f64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Div<&i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &i16) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Div<&i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &i16) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Div<&i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &i32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Div<&i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &i32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Div<&i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &i64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Div<&i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &i64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Div<&u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &u16) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Div<&u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &u16) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Div<&u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &u32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Div<&u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &u32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Div<&u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &u64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Div<&u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &u64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Div<f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: f32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Div<f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: f32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Div<f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: f64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Div<f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: f64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Div<i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: i16) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Div<i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: i16) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Div<i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: i32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Div<i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: i32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Div<i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: i64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Div<i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: i64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Div<u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: u16) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Div<u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: u16) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Div<u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: u32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Div<u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: u32) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Div<u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: u64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Div<u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: u64) -> Point2<T>

Performs the / operation. Read more
Source§

impl<T: Unit<Scalar = f32>> DivAssign<&f32> for Point2<T>

Source§

fn div_assign(&mut self, rhs: &f32)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = f64>> DivAssign<&f64> for Point2<T>

Source§

fn div_assign(&mut self, rhs: &f64)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = i16>> DivAssign<&i16> for Point2<T>

Source§

fn div_assign(&mut self, rhs: &i16)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = i32>> DivAssign<&i32> for Point2<T>

Source§

fn div_assign(&mut self, rhs: &i32)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = i64>> DivAssign<&i64> for Point2<T>

Source§

fn div_assign(&mut self, rhs: &i64)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = u16>> DivAssign<&u16> for Point2<T>

Source§

fn div_assign(&mut self, rhs: &u16)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = u32>> DivAssign<&u32> for Point2<T>

Source§

fn div_assign(&mut self, rhs: &u32)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = u64>> DivAssign<&u64> for Point2<T>

Source§

fn div_assign(&mut self, rhs: &u64)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = f32>> DivAssign<f32> for Point2<T>

Source§

fn div_assign(&mut self, rhs: f32)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = f64>> DivAssign<f64> for Point2<T>

Source§

fn div_assign(&mut self, rhs: f64)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = i16>> DivAssign<i16> for Point2<T>

Source§

fn div_assign(&mut self, rhs: i16)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = i32>> DivAssign<i32> for Point2<T>

Source§

fn div_assign(&mut self, rhs: i32)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = i64>> DivAssign<i64> for Point2<T>

Source§

fn div_assign(&mut self, rhs: i64)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = u16>> DivAssign<u16> for Point2<T>

Source§

fn div_assign(&mut self, rhs: u16)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = u32>> DivAssign<u32> for Point2<T>

Source§

fn div_assign(&mut self, rhs: u32)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar = u64>> DivAssign<u64> for Point2<T>

Source§

fn div_assign(&mut self, rhs: u64)

Performs the /= operation. Read more
Source§

impl<T: Unit<Scalar: Eq>> Eq for Point2<T>

Source§

impl<T: Unit> From<(<T as Unit>::Scalar, <T as Unit>::Scalar)> for Point2<T>

Source§

fn from((x, y): (T::Scalar, T::Scalar)) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = f64>> From<DVec2> for Point2<T>

Source§

fn from(value: DVec2) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = i16>> From<I16Vec2> for Point2<T>

Source§

fn from(value: I16Vec2) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = i64>> From<I64Vec2> for Point2<T>

Source§

fn from(value: I64Vec2) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = i32>> From<IVec2> for Point2<T>

Source§

fn from(value: IVec2) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit> From<Point2<T>> for [T::Scalar; 2]

Source§

fn from(value: Point2<T>) -> [T::Scalar; 2]

Converts to this type from the input type.
Source§

impl<T: Unit> From<Point2<T>> for (T::Scalar, T::Scalar)

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = f64>> From<Point2<T>> for DVec2

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = i16>> From<Point2<T>> for I16Vec2

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = i64>> From<Point2<T>> for I64Vec2

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = i32>> From<Point2<T>> for IVec2

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = u16>> From<Point2<T>> for U16Vec2

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = u64>> From<Point2<T>> for U64Vec2

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = u32>> From<Point2<T>> for UVec2

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = f32>> From<Point2<T>> for Vec2

Source§

fn from(value: Point2<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit> From<Point2<T>> for Vector2<T>

Source§

fn from(point: Point2<T>) -> Vector2<T>

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = u16>> From<U16Vec2> for Point2<T>

Source§

fn from(value: U16Vec2) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = u64>> From<U64Vec2> for Point2<T>

Source§

fn from(value: U64Vec2) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = u32>> From<UVec2> for Point2<T>

Source§

fn from(value: UVec2) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit<Scalar = f32>> From<Vec2> for Point2<T>

Source§

fn from(value: Vec2) -> Self

Converts to this type from the input type.
Source§

impl<T: Unit> From<Vector2<T>> for Point2<T>

Source§

fn from(vec: Vector2<T>) -> Point2<T>

Converts to this type from the input type.
Source§

impl<T: Unit> From<[<T as Unit>::Scalar; 2]> for Point2<T>

Source§

fn from(value: [T::Scalar; 2]) -> Self

Converts to this type from the input type.
Source§

impl<T: IntUnit> Hash for Point2<T>

Source§

fn hash<H>(&self, state: &mut H)
where H: Hasher,

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl<T: Unit> Index<usize> for Point2<T>

Source§

type Output = <T as Unit>::Scalar

The returned type after indexing.
Source§

fn index(&self, index: usize) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl<T: Unit> IndexMut<usize> for Point2<T>

Source§

fn index_mut(&mut self, index: usize) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl<T: Unit> Intersection<Point2<T>> for Box2<T>

Source§

type Intersection = Point2<T>

The type of intersection. Read more
Source§

fn intersects(&self, other: &Point2<T>) -> bool

True if thing intersects with self.
Source§

fn intersection(&self, thing: &Point2<T>) -> Option<Self::Intersection>

If thing intersects with self, return the intersection. Otherwise, returns None.
Source§

impl<T: Unit> Intersection<Point2<T>> for Rect<T>

Source§

type Intersection = Point2<T>

The type of intersection. Read more
Source§

fn intersects(&self, thing: &Point2<T>) -> bool

True if thing intersects with self.
Source§

fn intersection(&self, thing: &Point2<T>) -> Option<Self::Intersection>

If thing intersects with self, return the intersection. Otherwise, returns None.
Source§

impl<T: Unit> IntoIterator for Point2<T>

Source§

type Item = <T as Unit>::Scalar

The type of the elements being iterated over.
Source§

type IntoIter = <[<T as Unit>::Scalar; 2] as IntoIterator>::IntoIter

Which kind of iterator are we turning this into?
Source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more
Source§

impl<T: Unit<Scalar = f32>> Mul<&Point2<T>> for &f32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Mul<&Point2<T>> for &f64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Mul<&Point2<T>> for &i16

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Mul<&Point2<T>> for &i32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Mul<&Point2<T>> for &i64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Mul<&Point2<T>> for &u16

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Mul<&Point2<T>> for &u32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Mul<&Point2<T>> for &u64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Mul<&Point2<T>> for f32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Mul<&Point2<T>> for f64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Mul<&Point2<T>> for i16

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Mul<&Point2<T>> for i32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Mul<&Point2<T>> for i64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Mul<&Point2<T>> for u16

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Mul<&Point2<T>> for u32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Mul<&Point2<T>> for u64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Mul<&f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &f32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Mul<&f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &f32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Mul<&f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &f64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Mul<&f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &f64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Mul<&i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &i16) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Mul<&i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &i16) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Mul<&i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &i32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Mul<&i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &i32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Mul<&i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &i64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Mul<&i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &i64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Mul<&u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &u16) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Mul<&u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &u16) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Mul<&u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &u32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Mul<&u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &u32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Mul<&u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &u64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Mul<&u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &u64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Mul<Point2<T>> for &f32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Mul<Point2<T>> for &f64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Mul<Point2<T>> for &i16

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Mul<Point2<T>> for &i32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Mul<Point2<T>> for &i64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Mul<Point2<T>> for &u16

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Mul<Point2<T>> for &u32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Mul<Point2<T>> for &u64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T> Mul<Point2<T>> for Matrix3<T::Scalar>
where T: FloatUnit,

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Self::Output

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Mul<Point2<T>> for f32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Mul<Point2<T>> for f64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Mul<Point2<T>> for i16

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Mul<Point2<T>> for i32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Mul<Point2<T>> for i64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Mul<Point2<T>> for u16

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Mul<Point2<T>> for u32

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Mul<Point2<T>> for u64

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Point2<T>) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Mul<f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: f32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Mul<f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: f32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Mul<f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: f64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Mul<f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: f64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Mul<i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: i16) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Mul<i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: i16) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Mul<i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: i32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Mul<i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: i32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Mul<i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: i64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Mul<i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: i64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Mul<u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: u16) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Mul<u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: u16) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Mul<u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: u32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Mul<u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: u32) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Mul<u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: u64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Mul<u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: u64) -> Point2<T>

Performs the * operation. Read more
Source§

impl<T: Unit<Scalar = f32>> MulAssign<&f32> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: &f32)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = f64>> MulAssign<&f64> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: &f64)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = i16>> MulAssign<&i16> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: &i16)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = i32>> MulAssign<&i32> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: &i32)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = i64>> MulAssign<&i64> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: &i64)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = u16>> MulAssign<&u16> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: &u16)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = u32>> MulAssign<&u32> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: &u32)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = u64>> MulAssign<&u64> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: &u64)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = f32>> MulAssign<f32> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: f32)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = f64>> MulAssign<f64> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: f64)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = i16>> MulAssign<i16> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: i16)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = i32>> MulAssign<i32> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: i32)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = i64>> MulAssign<i64> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: i64)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = u16>> MulAssign<u16> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: u16)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = u32>> MulAssign<u32> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: u32)

Performs the *= operation. Read more
Source§

impl<T: Unit<Scalar = u64>> MulAssign<u64> for Point2<T>

Source§

fn mul_assign(&mut self, rhs: u64)

Performs the *= operation. Read more
Source§

impl<T: SignedUnit> Neg for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn neg(self) -> Self

Performs the unary - operation. Read more
Source§

impl<T: Unit> PartialEq for Point2<T>

Source§

fn eq(&self, other: &Self) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: Unit> PartialEq<(<T as Unit>::Scalar, <T as Unit>::Scalar)> for Point2<T>

Source§

fn eq(&self, other: &(T::Scalar, T::Scalar)) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: Unit> Pod for Point2<T>

Source§

impl<T: FloatUnit> RelativeEq for Point2<T>

Source§

fn default_max_relative() -> Self::Epsilon

The default relative tolerance for testing values that are far-apart. Read more
Source§

fn relative_eq( &self, other: &Self, epsilon: Self::Epsilon, max_relative: Self::Epsilon, ) -> bool

A test for equality that uses a relative comparison if the values are far apart.
Source§

fn relative_ne( &self, other: &Self, epsilon: Self::Epsilon, max_relative: Self::Epsilon, ) -> bool

The inverse of RelativeEq::relative_eq.
Source§

impl<T: Unit> Rem for Point2<T>

Source§

type Output = Vector2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: Point2<T>) -> Vector2<T>

Performs the % operation. Read more
Source§

impl<T: Unit> Rem<&Point2<T>> for &Point2<T>

Source§

type Output = Vector2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &Point2<T>) -> Vector2<T>

Performs the % operation. Read more
Source§

impl<T: Unit> Rem<&Point2<T>> for Point2<T>

Source§

type Output = Vector2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &Point2<T>) -> Vector2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Rem<&f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &f32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Rem<&f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &f32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Rem<&f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &f64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Rem<&f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &f64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Rem<&i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &i16) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Rem<&i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &i16) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Rem<&i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &i32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Rem<&i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &i32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Rem<&i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &i64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Rem<&i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &i64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Rem<&u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &u16) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Rem<&u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &u16) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Rem<&u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &u32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Rem<&u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &u32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Rem<&u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &u64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Rem<&u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: &u64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit> Rem<Point2<T>> for &Point2<T>

Source§

type Output = Vector2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: Point2<T>) -> Vector2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Rem<f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: f32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Rem<f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: f32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Rem<f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: f64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Rem<f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: f64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Rem<i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: i16) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Rem<i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: i16) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Rem<i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: i32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Rem<i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: i32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Rem<i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: i64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Rem<i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: i64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Rem<u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: u16) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Rem<u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: u16) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Rem<u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: u32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Rem<u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: u32) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Rem<u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: u64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Rem<u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the % operator.
Source§

fn rem(self, rhs: u64) -> Point2<T>

Performs the % operation. Read more
Source§

impl<T: Unit> RemAssign<&Vector2<T>> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &Vector2<T>)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = f32>> RemAssign<&f32> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &f32)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = f64>> RemAssign<&f64> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &f64)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = i16>> RemAssign<&i16> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &i16)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = i32>> RemAssign<&i32> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &i32)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = i64>> RemAssign<&i64> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &i64)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = u16>> RemAssign<&u16> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &u16)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = u32>> RemAssign<&u32> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &u32)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = u64>> RemAssign<&u64> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: &u64)

Performs the %= operation. Read more
Source§

impl<T: Unit> RemAssign<Vector2<T>> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: Vector2<T>)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = f32>> RemAssign<f32> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: f32)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = f64>> RemAssign<f64> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: f64)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = i16>> RemAssign<i16> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: i16)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = i32>> RemAssign<i32> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: i32)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = i64>> RemAssign<i64> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: i64)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = u16>> RemAssign<u16> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: u16)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = u32>> RemAssign<u32> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: u32)

Performs the %= operation. Read more
Source§

impl<T: Unit<Scalar = u64>> RemAssign<u64> for Point2<T>

Source§

fn rem_assign(&mut self, rhs: u64)

Performs the %= operation. Read more
Source§

impl<T: Unit> Sub for Point2<T>

Source§

type Output = Vector2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Vector2<T>

Performs the - operation. Read more
Source§

impl<T: Unit> Sub<&Point2<T>> for &Point2<T>

Source§

type Output = Vector2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Vector2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Sub<&Point2<T>> for &f32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Sub<&Point2<T>> for &f64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Sub<&Point2<T>> for &i16

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Sub<&Point2<T>> for &i32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Sub<&Point2<T>> for &i64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Sub<&Point2<T>> for &u16

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Sub<&Point2<T>> for &u32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Sub<&Point2<T>> for &u64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit> Sub<&Point2<T>> for Point2<T>

Source§

type Output = Vector2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Vector2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Sub<&Point2<T>> for f32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Sub<&Point2<T>> for f64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Sub<&Point2<T>> for i16

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Sub<&Point2<T>> for i32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Sub<&Point2<T>> for i64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Sub<&Point2<T>> for u16

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Sub<&Point2<T>> for u32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Sub<&Point2<T>> for u64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit> Sub<&Vector2<T>> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Vector2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit> Sub<&Vector2<T>> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &Vector2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Sub<&f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &f32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Sub<&f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &f32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Sub<&f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &f64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Sub<&f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &f64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Sub<&i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &i16) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Sub<&i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &i16) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Sub<&i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &i32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Sub<&i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &i32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Sub<&i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &i64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Sub<&i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &i64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Sub<&u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &u16) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Sub<&u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &u16) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Sub<&u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &u32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Sub<&u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &u32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Sub<&u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &u64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Sub<&u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &u64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit> Sub<Point2<T>> for &Point2<T>

Source§

type Output = Vector2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Vector2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Sub<Point2<T>> for &f32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Sub<Point2<T>> for &f64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Sub<Point2<T>> for &i16

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Sub<Point2<T>> for &i32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Sub<Point2<T>> for &i64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Sub<Point2<T>> for &u16

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Sub<Point2<T>> for &u32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Sub<Point2<T>> for &u64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Sub<Point2<T>> for f32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Sub<Point2<T>> for f64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Sub<Point2<T>> for i16

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Sub<Point2<T>> for i32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Sub<Point2<T>> for i64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Sub<Point2<T>> for u16

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Sub<Point2<T>> for u32

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Sub<Point2<T>> for u64

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Point2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit> Sub<Vector2<T>> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Vector2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit> Sub<Vector2<T>> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Vector2<T>) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Sub<f32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: f32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f32>> Sub<f32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: f32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Sub<f64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: f64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = f64>> Sub<f64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: f64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Sub<i16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: i16) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i16>> Sub<i16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: i16) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Sub<i32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: i32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i32>> Sub<i32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: i32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Sub<i64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: i64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = i64>> Sub<i64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: i64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Sub<u16> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: u16) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u16>> Sub<u16> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: u16) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Sub<u32> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: u32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u32>> Sub<u32> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: u32) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Sub<u64> for &Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: u64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit<Scalar = u64>> Sub<u64> for Point2<T>

Source§

type Output = Point2<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: u64) -> Point2<T>

Performs the - operation. Read more
Source§

impl<T: Unit> SubAssign<&Vector2<T>> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &Vector2<T>)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = f32>> SubAssign<&f32> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &f32)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = f64>> SubAssign<&f64> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &f64)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = i16>> SubAssign<&i16> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &i16)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = i32>> SubAssign<&i32> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &i32)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = i64>> SubAssign<&i64> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &i64)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = u16>> SubAssign<&u16> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &u16)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = u32>> SubAssign<&u32> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &u32)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = u64>> SubAssign<&u64> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: &u64)

Performs the -= operation. Read more
Source§

impl<T: Unit> SubAssign<Vector2<T>> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: Vector2<T>)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = f32>> SubAssign<f32> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: f32)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = f64>> SubAssign<f64> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: f64)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = i16>> SubAssign<i16> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: i16)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = i32>> SubAssign<i32> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: i32)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = i64>> SubAssign<i64> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: i64)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = u16>> SubAssign<u16> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: u16)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = u32>> SubAssign<u32> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: u32)

Performs the -= operation. Read more
Source§

impl<T: Unit<Scalar = u64>> SubAssign<u64> for Point2<T>

Source§

fn sub_assign(&mut self, rhs: u64)

Performs the -= operation. Read more
Source§

impl<T: Unit> Swizzle<T> for Point2<T>

Source§

fn swizzle2<const X: usize, const Y: usize>(&self) -> Vector2<T>

Select two components from this vector and return a 2D vector made from those components.
Source§

fn swizzle3<const X: usize, const Y: usize, const Z: usize>(&self) -> Vector3<T>

Select three components from this vector and return a 3D vector made from those components.
Source§

fn swizzle4<const X: usize, const Y: usize, const Z: usize, const W: usize>( &self, ) -> Vector4<T>

Select four components from this vector and return a 4D vector made from those components.
Source§

impl<Src, Dst> TransformMap<Point2<Src>> for Transform2<Src, Dst>
where Src: Unit, Src::Scalar: FloatScalar, Dst: Unit<Scalar = Src::Scalar>,

Source§

type Output = Point2<Dst>

Result type of the transformation.
Source§

fn map(&self, value: Point2<Src>) -> Self::Output

Map T to Self::Output.
Source§

impl<T: Unit> Transparent for Point2<T>

Source§

type Wrapped = <<T as Unit>::Scalar as Scalar>::Vec2

The inner type that shares a compatible representation with Self.
Source§

fn wrap(x: Self::Wrapped) -> Self

Wrap the inner type by copy. Read more
Source§

fn peel(x: Self) -> Self::Wrapped

Unwrap the inner type by copy. Read more
Source§

fn peel_copy(x: &Self) -> Self::Wrapped

Convert a reference to the inner type. Read more
Source§

impl<T: FloatUnit> UlpsEq for Point2<T>

Source§

fn default_max_ulps() -> u32

The default ULPs to tolerate when testing values that are far-apart. Read more
Source§

fn ulps_eq(&self, other: &Self, epsilon: Self::Epsilon, max_ulps: u32) -> bool

A test for equality that uses units in the last place (ULP) if the values are far apart.
Source§

fn ulps_ne(&self, other: &Self, epsilon: Self::Epsilon, max_ulps: u32) -> bool

The inverse of UlpsEq::ulps_eq.
Source§

impl<T: Unit> Vec2Swizzles for Point2<T>

Source§

type Vec3 = Point3<T>

Source§

type Vec4 = Point4<T>

Source§

fn xx(self) -> Point2<T>

Source§

fn xy(self) -> Point2<T>

Source§

fn yy(self) -> Point2<T>

Source§

fn yx(self) -> Point2<T>

Source§

fn xxx(self) -> Point3<T>

Source§

fn xxy(self) -> Point3<T>

Source§

fn xyx(self) -> Point3<T>

Source§

fn xyy(self) -> Point3<T>

Source§

fn yxx(self) -> Point3<T>

Source§

fn yxy(self) -> Point3<T>

Source§

fn yyx(self) -> Point3<T>

Source§

fn yyy(self) -> Point3<T>

Source§

fn xxxx(self) -> Point4<T>

Source§

fn xxxy(self) -> Point4<T>

Source§

fn xxyx(self) -> Point4<T>

Source§

fn xxyy(self) -> Point4<T>

Source§

fn xyxx(self) -> Point4<T>

Source§

fn xyxy(self) -> Point4<T>

Source§

fn xyyx(self) -> Point4<T>

Source§

fn xyyy(self) -> Point4<T>

Source§

fn yxxx(self) -> Point4<T>

Source§

fn yxxy(self) -> Point4<T>

Source§

fn yxyx(self) -> Point4<T>

Source§

fn yxyy(self) -> Point4<T>

Source§

fn yyxx(self) -> Point4<T>

Source§

fn yyxy(self) -> Point4<T>

Source§

fn yyyx(self) -> Point4<T>

Source§

fn yyyy(self) -> Point4<T>

Source§

impl<T: Unit> Zeroable for Point2<T>

Source§

fn zeroed() -> Self

Auto Trait Implementations§

§

impl<U> Freeze for Point2<U>
where <U as Unit>::Scalar: Freeze,

§

impl<U> RefUnwindSafe for Point2<U>
where <U as Unit>::Scalar: RefUnwindSafe,

§

impl<U> Send for Point2<U>

§

impl<U> Sync for Point2<U>

§

impl<U> Unpin for Point2<U>
where <U as Unit>::Scalar: Unpin,

§

impl<U> UnsafeUnpin for Point2<U>
where <U as Unit>::Scalar: UnsafeUnpin,

§

impl<U> UnwindSafe for Point2<U>
where <U as Unit>::Scalar: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> AnyBitPattern for T
where T: Pod,

Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CheckedBitPattern for T
where T: AnyBitPattern,

Source§

type Bits = T

Self must have the same layout as the specified Bits except for the possible invalid bit patterns being checked during is_valid_bit_pattern.
Source§

fn is_valid_bit_pattern(_bits: &T) -> bool

If this function returns true, then it must be valid to reinterpret bits as &Self.
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<'a, T> Facet<'a> for T
where T: 'a,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> NoUninit for T
where T: Pod,

Source§

impl<T, Rhs> NumAssignOps<Rhs> for T
where T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>,

Source§

impl<T, Rhs, Output> NumOps<Rhs, Output> for T
where T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>,

Source§

impl<T> PodValue for T
where T: Copy + Debug + Default + PartialEq + Pod + Send + Sync + Serializable + 'static,

Source§

impl<T, Base> RefNum<Base> for T
where T: NumOps<Base, Base> + for<'r> NumOps<&'r Base, Base>,

Source§

impl<T> Serializable for T

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WasmComponentType for T