00001 /* 00002 =========================================================================== 00003 Copyright (C) 1999-2005 Id Software, Inc. 00004 00005 This file is part of Quake III Arena source code. 00006 00007 Quake III Arena source code is free software; you can redistribute it 00008 and/or modify it under the terms of the GNU General Public License as 00009 published by the Free Software Foundation; either version 2 of the License, 00010 or (at your option) any later version. 00011 00012 Quake III Arena source code is distributed in the hope that it will be 00013 useful, but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 GNU General Public License for more details. 00016 00017 You should have received a copy of the GNU General Public License 00018 along with Foobar; if not, write to the Free Software 00019 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00020 =========================================================================== 00021 */ 00022 00023 #define AAS_MAX_BBOXES 5 00024 #define AAS_MAX_VERTEXES 512000 00025 #define AAS_MAX_PLANES 65536 00026 #define AAS_MAX_EDGES 512000 00027 #define AAS_MAX_EDGEINDEXSIZE 512000 00028 #define AAS_MAX_FACES 512000 00029 #define AAS_MAX_FACEINDEXSIZE 512000 00030 #define AAS_MAX_AREAS 65536 00031 #define AAS_MAX_AREASETTINGS 65536 00032 #define AAS_MAX_REACHABILITYSIZE 65536 00033 #define AAS_MAX_NODES 256000 00034 #define AAS_MAX_PORTALS 65536 00035 #define AAS_MAX_PORTALINDEXSIZE 65536 00036 #define AAS_MAX_CLUSTERS 65536 00037 00038 #define BSPCINCLUDE 00039 #include "../game/be_aas.h" 00040 #include "../botlib/be_aas_def.h" 00041 00042 /* 00043 typedef struct bspc_aas_s 00044 { 00045 int loaded; 00046 int initialized; //true when AAS has been initialized 00047 int savefile; //set true when file should be saved 00048 //bounding boxes 00049 int numbboxes; 00050 aas_bbox_t *bboxes; 00051 //vertexes 00052 int numvertexes; 00053 aas_vertex_t *vertexes; 00054 //planes 00055 int numplanes; 00056 aas_plane_t *planes; 00057 //edges 00058 int numedges; 00059 aas_edge_t *edges; 00060 //edge index 00061 int edgeindexsize; 00062 aas_edgeindex_t *edgeindex; 00063 //faces 00064 int numfaces; 00065 aas_face_t *faces; 00066 //face index 00067 int faceindexsize; 00068 aas_faceindex_t *faceindex; 00069 //convex areas 00070 int numareas; 00071 aas_area_t *areas; 00072 //convex area settings 00073 int numareasettings; 00074 aas_areasettings_t *areasettings; 00075 //reachablity list 00076 int reachabilitysize; 00077 aas_reachability_t *reachability; 00078 //nodes of the bsp tree 00079 int numnodes; 00080 aas_node_t *nodes; 00081 //cluster portals 00082 int numportals; 00083 aas_portal_t *portals; 00084 //cluster portal index 00085 int portalindexsize; 00086 aas_portalindex_t *portalindex; 00087 //clusters 00088 int numclusters; 00089 aas_cluster_t *clusters; 00090 // 00091 int numreachabilityareas; 00092 float reachabilitytime; 00093 } bspc_aas_t; 00094 00095 extern bspc_aas_t aasworld; 00096 //*/ 00097 00098 extern aas_t aasworld; 00099 00100 //stores the AAS file from the temporary AAS 00101 void AAS_StoreFile(char *filename); 00102 //returns a number of the given plane 00103 qboolean AAS_FindPlane(vec3_t normal, float dist, int *planenum); 00104 //allocates the maximum AAS memory for storage 00105 void AAS_AllocMaxAAS(void); 00106 //frees the maximum AAS memory for storage 00107 void AAS_FreeMaxAAS(void);
1.3.9.1