pub enum PhysicsJointKind {
Fixed,
Revolute,
Spherical,
Prismatic,
}Expand description
The constraint shape a PhysicsJoint declares.
Variants§
Fixed
All 6 degrees of freedom locked. The bodies move and rotate as one rigid assembly relative to their anchors. Use to weld two props together.
Revolute
Single rotational axis. Rotation around axis (in each body’s local
frame) is free; everything else is locked. The canonical door hinge.
Spherical
Three rotational axes free, all translation locked. Ball-and-socket joint: the canonical rope link or a hip socket.
Prismatic
Single translational axis. Sliding along axis is free; rotation and
the other two translational axes are locked. The canonical slider /
piston.
Implementations§
Source§impl PhysicsJointKind
impl PhysicsJointKind
Sourcepub fn from_str_norm(s: &str) -> Option<PhysicsJointKind>
pub fn from_str_norm(s: &str) -> Option<PhysicsJointKind>
The kind an authored name selects, accepting the common synonyms
(hinge, ball, slider, …). None for an unknown name.
Trait Implementations§
Source§impl Clone for PhysicsJointKind
impl Clone for PhysicsJointKind
Source§fn clone(&self) -> PhysicsJointKind
fn clone(&self) -> PhysicsJointKind
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 PhysicsJointKind
Source§impl Debug for PhysicsJointKind
impl Debug for PhysicsJointKind
impl Eq for PhysicsJointKind
Source§impl PartialEq for PhysicsJointKind
impl PartialEq for PhysicsJointKind
impl StructuralPartialEq for PhysicsJointKind
Auto Trait Implementations§
impl Freeze for PhysicsJointKind
impl RefUnwindSafe for PhysicsJointKind
impl Send for PhysicsJointKind
impl Sync for PhysicsJointKind
impl Unpin for PhysicsJointKind
impl UnsafeUnpin for PhysicsJointKind
impl UnwindSafe for PhysicsJointKind
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.