forked from rtpHarry/Sokoban
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTextureCache.h
41 lines (31 loc) · 802 Bytes
/
TextureCache.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#pragma once
#include <Windows.h>
#include "GLee.h"
//#include <gl\gl.h>
#include <string>
#include <vector>
using namespace std;
#include "Singleton.h"
// clean name for a reference to a sound
typedef GLuint TextureID;
// simple structure to hold together information about a texture
struct TextureCacheObject
{
TextureID OpenGLTextureID;
string FileName;
unsigned int References;
};
class TextureCache : public Singleton<TextureCache>
{
public:
TextureCache(void);
~TextureCache(void);
// Load a new texture into the system
TextureID LoadTexture(string FileName);
// Unload a texture from the system
unsigned int FreeTexture(TextureID TexID);
private:
vector<TextureCacheObject> m_TextureCache;
// Load a sample from a file
// TextureID _LoadSampleFromFile(string FileName);
};