]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - model_brush.h
rewrote how texture chains are handled, they are now stored outside the surfaces...
[xonotic/darkplaces.git] / model_brush.h
index a034185d53e17b7e0f56cf9279bb0e4fc7ec4304..557c2ce5b67482c17453729865d7ff1baf8b65f6 100644 (file)
@@ -82,7 +82,7 @@ struct msurface_s;
 // change this stuff when real shaders are added
 typedef struct Cshader_s
 {
-       void (*shaderfunc[SHADERSTAGE_COUNT])(const struct entity_render_s *ent, const struct texture_s *texture, const struct msurface_s *firstsurf);
+       void (*shaderfunc[SHADERSTAGE_COUNT])(const struct entity_render_s *ent, const struct texture_s *texture, struct msurface_s **surfchain);
        int flags;
 }
 Cshader_t;
@@ -100,6 +100,9 @@ typedef struct texture_s
        // SURF_ flags
        unsigned int flags;
 
+       // position in the model's textures array
+       int number;
+
        // type of rendering (SURFRENDER_ value)
        int rendertype;
 
@@ -380,6 +383,7 @@ void Mod_FindNonSolidLocation(vec3_t pos, struct model_s *mod);
 mleaf_t *Mod_PointInLeaf (const float *p, struct model_s *model);
 int Mod_PointContents (const float *p, struct model_s *model);
 qbyte *Mod_LeafPVS (mleaf_t *leaf, struct model_s *model);
+void Mod_BuildPVSTextureChains(struct model_s *model);
 
 #endif