Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00022
00023 #ifndef __VR3PHYMESHMANAGER_H__
00024 #define __VR3PHYMESHMANAGER_H__
00025
00026
00027 #if (defined(_WIN32) || defined(_WIN64)) && !defined(VR3CONF_NOPHYSICS)
00028
00029
00030 #include <map>
00031
00032 #include <VR3Map.h>
00033
00035
00051 class VR3PhyMeshManager {
00053 struct MapElement {
00055 VR3PhyMesh* phymesh;
00057 int count;
00058 };
00059
00061
00062 static std::map<std::string, std::map<int,MapElement>, VR3Map::Less> ms_phymeshes;
00063
00065 VR3PhyMeshManager();
00066
00067
00068
00069
00071
00072
00074
00081 static void LoadStaticAAM(std::ifstream& is, VR3PhyMesh* phymesh);
00082
00084
00093 static void LoadNonStaticAAM( std::ifstream& is, VR3PhyMesh* phymesh);
00094
00095 public:
00096
00098
00112 static void LoadAAM( const char* file_name, VR3PhyMesh* phymesh,
00113 const char* mesh_name = 0, int objID = -1 );
00114
00116
00117
00118
00120
00121
00122 private:
00123
00125
00134 static void CreatePhyMesh(VR3PhyMesh* phymesh);
00135
00136 public:
00137
00139
00152 static VR3PhyMesh* FindPhyMesh( const char* file_name,
00153 const char* mesh_name = 0, int objID = -1 );
00154
00156
00164 static void DeleteReference(VR3PhyMesh* phymesh);
00165
00167
00177 static void AddReference(VR3PhyMesh* phymesh);
00178
00180
00181
00182
00184
00185
00187
00204 static int ListPhyMeshesAAM( const char* file_name,
00205 int ids[],
00206 std::string mesh_names[],
00207 int count );
00208
00210
00211 };
00212
00213 #endif // windows only
00214
00215 #endif