From 7c4a0725e1c8b6a4ad1fc781ade35ac918ce6428 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Mon, 8 Oct 2007 09:50:02 +0000 Subject: [PATCH] clean out unused functions --- tools/qfbsp/include/bsp5.h | 4 +--- tools/qfbsp/include/map.h | 1 - tools/qfbsp/include/options.h | 1 - tools/qfbsp/source/map.c | 9 --------- tools/qfbsp/source/options.c | 2 +- tools/qfbsp/source/qfbsp.c | 5 ----- tools/qfbsp/source/surfaces.c | 26 -------------------------- 7 files changed, 2 insertions(+), 46 deletions(-) diff --git a/tools/qfbsp/include/bsp5.h b/tools/qfbsp/include/bsp5.h index 5a2aae229..58e65a74a 100644 --- a/tools/qfbsp/include/bsp5.h +++ b/tools/qfbsp/include/bsp5.h @@ -53,7 +53,6 @@ typedef struct { } winding_t; winding_t *BaseWindingForPlane (plane_t *p); -void CheckWinding (winding_t *w); winding_t *NewWinding (int points); void FreeWinding (winding_t *w); winding_t *CopyWinding (winding_t *w); @@ -157,7 +156,6 @@ void SplitFace (face_t *in, plane_t *split, face_t **front, face_t **back); void DivideFacet (face_t *in, plane_t *split, face_t **front, face_t **back); void CalcSurfaceInfo (surface_t *surf); -void SubdivideFace (face_t *f, face_t **prevptr); node_t *SolidBSP (surface_t *surfhead, qboolean midsplit); // merge.c ==================================================================== @@ -176,7 +174,7 @@ extern face_t *edgefaces[MAX_MAP_EDGES][2]; extern int firstmodeledge; extern int firstmodelface; -void SubdivideFaces (surface_t *surfhead); +void SubdivideFace (face_t *f, face_t **prevptr); surface_t *GatherNodeFaces (node_t *headnode); diff --git a/tools/qfbsp/include/map.h b/tools/qfbsp/include/map.h index 99f60bd50..746121717 100644 --- a/tools/qfbsp/include/map.h +++ b/tools/qfbsp/include/map.h @@ -65,7 +65,6 @@ int FindMiptex (const char *name); void PrintEntity (entity_t *ent); const char *ValueForKey (entity_t *ent, const char *key); void SetKeyValue (entity_t *ent, const char *key, const char *value); -float FloatForKey (entity_t *ent, const char *key); void GetVectorForKey (entity_t *ent, const char *key, vec3_t vec); void WriteEntitiesToString (void); diff --git a/tools/qfbsp/include/options.h b/tools/qfbsp/include/options.h index a3318804b..62c885283 100644 --- a/tools/qfbsp/include/options.h +++ b/tools/qfbsp/include/options.h @@ -57,6 +57,5 @@ typedef struct { extern options_t options; int DecodeArgs (int argc, char **argv); -void usage (int status); extern const char *this_program; #endif//__options_h diff --git a/tools/qfbsp/source/map.c b/tools/qfbsp/source/map.c index 62d0bffce..4aefa434c 100644 --- a/tools/qfbsp/source/map.c +++ b/tools/qfbsp/source/map.c @@ -540,15 +540,6 @@ SetKeyValue (entity_t *ent, const char *key, const char *value) ep->value = strdup (value); } -float -FloatForKey (entity_t *ent, const char *key) -{ - const char *k; - - k = ValueForKey (ent, key); - return atof (k); -} - void GetVectorForKey (entity_t *ent, const char *key, vec3_t vec) { diff --git a/tools/qfbsp/source/options.c b/tools/qfbsp/source/options.c index a4094f41d..4a4bce561 100644 --- a/tools/qfbsp/source/options.c +++ b/tools/qfbsp/source/options.c @@ -88,7 +88,7 @@ static const char *short_options = ; -void +static void usage (int status) { printf ("%s - QuakeForge PVS/PHS generation tool\n", this_program); diff --git a/tools/qfbsp/source/qfbsp.c b/tools/qfbsp/source/qfbsp.c index c306ebb44..5af8f21db 100644 --- a/tools/qfbsp/source/qfbsp.c +++ b/tools/qfbsp/source/qfbsp.c @@ -161,11 +161,6 @@ CopyWindingReverse (winding_t *w) return c; } -void -CheckWinding (winding_t * w) -{ -} - /* ClipWinding diff --git a/tools/qfbsp/source/surfaces.c b/tools/qfbsp/source/surfaces.c index 940bc26df..1ceef3f4d 100644 --- a/tools/qfbsp/source/surfaces.c +++ b/tools/qfbsp/source/surfaces.c @@ -105,32 +105,6 @@ SubdivideFace (face_t *f, face_t **prevptr) } } -void -SubdivideFaces (surface_t *surfhead) -{ - face_t *f, **prevptr; - surface_t *surf; - - qprintf ("--- SubdivideFaces ---\n"); - - subdivides = 0; - - for (surf = surfhead; surf; surf = surf->next) { - prevptr = &surf->faces; - while (1) { - f = *prevptr; - if (!f) - break; - SubdivideFace (f, prevptr); - f = *prevptr; - prevptr = &f->next; - } - } - - qprintf ("%i faces added by subdivision\n", subdivides); - -} - /* GatherNodeFaces