pub struct SceneRayHit {
pub mesh: MeshId,
pub hit: RayHit,
pub point: [f64; 3],
pub t: f64,
}Expand description
Where a world ray hit a mesh of the scene.
Fields§
§mesh: MeshIdThe mesh that was hit.
hit: RayHitThe hit as the Phase 3 raycast reported it, in the mesh’s local space.
point: [f64; 3]The hit point in the world: hit.point placed by the mesh’s origin
and placement.
t: f64The world distance from the ray’s origin: hit.t, which is a world
distance because the mapped local ray keeps the parameter (the
placement is affine, so apply(origin_l + t * dir_l) is the world
point at t).
Trait Implementations§
Source§impl Clone for SceneRayHit
impl Clone for SceneRayHit
Source§fn clone(&self) -> SceneRayHit
fn clone(&self) -> SceneRayHit
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for SceneRayHit
Source§impl Debug for SceneRayHit
impl Debug for SceneRayHit
Source§impl PartialEq for SceneRayHit
impl PartialEq for SceneRayHit
impl StructuralPartialEq for SceneRayHit
Auto Trait Implementations§
impl Freeze for SceneRayHit
impl RefUnwindSafe for SceneRayHit
impl Send for SceneRayHit
impl Sync for SceneRayHit
impl Unpin for SceneRayHit
impl UnsafeUnpin for SceneRayHit
impl UnwindSafe for SceneRayHit
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more