+typedef struct texture_s
+{
+ // name
+ char name[16];
+ // size
+ unsigned int width, height;
+ // SURF_ flags
+ unsigned int flags;
+
+ // position in the model's textures array
+ int number;
+
+ // type of rendering (SURFRENDER_ value)
+ int rendertype;
+
+ // base texture without fullbrights, never NULL
+ rtexture_t *texture;
+ // fullbrights texture, NULL if no fullbrights used
+ rtexture_t *glowtexture;
+ // alpha texture (used for fogging), NULL if opaque
+ rtexture_t *fogtexture;
+ // detail texture (usually not used if transparent)
+ rtexture_t *detailtexture;
+ // normalmap for bumpmap shading
+ rtexture_t *nmaptexture;
+ // color filtering for glossy surfaces
+ rtexture_t *glosstexture;
+
+ // shader to use for this texture
+ Cshader_t *shader;
+
+ // total frames in sequence and alternate sequence
+ int anim_total[2];
+ // direct pointers to each of the frames in the sequences
+ // (indexed as [alternate][frame])
+ struct texture_s *anim_frames[2][10];
+ // set if animated or there is an alternate frame set
+ // (this is an optimization in the renderer)
+ int animated;
+ // the current texture frame in animation
+ struct texture_s *currentframe;
+ // current alpha of the texture
+ float currentalpha;