Factory for GL ES 2 Frame Buffer Objects, and related things. More...
#include <OgreGLES2FBORenderTexture.h>
Classes | |
struct | FormatProperties |
Frame Buffer Object properties for a certain texture format. More... | |
struct | RBFormat |
Stencil and depth renderbuffers of the same format are re-used between surfaces of the same size and format. More... | |
struct | RBRef |
Public Member Functions | |
GLES2FBOManager () | |
~GLES2FBOManager () | |
void | _reload () |
Detects all supported fbo's and recreates the tempory fbo. More... | |
void | bind (RenderTarget *target) |
Bind a certain render target if it is a FBO. More... | |
bool | checkFormat (PixelFormat format) |
Check if a certain format is usable as FBO rendertarget format. More... | |
virtual MultiRenderTarget * | createMultiRenderTarget (const String &name) |
Create a multi render target. More... | |
virtual GLES2FBORenderTexture * | createRenderTexture (const String &name, const GLES2SurfaceDesc &target, bool writeGamma, uint fsaa) |
Create a texture rendertarget object. More... | |
void | getBestDepthStencil (GLenum internalFormat, GLenum *depthFormat, GLenum *stencilFormat) |
Get best depth and stencil supported for given internalFormat. More... | |
virtual PixelFormat | getSupportedAlternative (PixelFormat format) |
Get the closest supported alternative format. More... | |
GLuint | getTemporaryFBO () |
Get a FBO without depth/stencil for temporary use, like blitting between textures. More... | |
void | releaseRenderBuffer (const GLES2SurfaceDesc &surface) |
Release a render buffer. More... | |
GLES2SurfaceDesc | requestRenderBuffer (GLenum format, uint32 width, uint32 height, uint fsaa) |
Request a render buffer. More... | |
void | requestRenderBuffer (const GLES2SurfaceDesc &surface) |
Request the specify render buffer in case shared somewhere. More... | |
void | unbind (RenderTarget *target) |
Unbind a certain render target. More... | |
Static Public Member Functions | |
static GLES2RTTManager & | getSingleton (void) |
static GLES2RTTManager * | getSingletonPtr (void) |
Static Protected Attributes | |
static GLES2RTTManager * | msSingleton |
Private Types | |
typedef map< RBFormat, RBRef > ::type | RenderBufferMap |
Private Member Functions | |
void | _createTempFramebuffer (PixelFormat pixFmt, GLuint internalFormat, GLuint fmt, GLenum dataType, GLuint &fb, GLuint &tid) |
GLuint | _tryFormat (GLenum depthFormat, GLenum stencilFormat) |
bool | _tryPackedFormat (GLenum packedFormat) |
void | detectFBOFormats () |
Detect allowed FBO formats. More... | |
Private Attributes | |
FormatProperties | mProps [PF_COUNT] |
Properties for all internal formats defined by OGRE. More... | |
RenderBufferMap | mRenderBufferMap |
GLuint | mTempFBO |
Temporary FBO identifier. More... | |
Factory for GL ES 2 Frame Buffer Objects, and related things.
Definition at line 70 of file OgreGLES2FBORenderTexture.h.
|
private |
Definition at line 190 of file OgreGLES2FBORenderTexture.h.
Ogre::GLES2FBOManager::GLES2FBOManager | ( | ) |
Ogre::GLES2FBOManager::~GLES2FBOManager | ( | ) |
|
private |
void Ogre::GLES2FBOManager::_reload | ( | ) |
Detects all supported fbo's and recreates the tempory fbo.
|
private |
|
private |
|
virtual |
Bind a certain render target if it is a FBO.
If it is not a FBO, bind the main frame buffer.
Implements Ogre::GLES2RTTManager.
|
inlinevirtual |
Check if a certain format is usable as FBO rendertarget format.
Implements Ogre::GLES2RTTManager.
Definition at line 111 of file OgreGLES2FBORenderTexture.h.
|
virtual |
Create a multi render target.
Reimplemented from Ogre::GLES2RTTManager.
|
virtual |
Create a texture rendertarget object.
Implements Ogre::GLES2RTTManager.
|
private |
Detect allowed FBO formats.
|
virtual |
Get best depth and stencil supported for given internalFormat.
Reimplemented from Ogre::GLES2RTTManager.
|
inlinestaticinherited |
Definition at line 90 of file OgreSingleton.h.
|
inlinestaticinherited |
Definition at line 92 of file OgreSingleton.h.
|
virtualinherited |
Get the closest supported alternative format.
If format is supported, returns format.
|
inline |
Get a FBO without depth/stencil for temporary use, like blitting between textures.
Definition at line 115 of file OgreGLES2FBORenderTexture.h.
void Ogre::GLES2FBOManager::releaseRenderBuffer | ( | const GLES2SurfaceDesc & | surface | ) |
Release a render buffer.
Ignore silently if surface.buffer is 0.
GLES2SurfaceDesc Ogre::GLES2FBOManager::requestRenderBuffer | ( | GLenum | format, |
uint32 | width, | ||
uint32 | height, | ||
uint | fsaa | ||
) |
Request a render buffer.
If format is GL_NONE, return a zero buffer.
void Ogre::GLES2FBOManager::requestRenderBuffer | ( | const GLES2SurfaceDesc & | surface | ) |
Request the specify render buffer in case shared somewhere.
Ignore silently if surface.buffer is 0.
|
inlinevirtual |
Unbind a certain render target.
No-op for FBOs.
Implements Ogre::GLES2RTTManager.
Definition at line 83 of file OgreGLES2FBORenderTexture.h.
|
private |
Properties for all internal formats defined by OGRE.
Definition at line 139 of file OgreGLES2FBORenderTexture.h.
|
private |
Definition at line 191 of file OgreGLES2FBORenderTexture.h.
|
staticprotectedinherited |
Definition at line 75 of file OgreSingleton.h.
|
private |
Temporary FBO identifier.
Definition at line 196 of file OgreGLES2FBORenderTexture.h.