[][src]Struct collision::primitive::Particle

pub struct Particle<P> { /* fields omitted */ }

Represents a particle in space.

Only have implementations of intersection tests for movement, using (Particle, Range<P>) where P is the positional Point of the particle at the start and end of movement. These intersection tests can be used with any primitive that has Ray intersection tests implemented.

Methods

impl<P> Particle<P>[src]

pub fn new() -> Self[src]

Create a new particle

Trait Implementations

impl<P> Continuous<Ray<<P as EuclideanSpace>::Scalar, P, <P as EuclideanSpace>::Diff>> for Particle<P> where
    P: EuclideanSpace,
    P::Diff: InnerSpace,
    P::Scalar: BaseFloat
[src]

type Result = P

Result returned by the intersection test

fn intersection(&self, ray: &Ray<P::Scalar, P, P::Diff>) -> Option<P>[src]

Ray needs to be in particle object space

impl<P> Discrete<Ray<<P as EuclideanSpace>::Scalar, P, <P as EuclideanSpace>::Diff>> for Particle<P> where
    P: EuclideanSpace,
    P::Diff: InnerSpace,
    P::Scalar: BaseFloat
[src]

fn intersects(&self, ray: &Ray<P::Scalar, P, P::Diff>) -> bool[src]

Ray needs to be in particle object space

impl<P: Clone> Clone for Particle<P>[src]

default fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl<P: PartialEq> PartialEq<Particle<P>> for Particle<P>[src]

impl<S> From<Particle<Point2<S>>> for Primitive2<S>[src]

impl<S> From<Particle<Point3<S>>> for Primitive3<S> where
    S: BaseFloat
[src]

impl<P: Debug> Debug for Particle<P>[src]

Auto Trait Implementations

impl<P> Send for Particle<P> where
    P: Send

impl<P> Sync for Particle<P> where
    P: Sync

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]