pub enum JointSpec {
Fixed,
Revolute {
axis: [f32; 3],
limits: Option<[f32; 2]>,
motor: Option<JointMotor>,
},
Spherical,
Prismatic {
axis: [f32; 3],
limits: Option<[f32; 2]>,
motor: Option<JointMotor>,
},
}Expand description
Constraint shape connecting two bodies.
Variants§
Fixed
All six degrees of freedom locked: the bodies move and rotate as one rigid assembly relative to their anchors.
Revolute
Hinge: rotation is allowed only around one axis.
Fields
§
motor: Option<JointMotor>Drives the hinge at a target angular velocity.
Spherical
Ball-and-socket: translation locked, all three rotational axes free.
Prismatic
Slider: translation is allowed only along one axis.
Trait Implementations§
impl Copy for JointSpec
impl StructuralPartialEq for JointSpec
Auto Trait Implementations§
impl Freeze for JointSpec
impl RefUnwindSafe for JointSpec
impl Send for JointSpec
impl Sync for JointSpec
impl Unpin for JointSpec
impl UnsafeUnpin for JointSpec
impl UnwindSafe for JointSpec
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