Panda3D
 All Classes Functions Variables Enumerations
physxCapsuleControllerDesc.cxx
1 // Filename: physxCapsuleControllerDesc.cxx
2 // Created by: enn0x (22Sep09)
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 #include "physxCapsuleControllerDesc.h"
16 
17 ////////////////////////////////////////////////////////////////////
18 // Function: PhysxCapsuleControllerDesc::set_radius
19 // Access: Published
20 // Description: Sets the radius of the capsule's hemispherical
21 // ends and its trunk.
22 ////////////////////////////////////////////////////////////////////
24 set_radius(float radius) {
25 
26  _desc.radius = radius;
27 }
28 
29 ////////////////////////////////////////////////////////////////////
30 // Function: PhysxCapsuleControllerDesc::set_height
31 // Access: Published
32 // Description: Sets the distance between the two hemispherical
33 // ends of the capsule.
34 ////////////////////////////////////////////////////////////////////
36 set_height(float height) {
37 
38  _desc.height = height;
39 }
40 
41 ////////////////////////////////////////////////////////////////////
42 // Function: PhysxCapsuleControllerDesc::get_radius
43 // Access: Published
44 // Description: The radius of the capsule's hemispherical ends
45 // and its trunk.
46 ////////////////////////////////////////////////////////////////////
48 get_radius() const {
49 
50  return _desc.radius;
51 }
52 
53 ////////////////////////////////////////////////////////////////////
54 // Function: PhysxCapsuleControllerDesc::get_height
55 // Access: Published
56 // Description: The distance between the two hemispherical ends
57 // of the capsule.
58 ////////////////////////////////////////////////////////////////////
60 get_height() const {
61 
62  return _desc.height;
63 }
64 
float get_radius() const
The radius of the capsule's hemispherical ends and its trunk.
float get_height() const
The distance between the two hemispherical ends of the capsule.
void set_height(float height)
Sets the distance between the two hemispherical ends of the capsule.
void set_radius(float radius)
Sets the radius of the capsule's hemispherical ends and its trunk.