]> git.tdb.fi Git - libs/gl.git/blobdiff - source/framebuffer.h
Add support for cube map textures
[libs/gl.git] / source / framebuffer.h
index 3d3ec088138f9d4b50d675ead1d0b73807277212..e33deda9218d9bf3afea690b44fc1e9dd6329bc1 100644 (file)
@@ -4,6 +4,7 @@
 #include <vector>
 #include "bindable.h"
 #include "gl.h"
+#include "texturecube.h"
 
 namespace Msp {
 namespace GL {
@@ -80,10 +81,11 @@ private:
                        Texture *tex;
                };
                unsigned level;
+               GLenum cube_face;
 
                Attachment(FramebufferAttachment);
                void set(Renderbuffer &);
-               void set(Texture &, unsigned);
+               void set(Texture &, GLenum, unsigned);
                void clear();
        };
 
@@ -107,6 +109,7 @@ private:
 public:
        void attach(FramebufferAttachment attch, Renderbuffer &rbuf);
        void attach(FramebufferAttachment attch, Texture2D &tex, unsigned level = 0);
+       void attach(FramebufferAttachment attch, TextureCube &tex, TextureCubeFace face, unsigned level = 0);
        void detach(FramebufferAttachment attch);
 
        /**