Panda3D

physxMaterialDesc.h

00001 // Filename: physxMaterialDesc.h
00002 // Created by:  enn0x (21Sep09)
00003 //
00004 ////////////////////////////////////////////////////////////////////
00005 //
00006 // PANDA 3D SOFTWARE
00007 // Copyright (c) Carnegie Mellon University.  All rights reserved.
00008 //
00009 // All use of this software is subject to the terms of the revised BSD
00010 // license.  You should have received a copy of this license along
00011 // with this source code in a file named "LICENSE."
00012 //
00013 ////////////////////////////////////////////////////////////////////
00014 
00015 #ifndef PHYSXMATERIALDESC_H
00016 #define PHYSXMATERIALDESC_H
00017 
00018 #include "pandabase.h"
00019 
00020 #include "physxEnums.h"
00021 #include "physx_includes.h"
00022 
00023 ////////////////////////////////////////////////////////////////////
00024 //       Class : PhysxMaterialDesc
00025 // Description : Descriptor class for materials. See PhysxMaterial.
00026 ////////////////////////////////////////////////////////////////////
00027 class EXPCL_PANDAPHYSX PhysxMaterialDesc : public PhysxEnums {
00028 
00029 PUBLISHED:
00030   INLINE PhysxMaterialDesc();
00031   INLINE ~PhysxMaterialDesc();
00032 
00033   INLINE void set_to_default();
00034   INLINE bool is_valid() const;
00035 
00036   void set_dynamic_friction(float coef);
00037   void set_static_friction(float coef);
00038   void set_restitution(float rest);
00039   void set_dynamic_friction_v(float coef);
00040   void set_static_friction_v(float coef);
00041   void set_dir_of_anisotropy(const LVector3f dir);
00042   void set_flag(PhysxMaterialFlag flag, bool value);
00043   void set_friction_combine_mode(PhysxCombineMode mode);
00044   void set_restitution_combine_mode(PhysxCombineMode mode);
00045 
00046   float get_dynamic_friction() const;
00047   float get_static_friction() const;
00048   float get_restitution() const;
00049   float get_dynamic_friction_v() const;
00050   float get_static_friction_v() const;
00051   LVector3f get_dir_of_anisotropy() const;
00052   bool get_flag(PhysxMaterialFlag flag) const;
00053   PhysxCombineMode get_friction_combine_mode() const;
00054   PhysxCombineMode get_restitution_combine_mode() const;
00055 
00056 public:
00057   NxMaterialDesc _desc;
00058 };
00059 
00060 #include "physxMaterialDesc.I"
00061 
00062 #endif // PHYSXMATERIALDESC_H
 All Classes Functions Variables Enumerations