#define MATERIALFLAG_NODRAW 512
// probably used only on q1bsp water
#define MATERIALFLAG_LIGHTBOTHSIDES 1024
+// use alpha test on this material
+#define MATERIALFLAG_ALPHATEST 2048
+// treat this material as a blended transparency (as opposed to an alpha test
+// transparency), this causes special fog behavior, and disables glDepthMask
+#define MATERIALFLAG_BLENDED 4096
+// render using a custom blendfunc
+#define MATERIALFLAG_CUSTOMBLEND 8192
typedef struct medge_s
{
int *firstleafsurface;
int numleafbrushes; // q3bsp
int *firstleafbrush; // q3bsp
- qbyte ambient_sound_level[NUM_AMBIENTS]; // q1bsp
+ unsigned char ambient_sound_level[NUM_AMBIENTS]; // q1bsp
int contents; // q1bsp: // TODO: remove (only used temporarily during loading when making collision hull 0)
int portalmarkid; // q1bsp // used by see-polygon-through-portals visibility checker
}
}
svbspmesh_t;
-typedef struct mlight_s
-{
- // location of light
- vec3_t origin;
- // distance attenuation scale (smaller is a larger light)
- float falloff;
- // color and brightness combined
- vec3_t light;
- // brightness bias, used for limiting radius without a hard edge
- float subtract;
- // spotlight direction
- vec3_t spotdir;
- // cosine of spotlight cone angle (or 0 if not a spotlight)
- float spotcone;
- // distance bias (larger value is softer and darker)
- float distbias;
- // light style controlling this light
- int style;
- // maximum extent of the light for shading purposes
- float lightradius;
- // maximum extent of the light for culling purposes
- float cullradius;
- float cullradius2;
- /*
- // surfaces this shines on
- int numsurfaces;
- msurface_t **surfaces;
- // lit area
- vec3_t mins, maxs;
- // precomputed shadow volume meshs
- //svbspmesh_t *shadowvolume;
- //vec3_t shadowvolumemins, shadowvolumemaxs;
- shadowmesh_t *shadowvolume;
- */
-}
-mlight_t;
-
// Q2 bsp stuff
#define Q2BSPVERSION 38
{
int ident;
int version;
- lump_t lumps[HEADER_LUMPS];
+ lump_t lumps[Q2HEADER_LUMPS];
} q2dheader_t;
typedef struct q2dmodel_s
{
int ident;
int version;
- lump_t lumps[HEADER_LUMPS];
+ lump_t lumps[Q3HEADER_LUMPS];
} q3dheader_t;
typedef struct q3dtexture_s
#define Q3SURFACEPARM_TRANS 16777216
#define Q3SURFACEPARM_WATER 33554432
#define Q3SURFACEPARM_POINTLIGHT 67108864
+#define Q3SURFACEPARM_HINT 134217728
+#define Q3SURFACEPARM_DUST 268435456
+#define Q3SURFACEPARM_BOTCLIP 536870912
+#define Q3SURFACEPARM_LIGHTGRID 1073741824
-// various flags from shaders
+// various flags from shaders, used for special effects not otherwise classified
#define Q3TEXTUREFLAG_TWOSIDED 1
-#define Q3TEXTUREFLAG_ADDITIVE 2
-#define Q3TEXTUREFLAG_NOMIPMAPS 4
-#define Q3TEXTUREFLAG_NOPICMIP 8
-#define Q3TEXTUREFLAG_AUTOSPRITE 16
-#define Q3TEXTUREFLAG_AUTOSPRITE2 32
-#define Q3TEXTUREFLAG_ALPHATEST 64
+#define Q3TEXTUREFLAG_AUTOSPRITE 2
+#define Q3TEXTUREFLAG_AUTOSPRITE2 4
+#define Q3TEXTUREFLAG_NOPICMIP 16
typedef struct q3mbrush_s
{