Skip to main content

Point

Struct Point 

Source
pub struct Point;

Trait Implementations§

Source§

impl Clone for Point

Source§

fn clone(&self) -> Point

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<A> CollidesRel2d<A> for Point
where A: DefaultCol2dImpls + CollidesRel2d<Point>,

Source§

fn collides_rel(&self, other: &A, rel: &impl Transformation2d) -> bool

Checks whether objects collide. Read more
Source§

impl CollidesRel2d<Point> for Ball

Source§

fn collides_rel(&self, _t: &Point, rel: &impl Transformation2d) -> bool

Checks whether objects collide. Read more
Source§

impl CollidesRel2d<Point> for Box2d

Source§

fn collides_rel(&self, _t: &Point, rel: &impl Transformation2d) -> bool

Checks whether objects collide. Read more
Source§

impl CollidesRel2d<Point> for RoundedBox2d

Source§

fn collides_rel(&self, t: &Point, rel: &impl Transformation2d) -> bool

Checks whether objects collide. Read more
Source§

impl CollidesRel2d<Point> for Tilemap

Source§

fn collides_rel(&self, _t: &Point, rel: &impl Transformation2d) -> bool

Checks whether objects collide. Read more
Source§

impl<A> CollidesRel3d<A> for Point
where A: DefaultCol3dImpls + CollidesRel3d<Point>,

Source§

fn collides_rel(&self, other: &A, rel: &impl Transformation3d) -> bool

Checks whether objects collide. Read more
Source§

impl CollidesRel3d<Point> for Ball

Source§

fn collides_rel(&self, _t: &Point, rel: &impl Transformation3d) -> bool

Checks whether objects collide. Read more
Source§

impl CollidesRel3d<Point> for Box3d

Source§

fn collides_rel(&self, _t: &Point, rel: &impl Transformation3d) -> bool

Checks whether objects collide. Read more
Source§

impl Copy for Point

Source§

impl Debug for Point

Source§

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

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

impl Default for Point

Source§

fn default() -> Point

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

impl Eq for Point

Source§

impl ExtremePoint2d for Point

Source§

fn extreme_point(&self, _direction: Vec2) -> Vec2

Computes the farthest point along a direction. Read more
Source§

impl ExtremePoint3d for Point

Source§

fn extreme_point(&self, _direction: Vec3) -> Vec3

Computes the farthest point along a direction. Read more
Source§

impl From<()> for Point

Source§

fn from(_: ()) -> Self

Converts to this type from the input type.
Source§

impl Hash for Point

Source§

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

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 MinkowskiNegationIsIdentity for Point

Source§

impl Ord for Point

Source§

fn cmp(&self, other: &Point) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 (const: unstable) · Source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 (const: unstable) · Source§

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

Restrict a value to a certain interval. Read more
Source§

impl PartialEq for Point

Source§

fn eq(&self, other: &Point) -> 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 PartialOrd for Point

Source§

fn partial_cmp(&self, other: &Point) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl<A> PenetratesRel2d<A> for Point
where A: DefaultCol2dImpls + PenetratesRel2d<Point>,

Source§

fn penetrates_rel(&self, other: &A, rel: &impl Transformation2d) -> Option<Vec2>

Computes the smallest penetration vector between self and t. Read more
Source§

impl PenetratesRel2d<Point> for Ball

Source§

fn penetrates_rel(&self, t: &Point, rel: &impl Transformation2d) -> Option<Vec2>

Computes the smallest penetration vector between self and t. Read more
Source§

impl PenetratesRel2d<Point> for Box2d

Source§

fn penetrates_rel(&self, t: &Point, rel: &impl Transformation2d) -> Option<Vec2>

Computes the smallest penetration vector between self and t. Read more
Source§

impl PenetratesRel2d<Point> for RoundedBox2d

Source§

fn penetrates_rel(&self, t: &Point, rel: &impl Transformation2d) -> Option<Vec2>

Computes the smallest penetration vector between self and t. Read more
Source§

impl PenetratesRel2d<Point> for Tilemap

Source§

fn penetrates_rel( &self, _t: &Point, rel: &impl Transformation2d, ) -> Option<Vec2>

Computes the smallest penetration vector between self and t. Read more
Source§

impl<A> PenetratesRel3d<A> for Point
where A: DefaultCol3dImpls + PenetratesRel3d<Point>,

Source§

fn penetrates_rel(&self, other: &A, rel: &impl Transformation3d) -> Option<Vec3>

Computes the smallest penetration vector between self and t. Read more
Source§

impl PenetratesRel3d<Point> for Ball

Source§

fn penetrates_rel(&self, t: &Point, rel: &impl Transformation3d) -> Option<Vec3>

Computes the smallest penetration vector between self and t. Read more
Source§

impl PenetratesRel3d<Point> for Box3d

Source§

fn penetrates_rel(&self, t: &Point, rel: &impl Transformation3d) -> Option<Vec3>

Computes the smallest penetration vector between self and t. Read more
Source§

impl<A> SdfRel2d<A> for Point
where A: DefaultCol2dImpls + SdfRel2d<Point>,

