use na::{Transform, Rotate}; use na; use entities::bounding_volume::AABB; use entities::shape::Cuboid; use ray::{Ray, RayCast, RayIntersection}; use math::{Point, Vector}; impl
RayCast
for Cuboid + Rotate , solid: bool) -> Option< () + (-*self.half_extents());
let ur = na::origin:: () + *self.half_extents();
AABB::new(dl, ur).toi_with_ray(m, ray, solid)
}
#[inline]
fn toi_and_normal_with_ray(&self, m: &M, ray: &Ray , solid: bool) -> Option () + (-*self.half_extents());
let ur = na::origin:: () + *self.half_extents();
AABB::new(dl, ur).toi_and_normal_with_ray(m, ray, solid)
}
#[inline]
fn toi_and_normal_and_uv_with_ray(&self, m: &M, ray: &Ray , solid: bool) -> Option () + (-*self.half_extents());
let ur = na::origin:: () + *self.half_extents();
AABB::new(dl, ur).toi_and_normal_and_uv_with_ray(m, ray, solid)
}
}