29 #include "../../../renderer/tr_local.h"
79 #define MAX_PATCH_SIZE 32
81 #define PLANENUM_LEAF -1
178 #define MAX_QPATH 256 // max length of a game pathname
186 #define MAX_GROUP_LIGHTS 16
235 char mapFileBase[1024];
281 #define CLIP_EPSILON 0.1f
284 #define PSIDE_FRONT 1
286 #define PSIDE_BOTH (PSIDE_FRONT|PSIDE_BACK)
287 #define PSIDE_FACING 4
337 #define MAX_INTER_AREA_PORTALS 1024
void WriteBspBrushMap(const char *name, uBrush_t *list)
void DrawWinding(const idWinding *w)
void PrintBrush(uBrush_t *brush)
void FlipTriList(mapTri_t *tris)
void MakeTreePortals(tree_t *tree)
void FixGlobalTjunctions(uEntity_t *e)
struct primitive_s primitive_t
bool BoundBrush(uBrush_t *brush)
struct hashVert_s * GetHashVert(idVec3 &v)
mapTri_t * CopyMapTri(const mapTri_t *tri)
void CarveTriByBeamTree(const struct beamTree_s *beamTree, const mapTri_t *tri, mapTri_t **lit, mapTri_t **unLit)
bool LoadDMapFile(const char *filename)
void DrawLine(idVec3 v1, idVec3 v2, int color)
void PutPrimitivesInAreas(uEntity_t *e)
mapTri_t * RemoveBadTris(const mapTri_t *tri)
idList< mapLight_t * > mapLights
uBrush_t * BrushFromBounds(const idBounds &bounds)
void FreeTree_r(node_t *node)
idWinding * WindingForTri(const mapTri_t *tri)
int FindFloatPlane(const idPlane &plane, bool *fixedDegeneracies=NULL)
tree_t * FaceBSP(bspface_t *list)
void DrawAuxWinding(const idWinding *w)
struct optVertex_s * islandLink
const struct hashVert_s * hashVert[3]
struct uPortal_s * next[2]
void FreeTri(mapTri_t *tri)
float BrushVolume(uBrush_t *brush)
mapTri_t * WindingToTriList(const idWinding *w, const mapTri_t *originalTri)
#define MAX_INTER_AREA_PORTALS
shadowOptLevel_t shadowOptLevel
void Prelight(uEntity_t *e)
mapLight_t * groupLights[MAX_GROUP_LIGHTS]
srfTriangles_t * shadowTris
mapTri_t * MergeTriLists(mapTri_t *a, mapTri_t *b)
struct optTri_s * backTri
void FixEntityTjunctions(uEntity_t *e)
void GLS_Triangle(const mapTri_t *tri, int code)
void GLS_BeginScene(void)
void FreeTriList(mapTri_t *a)
void Draw_ClearWindow(void)
void SplitBrush(uBrush_t *brush, int planenum, uBrush_t **front, uBrush_t **back)
void OptimizeGroupList(optimizeGroup_t *groupList)
void FreeTree(tree_t *tree)
struct optimizeGroup_s * groups
bspface_t * MakeVisibleBspFaceList(primitive_t *list)
struct optTri_s * frontTri
const idMaterial * material
GLsizei GLsizei GLcharARB * source
float MapTriArea(const mapTri_t *tri)
struct optVertex_s optVertex_t
GLfloat GLfloat GLfloat v2
struct drawSurfRef_s drawSurfRef_t
struct uPortal_s uPortal_t
struct bspbrush_s uBrush_t
void TriVertsFromOriginal(mapTri_t *tri, const mapTri_t *original)
mapTri_t * CullTrisInOpaqueLeafs(mapTri_t *triList, tree_t *tree)
void ClipTriList(const mapTri_t *list, const idPlane &plane, float epsilon, mapTri_t **front, mapTri_t **back)
void FloodAreas(uEntity_t *e)
struct node_s * children[2]
GLubyte GLubyte GLubyte GLubyte w
uBrush_t * CopyBrush(uBrush_t *brush)
mapTri_t * regeneratedTris
void FreeTreePortals_r(node_t *node)
mapTri_t * CopyTriList(const mapTri_t *a)
struct uPortal_s * portals
struct bspface_s bspface_t
void FreeBrush(uBrush_t *brushes)
void FreeOptimizeGroupList(optimizeGroup_t *groups)
void GLS_Winding(const idWinding *w, int code)
bspface_t * MakeStructuralBspFaceList(primitive_t *list)
void PlaneForTri(const mapTri_t *tri, idPlane &plane)
void HashTriangles(optimizeGroup_t *groupList)
struct optEdge_s * v1link
struct optVertex_s * optVert[3]
void FixAreaGroupsTjunctions(optimizeGroup_t *groupList)
bool CreateBrushWindings(uBrush_t *brush)
void SplitTrisToSurfaces(mapTri_t *triList, tree_t *tree)
srfTriangles_t * ShareMapTriVerts(const mapTri_t *tris)
GLubyte GLubyte GLubyte a
mapTri_t * AllocTri(void)
const idMaterial * material
GLenum GLsizei GLsizei height
struct parseMesh_s parseMesh_t
int CountBrushList(uBrush_t *brushes)
struct optimizeGroup_s optimizeGroup_t
srfTriangles_t * CreateLightShadow(optimizeGroup_t *shadowerGroups, const mapLight_t *light)
struct primitive_s * next
int CountGroupListTris(const optimizeGroup_t *groupList)
uBrush_t * AllocBrush(int numsides)
struct optEdge_s * islandLink
struct bspbrush_s * original
void BoundTriList(const mapTri_t *list, idBounds &b)
void FreeBrushList(uBrush_t *brushes)
const idMaterial * contentShader
void FreeTJunctionHash(void)
void FreeBeamTree(struct beamTree_s *beamTree)
const idMaterial * material
void FreePortal(uPortal_t *p)
interAreaPortal_t interAreaPortals[MAX_INTER_AREA_PORTALS]
int CountTriList(const mapTri_t *list)
bool FloodEntities(tree_t *tree)
void WriteGLView(tree_t *tree, char *source)
struct optimizeGroup_s * nextGroup
const idMaterial * material
void LeakFile(tree_t *tree)
void WriteOutputFile(void)
void ClipSidesByTree(uEntity_t *e)
void OutputWinding(idWinding *w, idFile *glview)
void FilterBrushesIntoTree(uEntity_t *e)
struct bspbrush_s * brush
struct parseMesh_s * next
struct optEdge_s optEdge_t
struct drawSurfRef_s * nextRef
void OptimizeEntity(uEntity_t *e)
void FillOutside(uEntity_t *e)
void DrawBrushList(uBrush_t *brush)
void DrawTri(const mapTri_t *tri)
dmapGlobals_t dmapGlobals
struct optEdge_s * v2link