Source§

fn sdf_rel(&self, t: &A, rel: &impl Transformation2d) -> f32

Computes scalar signed-distance between self and t. Read more
Source§

impl SdfRel2d<Point> for Ball

Source§

fn sdf_rel(&self, _t: &Point, rel: &impl Transformation2d) -> f32

Computes scalar signed-distance between self and t. Read more
Source§

impl SdfRel2d<Point> for Box2d

Source§

fn sdf_rel(&self, t: &Point, rel: &impl Transformation2d) -> f32

Computes scalar signed-distance between self and t. Read more
Source§

impl SdfRel2d<Point> for RoundedBox2d

Source§

fn sdf_rel(&self, t: &Point, rel: &impl Transformation2d) -> f32

Computes scalar signed-distance between self and t. Read more
Source§

impl<A> SdfRel2dVector<A> for Point
where A: DefaultCol2dImpls + SdfRel2dVector<Point>,

Source§

fn sdfv_rel(&self, t: &A, rel: &impl Transformation2d) -> Vec2

Computes vector signed-distance between self and t. Read more
Source§

impl SdfRel2dVector<Point> for Ball

Source§

fn sdfv_rel(&self, _t: &Point, rel: &impl Transformation2d) -> Vec2

Computes vector signed-distance between self and t. Read more
Source§

impl SdfRel2dVector<Point> for Box2d

Source§

fn sdfv_rel(&self, t: &Point, rel: &impl Transformation2d) -> Vec2

Computes vector signed-distance between self and t. Read more
Source§

impl SdfRel2dVector<Point> for RoundedBox2d

Source§

fn sdfv_rel(&self, t: &Point, rel: &impl Transformation2d) -> Vec2

Computes vector signed-distance between self and t. Read more
Source§

impl<A> SdfRel3d<A> for Point
where A: DefaultCol3dImpls + SdfRel3d<Point>,

Source§

fn sdf_rel(&self, t: &A, rel: &impl Transformation3d) -> f32

Computes scalar signed-distance between self and t. Read more
Source§

impl SdfRel3d<Point> for Ball

Source§

fn sdf_rel(&self, _t: &Point, rel: &impl Transformation3d) -> f32

Computes scalar signed-distance between self and t. Read more
Source§

impl SdfRel3d<Point> for Box3d

Source§

fn sdf_rel(&self, t: &Point, rel: &impl Transformation3d) -> f32

Computes scalar signed-distance between self and t. Read more
Source§

impl<A> SdfRel3dVector<A> for Point
where A: DefaultCol3dImpls + SdfRel3dVector<Point>,

Source§

fn sdfv_rel(&self, t: &A, rel: &impl Transformation3d) -> Vec3

Computes vector signed-distance between self and t. Read more
Source§

impl SdfRel3dVector<Point> for Ball

Source§

fn sdfv_rel(&self, _t: &Point, rel: &impl Transformation3d) -> Vec3

Computes vector signed-distance between self and t. Read more
Source§

impl SdfRel3dVector<Point> for Box3d

Source§

fn sdfv_rel(&self, t: &Point, rel: &impl Transformation3d) -> Vec3

Computes vector signed-distance between self and t. Read more
Source§

impl StructuralPartialEq for Point

Source§

impl SymmetricBoundingBox2d for Point

Source§

fn symmetric_bounding_box(&self) -> Box2d

Computes the bounding box. Read more

Auto Trait Implementations§

§

impl Freeze for Point

§

impl RefUnwindSafe for Point

§

impl Send for Point

§

impl Sync for Point

§

impl Unpin for Point

§

impl UnsafeUnpin for Point

§

impl UnwindSafe for Point

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> 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> 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, B, T> Collides2d<B, T> for A

Source§

fn collides(&self, transform: &T, t: &B, t_transform: &T) -> bool

Checks whether objects collide. Read more
Source§

impl<A, B, T> Collides3d<B, T> for A

Source§

fn collides(&self, transform: &T, t: &B, t_transform: &T) -> bool

Checks whether objects collide. Read more
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> MinkowskiNegation for T

Source§

fn minkowski_negation(&self) -> T

Computes Minkowski negation. (Reflection about the origin) Read more
Source§

impl<A, B, T> Penetrates2d<B, T> for A

Source§

fn penetrates(&self, a_transform: &T, b: &B, b_transform: &T) -> Option<Vec2>

Computes the smallest penetration vector between self and t. Read more
Source§

impl<A, B, T> Penetrates3d<B, T> for A

Source§

fn penetrates(&self, transform: &T, t: &B, t_transform: &T) -> Option<Vec3>

Computes the smallest penetration vector between self and t. Read more
Source§

impl<A, B, T> Sdf2d<B, T> for A

Source§

fn sdf(&self, a_transform: &T, b: &B, b_transform: &T) -> f32

Computes scalar signed-distance between self and t. Read more
Source§

impl<A, B, T> Sdf2dVector<B, T> for A

Source§

fn sdfv(&self, a_transform: &T, b: &B, b_transform: &T) -> Vec2

Computes vector signed-distance between self and t. Read more
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.