tools/celhpf.h
00001 /* 00002 Crystal Space Entity Layer 00003 Copyright (C) 2010 by Leonardo Rodrigo Domingues 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Library General Public 00007 License as published by the Free Software Foundation; either 00008 version 2 of the License, or (at your option) any later version. 00009 00010 This library is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00013 Library General Public License for more details. 00014 00015 You should have received a copy of the GNU Library General Public 00016 License along with this library; if not, write to the Free 00017 Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00018 */ 00019 00020 #ifndef __CEL_HPFAPI__ 00021 #define __CEL_HPFAPI__ 00022 00023 #include <csutil/scf.h> 00024 #include <csutil/list.h> 00025 #include <tools/celnavmesh.h> 00026 00027 #include "iutil/vfs.h" 00028 00029 class csBox3; 00030 class csOBB; 00031 class csString; 00032 class csVector3; 00033 struct csSimpleRenderMesh; 00034 struct iCelNavMeshParams; 00035 struct iCelPath; 00036 struct iSector; 00037 struct iSectorList; 00038 struct iMapNode; 00039 00040 00041 00045 struct iCelHPath : public virtual iBase 00046 { 00047 SCF_INTERFACE (iCelHPath, 1, 0, 0); 00048 00050 virtual bool HasNext () const = 0; 00051 00053 virtual bool HasPrevious () const = 0; 00054 00056 virtual iMapNode* Next () = 0; 00057 00059 virtual iMapNode* Previous () = 0; 00060 00062 virtual iMapNode* Current () = 0; 00063 00065 virtual iMapNode* GetFirst () = 0; 00066 00068 virtual iMapNode* GetLast () = 0; 00069 00071 virtual void Invert () = 0; 00072 00074 virtual void Restart () = 0; 00075 00077 virtual float GetDistance () const = 0; 00078 00082 virtual csArray<csSimpleRenderMesh*>* GetDebugMeshes () = 0; 00083 }; 00084 00085 00086 00090 struct iCelHNavStruct : public virtual iBase 00091 { 00092 SCF_INTERFACE (iCelHNavStruct, 1, 1, 0); 00093 00104 virtual iCelHPath* ShortestPath (const csVector3& from, iSector* fromSector, const csVector3& goal, 00105 iSector* goalSector) = 0; 00106 00115 virtual iCelHPath* ShortestPath (iMapNode* from, iMapNode* goal) = 0; 00116 00124 virtual bool Update (const csBox3& boundingBox, iSector* sector = 0) = 0; 00125 00133 virtual bool Update (const csOBB& boundingBox, iSector* sector = 0) = 0; 00134 00142 virtual bool SaveToFile (iVFS* vfs, const char* directory) = 0; 00143 00148 virtual const iCelNavMeshParams* GetNavMeshParams () const = 0; 00149 00153 virtual csArray<csSimpleRenderMesh*>* GetDebugMeshes (iSector* sector = 0) = 0; 00154 00159 virtual csArray<csSimpleRenderMesh*>* GetAgentDebugMeshes (const csVector3& pos, int red, int green, 00160 int blue, int alpha) = 0; 00161 00165 virtual void ResetAgentDebugMeshes () = 0; 00166 }; 00167 00168 00169 00173 struct iCelHNavStructBuilder : public virtual iBase 00174 { 00175 SCF_INTERFACE (iCelHNavStructBuilder, 1, 0, 0); 00176 00183 virtual bool SetSectors(csRefArray<iSector>* sectorList) = 0; 00184 00189 virtual iCelHNavStruct* BuildHNavStruct () = 0; 00190 00198 virtual iCelHNavStruct* LoadHNavStruct (iVFS* vfs, const char* directory) = 0; 00199 00204 virtual const iCelNavMeshParams* GetNavMeshParams () const = 0; 00205 00210 virtual void SetNavMeshParams (const iCelNavMeshParams* parameters) = 0; 00211 }; 00212 00213 #endif // __CEL_HPFAPI__
Generated for CEL: Crystal Entity Layer 2.1 by doxygen 1.6.1
