20 FBO(
bool useTextureColor,
bool useTextureDepth,
bool multiSample,
unsigned int width,
unsigned int height,
bool addSecondColorBuffer =
false);
31 FBO(
unsigned int nrColorTexture,
bool useDepthTexture,
bool useMultisampling,
unsigned int width,
unsigned int height);
41 static void copyFBO(
const FBO& from,
const FBO& to,
unsigned int bufferMask = GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
45 static void copyFBO(
const FBO& from,
unsigned int to,
unsigned int bufferMask = GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
49 static void copyFBO(
unsigned int from,
const FBO& to,
unsigned int bufferMask = GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
58 const unsigned int getColorTexture(
unsigned int i)
const {
return colorTextures.at(i); }
99 unsigned int colorTexture;
100 unsigned int colorTexture2;
101 unsigned int depthTexture;
105 bool useTextureDepth;
106 bool useTextureColor;
107 std::vector<unsigned int> colorTextures;
108 std::vector<unsigned int> multiSampleTextures;
109 bool hasSecondaryColorBuffer;
112 void createFrameBuffers(
unsigned int nrColorTexture,
bool useDepthTexture,
bool useMultisampling,
unsigned int width,
unsigned int height);
void setActive()
Definition: FBO.cpp:26
const bool isMultiSample() const
Definition: FBO.h:82
const unsigned int getColorTexture(unsigned int i) const
Definition: FBO.h:58
const unsigned int getSecondaryColorTexture() const
Definition: FBO.h:70
static void copyFBO(const FBO &from, const FBO &to, unsigned int bufferMask=GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT)
Definition: FBO.cpp:114
static unsigned int MULTI_SAMPLE_COUNT
Definition: FBO.h:94
Class for handling render to texture using framebuffer objects.
Definition: FBO.h:8
FBO(bool useTextureColor, bool useTextureDepth, bool multiSample, unsigned int width, unsigned int height, bool addSecondColorBuffer=false)
Definition: FBO.cpp:6
const unsigned int getDepthTexture() const
Definition: FBO.h:77
const unsigned int getColorTexture() const
Definition: FBO.h:64