Panda3D
physxMaterialDesc.h
Go to the documentation of this file.
1 /**
2  * PANDA 3D SOFTWARE
3  * Copyright (c) Carnegie Mellon University. All rights reserved.
4  *
5  * All use of this software is subject to the terms of the revised BSD
6  * license. You should have received a copy of this license along
7  * with this source code in a file named "LICENSE."
8  *
9  * @file physxMaterialDesc.h
10  * @author enn0x
11  * @date 2009-09-21
12  */
13 
14 #ifndef PHYSXMATERIALDESC_H
15 #define PHYSXMATERIALDESC_H
16 
17 #include "pandabase.h"
18 
19 #include "physxEnums.h"
20 #include "physx_includes.h"
21 
22 /**
23  * Descriptor class for materials. See PhysxMaterial.
24  */
25 class EXPCL_PANDAPHYSX PhysxMaterialDesc : public PhysxEnums {
26 
27 PUBLISHED:
28  INLINE PhysxMaterialDesc();
29  INLINE ~PhysxMaterialDesc();
30 
31  INLINE void set_to_default();
32  INLINE bool is_valid() const;
33 
34  void set_dynamic_friction(float coef);
35  void set_static_friction(float coef);
36  void set_restitution(float rest);
37  void set_dynamic_friction_v(float coef);
38  void set_static_friction_v(float coef);
39  void set_dir_of_anisotropy(const LVector3f dir);
40  void set_flag(PhysxMaterialFlag flag, bool value);
41  void set_friction_combine_mode(PhysxCombineMode mode);
42  void set_restitution_combine_mode(PhysxCombineMode mode);
43 
44  float get_dynamic_friction() const;
45  float get_static_friction() const;
46  float get_restitution() const;
47  float get_dynamic_friction_v() const;
48  float get_static_friction_v() const;
49  LVector3f get_dir_of_anisotropy() const;
50  bool get_flag(PhysxMaterialFlag flag) const;
51  PhysxCombineMode get_friction_combine_mode() const;
52  PhysxCombineMode get_restitution_combine_mode() const;
53 
54 public:
55  NxMaterialDesc _desc;
56 };
57 
58 #include "physxMaterialDesc.I"
59 
60 #endif // PHYSXMATERIALDESC_H
Descriptor class for materials.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
This class exists just to provide scoping for the enums shared by PhysX classes.
Definition: physxEnums.h:355
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.