Struct bevy_math::primitives::Capsule3d
source · pub struct Capsule3d {
pub radius: f32,
pub half_length: f32,
}
Expand description
A 3D capsule primitive. A three-dimensional capsule is defined as a surface at a distance (radius) from a line
Fields§
§radius: f32
The radius of the capsule
half_length: f32
Half the height of the capsule, excluding the hemispheres
Implementations§
Trait Implementations§
source§impl Bounded3d for Capsule3d
impl Bounded3d for Capsule3d
source§fn aabb_3d(&self, translation: Vec3, rotation: Quat) -> Aabb3d
fn aabb_3d(&self, translation: Vec3, rotation: Quat) -> Aabb3d
Get an axis-aligned bounding box for the shape with the given translation and rotation
source§fn bounding_sphere(&self, translation: Vec3, _rotation: Quat) -> BoundingSphere
fn bounding_sphere(&self, translation: Vec3, _rotation: Quat) -> BoundingSphere
Get a bounding sphere for the shape with the given translation and rotation
source§impl<'de> Deserialize<'de> for Capsule3d
impl<'de> Deserialize<'de> for Capsule3d
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq for Capsule3d
impl PartialEq for Capsule3d
impl Copy for Capsule3d
impl Primitive3d for Capsule3d
impl StructuralPartialEq for Capsule3d
Auto Trait Implementations§
impl RefUnwindSafe for Capsule3d
impl Send for Capsule3d
impl Sync for Capsule3d
impl Unpin for Capsule3d
impl UnwindSafe for Capsule3d
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