Panda3D
odeLMotorJoint.I
1 // Filename: odeLMotorJoint.I
2 // Created by: joswilso (27Dec06)
3 //
4 ////////////////////////////////////////////////////////////////////
5 //
6 // PANDA 3D SOFTWARE
7 // Copyright (c) Carnegie Mellon University. All rights reserved.
8 //
9 // All use of this software is subject to the terms of the revised BSD
10 // license. You should have received a copy of this license along
11 // with this source code in a file named "LICENSE."
12 //
13 ////////////////////////////////////////////////////////////////////
14 
15 
16 INLINE void OdeLMotorJoint::
17 set_num_axes(int num) {
18  dJointSetLMotorNumAxes(_id, num);
19 }
20 
21 INLINE void OdeLMotorJoint::
22 set_axis(int anum, int rel, dReal x, dReal y, dReal z) {
23  dJointSetLMotorAxis(_id, anum, rel, x, y, z);
24 }
25 
26 INLINE void OdeLMotorJoint::
27 set_axis(int anum, int rel, const LVecBase3f &axis) {
28  dJointSetLMotorAxis(_id, anum, rel, axis[0], axis[1], axis[2]);
29 }
30 
31 INLINE void OdeLMotorJoint::
32 set_param(int parameter, dReal value) {
33  dJointSetLMotorParam(_id, parameter, value);
34 }
35 
36 INLINE int OdeLMotorJoint::
37 get_num_axes() const {
38  return dJointGetLMotorNumAxes(_id);
39 }
40 
41 INLINE LVecBase3f OdeLMotorJoint::
42 get_axis(int anum) const {
43  dVector3 result;
44  dJointGetLMotorAxis(_id, anum, result);
45  return LVecBase3f(result[0], result[1], result[2]);
46 }
47 
48 INLINE dReal OdeLMotorJoint::
49 get_param(int parameter) const {
50  return dJointGetLMotorParam(_id, parameter);
51 }
52 
This is the base class for all three-component vectors and points.
Definition: lvecBase3.h:105