]> git.tdb.fi Git - libs/gl.git/blob - source/texunit.h
Add vertex arrays and buffers
[libs/gl.git] / source / texunit.h
1 #ifndef MSP_GL_TEXUNIT_H_
2 #define MSP_GL_TEXUNIT_H_
3
4 #include <vector>
5
6 namespace Msp {
7 namespace GL {
8
9 class Texture;
10
11 class TexUnit
12 {
13 public:
14         TexUnit();
15         bool set_texture(const Texture *);
16         const Texture *get_texture() { return texture; }
17         //TexEnv &get_env() { return env; }
18
19         static TexUnit &activate(unsigned);
20         static TexUnit &current();
21 private:
22         const Texture *texture;
23         //TexEnv env;
24
25         static std::vector<TexUnit> units;
26         static TexUnit *cur_unit;
27 };
28
29 } // namespace GL
30 } // namespace Msp
31
32 #endif