Fix POLYMER=0 build, cleaning up #include discipline on the way.

Also taking care that the USE_OPENGL=0 build builds.

git-svn-id: https://svn.eduke32.com/eduke32@3467 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
helixhorned 2013-02-07 21:01:24 +00:00
parent 5e4edcaaa8
commit 1dd52a4d6e
4 changed files with 8 additions and 2 deletions

View file

@ -11,6 +11,7 @@
#include "compat.h"
#include "pragmas.h"
#include "glbuild.h"
#ifdef EXTERNC
extern "C" {
@ -1076,7 +1077,6 @@ void hash_delete(hashtable_t *t, const char *s);
extern void initialize_engine_globals(void);
// XXX: These assume that glbuild.h is already #include'd
static inline void push_nofog(void)
{
#ifdef USE_OPENGL

View file

@ -1,6 +1,7 @@
#ifndef _mdsprite_h_
# define _mdsprite_h_
#ifdef USE_OPENGL
#include "hightile.h"
#define SHIFTMOD32(a) ((a)&31)
@ -226,4 +227,5 @@ int32_t voxdraw(voxmodel_t *m, const spritetype *tspr);
int md3postload_polymer(md3model_t* m);
//int32_t md_thinoutmodel(int32_t modelid, uint8_t *usedframebitmap);
#endif // defined USE_OPENGL
#endif // !_mdsprite_h_

View file

@ -14,6 +14,7 @@
#include "kplib.h"
#include "quicklz.h"
#include "common.h"
#include "mdsprite.h" // md3model_t
enum scripttoken_t
{
@ -699,8 +700,10 @@ static int32_t defsparser(scriptfile *script)
break;
}
md_setmisc(lastmodelid,(float)scale, shadeoffs,0.0,0.0,0);
# ifdef POLYMER
if (glrendmode==4)
md3postload_polymer((md3model_t *)models[lastmodelid]);
# endif
#endif
modelskin = lastmodelskin = 0;
seenframe = 0;

View file

@ -513,8 +513,9 @@ void G_CacheMapData(void)
// this is the CROSSHAIR_COLOR, see comment in game.c
if (k == MAXPALOOKUPS-RESERVEDPALS-1)
break;
#ifdef POLYMER
if (rendmode!=4 || !polymer_havehighpalookup(0, k))
#endif
polymost_precache(i,k,type);
}