42 lines
768 B
C
42 lines
768 B
C
|
#ifndef __TEXTURES
|
||
|
#define __TEXTURES
|
||
|
|
||
|
#include "fileio.h"
|
||
|
#include <OpenGL/gl.h>
|
||
|
|
||
|
typedef struct{
|
||
|
tFileRef texture;
|
||
|
int priority;
|
||
|
} tTexturePriority;
|
||
|
|
||
|
typedef struct{
|
||
|
int numPriorities;
|
||
|
tTexturePriority *priorities;
|
||
|
} tTexturePriorityList;
|
||
|
|
||
|
typedef struct{
|
||
|
GLint compressionSize;
|
||
|
GLenum target;
|
||
|
GLint level;
|
||
|
GLint internalformat;
|
||
|
GLsizei width;
|
||
|
GLsizei height;
|
||
|
GLint border;
|
||
|
GLenum format;
|
||
|
GLenum type;
|
||
|
GLbyte data[1];
|
||
|
} tCachedTexture;
|
||
|
|
||
|
typedef struct{
|
||
|
int numEntries;
|
||
|
int offsets[1];
|
||
|
} tTextureCacheFile;
|
||
|
|
||
|
extern int gEnableTextureLoad,gNumTexturesRequested,gNumTexturesLoaded,gTexturesQualityModifier;
|
||
|
|
||
|
void TexturesSelectTex(tFileRef tex);
|
||
|
void TexturesAlphaFadeMipMaps();
|
||
|
void TexturesUnloadAll();
|
||
|
int TexturesSelectTextureUnit(int unit);
|
||
|
|
||
|
#endif
|