#ifndef DEF_FRAMEBUFFER #define DEF_FRAMEBUFFER // Include Windows #ifdef WIN32 #include // Include Mac #elif __APPLE__ #define GL3_PROTOTYPES 1 #include // Include UNIX/Linux #else #define GL3_PROTOTYPES 1 #include #endif // Includes communs #include #include "Texture.h" // Classe class FrameBuffer { public: FrameBuffer(); FrameBuffer(int largeur, int hauteur, bool stencil = false); FrameBuffer(const FrameBuffer &frameBufferACopier); ~FrameBuffer(); bool charger(); void creerRenderBuffer(GLuint &id, GLenum formatInterne); GLuint getID() const; Texture* getColorBuffer(unsigned int index); int getLargeur() const; int getHauteur() const; private: GLuint m_id; int m_largeur; int m_hauteur; std::vector m_colorBuffers; GLuint m_depthBufferID; bool m_stencil; }; #endif