1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
use libc::size_t;
use super::super::dynamics::body::{Body};
pub mod revolute_joint;
#[repr(C)]
#[derive(Debug, Clone, Copy)]
pub enum JointType {
UnknownJoint = 0,
RevoluteJoint,
PrismaticJoint,
DistanceJoint,
PulleyJoint,
MouseJoint,
GearJoint,
WheelJoint,
WeldJoint,
FrictionJoint,
RopeJoint,
MotorJoint
}
#[derive(Debug)]
pub struct JointDef {
pub joint_type: JointType,
pub user_data: size_t,
pub body_a: Option<Body>,
pub body_b: Option<Body>,
pub collide_connected: bool,
}
impl Default for JointDef {
fn default() -> JointDef {
JointDef {
joint_type: JointType::UnknownJoint,
user_data: 0,
body_a: None,
body_b: None,
collide_connected: false,
}
}
}