Trait parry3d::query::RayCast

source ·
pub trait RayCast {
    // Required method
    fn cast_local_ray_and_get_normal(
        &self,
        ray: &Ray,
        max_time_of_impact: Real,
        solid: bool
    ) -> Option<RayIntersection>;

    // Provided methods
    fn cast_local_ray(
        &self,
        ray: &Ray,
        max_time_of_impact: Real,
        solid: bool
    ) -> Option<Real> { ... }
    fn intersects_local_ray(&self, ray: &Ray, max_time_of_impact: Real) -> bool { ... }
    fn cast_ray(
        &self,
        m: &Isometry<Real>,
        ray: &Ray,
        max_time_of_impact: Real,
        solid: bool
    ) -> Option<Real> { ... }
    fn cast_ray_and_get_normal(
        &self,
        m: &Isometry<Real>,
        ray: &Ray,
        max_time_of_impact: Real,
        solid: bool
    ) -> Option<RayIntersection> { ... }
    fn intersects_ray(
        &self,
        m: &Isometry<Real>,
        ray: &Ray,
        max_time_of_impact: Real
    ) -> bool { ... }
}
Expand description

Traits of objects which can be transformed and tested for intersection with a ray.

Required Methods§

source

fn cast_local_ray_and_get_normal( &self, ray: &Ray, max_time_of_impact: Real, solid: bool ) -> Option<RayIntersection>

Computes the time of impact, and normal between this transformed shape and a ray.

Provided Methods§

source

fn cast_local_ray( &self, ray: &Ray, max_time_of_impact: Real, solid: bool ) -> Option<Real>

Computes the time of impact between this transform shape and a ray.

source

fn intersects_local_ray(&self, ray: &Ray, max_time_of_impact: Real) -> bool

Tests whether a ray intersects this transformed shape.

source

fn cast_ray( &self, m: &Isometry<Real>, ray: &Ray, max_time_of_impact: Real, solid: bool ) -> Option<Real>

Computes the time of impact between this transform shape and a ray.

source

fn cast_ray_and_get_normal( &self, m: &Isometry<Real>, ray: &Ray, max_time_of_impact: Real, solid: bool ) -> Option<RayIntersection>

Computes the time of impact, and normal between this transformed shape and a ray.

source

fn intersects_ray( &self, m: &Isometry<Real>, ray: &Ray, max_time_of_impact: Real ) -> bool

Tests whether a ray intersects this transformed shape.

Implementors§