]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - model_brush.h
make view kicks (both angle and origin) occur before gun is oriented, so it follows...
[xonotic/darkplaces.git] / model_brush.h
index 3d031e73934bfe75817f37edd115dacf1a7304e1..fb4c30a65e70bc4c581b312acaae41d48c9c3112 100644 (file)
@@ -57,8 +57,7 @@ mplane_t;
 
 #define SHADERSTAGE_SKY 0
 #define SHADERSTAGE_NORMAL 1
-#define SHADERSTAGE_BASELIGHTING 2
-#define SHADERSTAGE_COUNT 3
+#define SHADERSTAGE_COUNT 2
 
 #define SHADERFLAGS_NEEDLIGHTMAP 1
 
@@ -69,7 +68,6 @@ mplane_t;
 #define SURF_DRAWNOALPHA 0x100
 #define SURF_DRAWFULLBRIGHT 0x200
 #define SURF_LIGHTBOTHSIDES 0x400
-#define SURF_CLIPSOLID 0x800 // this polygon can obscure other polygons
 #define SURF_SHADOWCAST 0x1000 // this polygon can cast stencil shadows
 #define SURF_SHADOWLIGHT 0x2000 // this polygon can be lit by stencil shadowing
 #define SURF_WATERALPHA 0x4000 // this polygon's alpha is modulated by r_wateralpha
@@ -129,9 +127,10 @@ typedef struct texture_s
        // set if animated or there is an alternate frame set
        // (this is an optimization in the renderer)
        int animated;
-       // the current texture frames in animation
-       // (index with entity frame != 0)
-       struct texture_s *currentframe[2];
+       // the current texture frame in animation
+       struct texture_s *currentframe;
+       // current alpha of the texture
+       float currentalpha;
 }
 texture_t;
 
@@ -222,6 +221,8 @@ typedef struct msurface_s
 
        // neighboring surfaces (one per poly_numverts)
        struct msurface_s **neighborsurfaces;
+       // currently used only for generating static shadow volumes
+       int castshadow;
 
        // these are regenerated every frame
        // lighting info
@@ -280,8 +281,12 @@ typedef struct mleaf_s
        vec3_t maxs;
 
 // leaf specific
-       // potentially visible if current (r_pvsframecount)
+       // next leaf in pvschain
+       struct mleaf_s *pvschain;
+       // potentially visible if current (model->pvsframecount)
        int pvsframe;
+       // visible if marked current (r_framecount)
+       int visframe;
        // used by certain worldnode variants to avoid processing the same leaf twice in a frame
        int worldnodeframe;
        // used by polygon-through-portals visibility checker
@@ -352,6 +357,7 @@ typedef struct mlight_s
        // maximum extent of the light for culling purposes
        float cullradius;
        float cullradius2;
+       /*
        // surfaces this shines on
        int numsurfaces;
        msurface_t **surfaces;
@@ -361,6 +367,7 @@ typedef struct mlight_s
        //svbspmesh_t *shadowvolume;
        //vec3_t shadowvolumemins, shadowvolumemaxs;
        shadowmesh_t *shadowvolume;
+       */
 }
 mlight_t;