pub struct BodyCastResult {
pub shape_id: ShapeId,
pub point: Pos,
pub normal: Vec3,
pub fraction: f32,
pub triangle_index: i32,
pub user_material_id: u64,
pub iterations: i32,
pub hit: bool,
}Expand description
Body cast result for ray and shape casts. (b3BodyCastResult)
Fields§
§shape_id: ShapeIdThe shape hit.
point: PosThe world point on the shape surface.
normal: Vec3The world normal vector on the shape surface.
fraction: f32The fraction along the ray hit. hit point = origin + fraction * translation
triangle_index: i32The triangle index if the shape is a mesh or height-field.
user_material_id: u64The user material id at the hit point.
iterations: i32The number of iterations used. Diagnostic.
hit: boolDid the cast hit? If false, all other fields are invalid.
Trait Implementations§
Source§impl Clone for BodyCastResult
impl Clone for BodyCastResult
Source§fn clone(&self) -> BodyCastResult
fn clone(&self) -> BodyCastResult
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 BodyCastResult
Source§impl Debug for BodyCastResult
impl Debug for BodyCastResult
Source§impl Default for BodyCastResult
impl Default for BodyCastResult
Source§impl PartialEq for BodyCastResult
impl PartialEq for BodyCastResult
impl StructuralPartialEq for BodyCastResult
Auto Trait Implementations§
impl Freeze for BodyCastResult
impl RefUnwindSafe for BodyCastResult
impl Send for BodyCastResult
impl Sync for BodyCastResult
impl Unpin for BodyCastResult
impl UnsafeUnpin for BodyCastResult
impl UnwindSafe for BodyCastResult
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