Skip to main content

Joint

Trait Joint 

Source
pub trait Joint: Obj {
    type Qpos: for<'q> TryFrom<&'q [f64]> + AsRef<[f64]>;
    type Qvel: for<'q> TryFrom<&'q [f64]> + AsRef<[f64]>;

    const MJT: mjtJoint;
    const QPOS_SIZE: usize;
    const QVEL_SIZE: usize;
}

Required Associated Constants§

Required Associated Types§

Source

type Qpos: for<'q> TryFrom<&'q [f64]> + AsRef<[f64]>

Source

type Qvel: for<'q> TryFrom<&'q [f64]> + AsRef<[f64]>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl Joint for Ball

Source§

const MJT: mjtJoint = super::mjtJoint::BALL

Source§

const QPOS_SIZE: usize = 4

Source§

const QVEL_SIZE: usize = 3

Source§

type Qpos = [f64; 4]

Source§

type Qvel = [f64; 3]

Source§

impl Joint for Free

Source§

const MJT: mjtJoint = super::mjtJoint::FREE

Source§

const QPOS_SIZE: usize = 7

Source§

const QVEL_SIZE: usize = 6

Source§

type Qpos = [f64; 7]

Source§

type Qvel = [f64; 6]

Source§

impl Joint for Hinge

Source§

const MJT: mjtJoint = super::mjtJoint::HINGE

Source§

const QPOS_SIZE: usize = 1

Source§

const QVEL_SIZE: usize = 1

Source§

type Qpos = [f64; 1]

Source§

type Qvel = [f64; 1]

Source§

impl Joint for Slide

Source§

const MJT: mjtJoint = super::mjtJoint::SLIDE

Source§

const QPOS_SIZE: usize = 1

Source§

const QVEL_SIZE: usize = 1

Source§

type Qpos = [f64; 1]

Source§

type Qvel = [f64; 1]