![]() |
DarkPlaces
Game engine based on the Quake 1 engine by id Software, developed by LadyHavoc
|
|
Go to the source code of this file.
Data Structures | |
struct | svbsp_polygon_t |
Macros | |
#define | MAX_SVBSP_POLYGONPOINTS 64 |
#define | SVBSP_CLIP_EPSILON (1.0f / 1024.0f) |
#define | SVBSP_DotProduct(a, b) |
Functions | |
int | SVBSP_AddPolygon (svbsp_t *b, int numpoints, const float *points, int insertoccluder, void(*fragmentcallback)(void *fragmentcallback_pointer1, int fragmentcallback_number1, svbsp_t *b, int numpoints, const float *points), void *fragmentcallback_pointer1, int fragmentcallback_number1) |
static int | SVBSP_AddPolygonNode (svbsp_t *b, int *parentnodenumpointer, int parentnodenum, const svbsp_polygon_t *poly, int insertoccluder, void(*fragmentcallback)(void *fragmentcallback_pointer1, int fragmentcallback_number1, svbsp_t *b, int numpoints, const float *points), void *fragmentcallback_pointer1, int fragmentcallback_number1) |
static void | SVBSP_DividePolygon (const svbsp_polygon_t *poly, const float *plane, svbsp_polygon_t *front, svbsp_polygon_t *back, const float *dists, const int *sides) |
void | SVBSP_Init (svbsp_t *b, const float *origin, int maxnodes, svbsp_node_t *nodes) |
static void | SVBSP_InsertOccluderPolygonNodes (svbsp_t *b, int *parentnodenumpointer, int parentnodenum, const svbsp_polygon_t *poly, void(*fragmentcallback)(void *fragmentcallback_pointer1, int fragmentcallback_number1, svbsp_t *b, int numpoints, const float *points), void *fragmentcallback_pointer1, int fragmentcallback_number1) |
static void | SVBSP_PlaneFromPoints (float *plane4f, const float *p1, const float *p2, const float *p3) |
#define MAX_SVBSP_POLYGONPOINTS 64 |
Definition at line 11 of file svbsp.c.
Referenced by SVBSP_AddPolygon(), SVBSP_AddPolygonNode(), and SVBSP_DividePolygon().
#define SVBSP_CLIP_EPSILON (1.0f / 1024.0f) |
Definition at line 12 of file svbsp.c.
Referenced by SVBSP_AddPolygonNode(), and SVBSP_InsertOccluderPolygonNodes().
Definition at line 14 of file svbsp.c.
Referenced by SVBSP_AddPolygonNode(), SVBSP_InsertOccluderPolygonNodes(), and SVBSP_PlaneFromPoints().
int SVBSP_AddPolygon | ( | svbsp_t * | b, |
int | numpoints, | ||
const float * | points, | ||
int | insertoccluder, | ||
void(* | fragmentcallback )(void *fragmentcallback_pointer1, int fragmentcallback_number1, svbsp_t *b, int numpoints, const float *points), | ||
void * | fragmentcallback_pointer1, | ||
int | fragmentcallback_number1 ) |
Definition at line 403 of file svbsp.c.
References b, DRAWFLAG_ADDITIVE, svbsp_polygon_t::facesplitflag, i, MAX_SVBSP_POLYGONPOINTS, NULL, svbsp_polygon_t::numpoints, svbsp_polygon_t::points, and SVBSP_AddPolygonNode().
Referenced by Mod_GenerateLightmaps_CreateLights_ComputeSVBSP_InsertSurfaces(), R_Q1BSP_RecursiveGetLightInfo_BIH(), and R_Q1BSP_RecursiveGetLightInfo_BSP().
|
static |
Definition at line 273 of file svbsp.c.
References b, svbsp_node_t::children, DRAWFLAG_ADDITIVE, svbsp_polygon_t::facesplitflag, i, MAX_SVBSP_POLYGONPOINTS, NULL, svbsp_polygon_t::numpoints, svbsp_node_t::plane, svbsp_polygon_t::points, PolygonF_Divide(), SVBSP_AddPolygonNode(), SVBSP_CLIP_EPSILON, SVBSP_DividePolygon(), SVBSP_DotProduct, and SVBSP_InsertOccluderPolygonNodes().
Referenced by SVBSP_AddPolygon(), and SVBSP_AddPolygonNode().
|
static |
Definition at line 43 of file svbsp.c.
References count, i, MAX_SVBSP_POLYGONPOINTS, svbsp_polygon_t::numpoints, and svbsp_polygon_t::points.
Referenced by SVBSP_AddPolygonNode().
void SVBSP_Init | ( | svbsp_t * | b, |
const float * | origin, | ||
int | maxnodes, | ||
svbsp_node_t * | nodes ) |
Definition at line 99 of file svbsp.c.
References b, origin, and svbsp_node_t::plane.
Referenced by Mod_GenerateLightmaps_CreateLights_ComputeSVBSP(), and R_Q1BSP_CallRecursiveGetLightInfo().
|
static |
Definition at line 157 of file svbsp.c.
References b, svbsp_node_t::children, fabs(), svbsp_polygon_t::facesplitflag, i, int(), svbsp_polygon_t::numpoints, svbsp_node_t::parent, svbsp_node_t::plane, svbsp_polygon_t::points, SVBSP_CLIP_EPSILON, SVBSP_DotProduct, and SVBSP_PlaneFromPoints().
Referenced by SVBSP_AddPolygonNode().
|
static |
Definition at line 25 of file svbsp.c.
References float, sqrt(), and SVBSP_DotProduct.
Referenced by SVBSP_InsertOccluderPolygonNodes().