00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef PHYSXCLOTHMESHDESC_H
00016 #define PHYSXCLOTHMESHDESC_H
00017
00018 #include "pandabase.h"
00019 #include "luse.h"
00020 #include "nodePath.h"
00021 #include "plist.h"
00022
00023 #include "physx_includes.h"
00024
00025
00026
00027
00028
00029 class EXPCL_PANDAPHYSX PhysxClothMeshDesc {
00030
00031 PUBLISHED:
00032 INLINE PhysxClothMeshDesc();
00033 INLINE ~PhysxClothMeshDesc();
00034
00035 INLINE bool is_valid() const;
00036
00037 void set_num_vertices(unsigned int n);
00038 void set_vertex(unsigned int idx,
00039 const LPoint3f &vert, const LPoint2f &texcoord);
00040
00041 void set_num_triangles(unsigned int n);
00042 void set_triangle(unsigned int idx,
00043 unsigned int i1, unsigned int i2, unsigned int i3);
00044
00045 void set_from_node_path(const NodePath &np);
00046
00047 public:
00048 INLINE const NxClothMeshDesc &get_desc() const;
00049 INLINE const plist<LPoint2f> get_texcoords() const;
00050
00051 private:
00052 NxClothMeshDesc _desc;
00053 NxVec3 *_points;
00054 NxU32 *_triangles;
00055
00056 LPoint2f *_texcoords;
00057 };
00058
00059 #include "physxClothMeshDesc.I"
00060
00061 #endif // PHYSXCLOTHMESHDESC_H