]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - model_shared.h
temporarily disabled compiled rtlights (they'll make a comeback after dynamic rtlight...
[xonotic/darkplaces.git] / model_shared.h
index 86339635a98bb74e9fa1a843f867ff7c82518257..b16ee206e7f45404918e7ad79fe9220fb1d3cf61 100644 (file)
@@ -47,15 +47,16 @@ animscene_t;
 
 typedef struct skinframe_s
 {
+       rtexture_t *stain; // inverse modulate with background (used for decals and such)
+       rtexture_t *merged; // original texture without glow
        rtexture_t *base; // original texture without pants/shirt/glow
        rtexture_t *pants; // pants only (in greyscale)
        rtexture_t *shirt; // shirt only (in greyscale)
-       rtexture_t *glow; // glow only (fullbrights)
-       rtexture_t *merged; // original texture without glow
-       rtexture_t *fog; // alpha of the base texture (if not opaque)
        rtexture_t *nmap; // normalmap (bumpmap for dot3)
        rtexture_t *gloss; // glossmap (for dot3)
        rtexture_t *detail; // detail texture (silly bumps for non-dot3)
+       rtexture_t *glow; // glow only (fullbrights)
+       rtexture_t *fog; // alpha of the base texture (if not opaque)
 }
 skinframe_t;
 
@@ -174,6 +175,9 @@ typedef struct model_brush_s
        //pvschain = model->brush.data_pvsclusters + mycluster * model->brush.num_pvsclusterbytes;
        //if (pvschain[thatcluster >> 3] & (1 << (thatcluster & 7)))
 
+       // a mesh containing all shadow casting geometry for the whole model (including submodels), portions of this are referenced by each surface's num_firstshadowmeshtriangle 
+       shadowmesh_t *shadowmesh;
+
        // common functions
        int (*SuperContentsFromNativeContents)(struct model_s *model, int nativecontents);
        int (*NativeContentsFromSuperContents)(struct model_s *model, int supercontents);
@@ -444,6 +448,9 @@ typedef struct q3mface_s
        int *data_element3i;
        int *data_neighbor3i;
 
+       // index into model->brush.shadowmesh
+       int num_firstshadowmeshtriangle;
+
        // temporary use by light processing
        int lighttemp_castshadow;
 }