Public Member Functions | Private Member Functions | Private Attributes
Ogre::GLFrameBufferObject Class Reference

Frame Buffer Object abstraction. More...

#include <OgreGLFrameBufferObject.h>

List of all members.

Public Member Functions

 GLFrameBufferObject (GLFBOManager *manager, uint fsaa)
 ~GLFrameBufferObject ()
void bindSurface (size_t attachment, const GLSurfaceDesc &target)
 Bind a surface to a certain attachment point.
void unbindSurface (size_t attachment)
 Unbind attachment.
void bind ()
 Bind FrameBufferObject.
void swapBuffers ()
 Swap buffers - only useful when using multisample buffers.
void attachDepthBuffer (DepthBuffer *depthBuffer)
 This function acts very similar to.
void detachDepthBuffer ()
GLuint getGLFBOID () const
 Get the GL id for the FBO.
GLuint getGLMultisampleFBOID () const
 Get the GL id for the multisample FBO.
size_t getWidth ()
 Accessors.
size_t getHeight ()
PixelFormat getFormat ()
GLsizei getFSAA ()
GLFBOManagergetManager ()
const GLSurfaceDescgetSurface (size_t attachment)

Private Member Functions

void initialise ()
 Initialise object (find suitable depth and stencil format).

Private Attributes

GLFBOManagermManager
GLsizei mNumSamples
GLuint mFB
GLuint mMultisampleFB
GLSurfaceDesc mMultisampleColourBuffer
GLSurfaceDesc mDepth
GLSurfaceDesc mStencil
GLSurfaceDesc mColour [OGRE_MAX_MULTIPLE_RENDER_TARGETS]

Detailed Description

Frame Buffer Object abstraction.

Definition at line 38 of file OgreGLFrameBufferObject.h.


Constructor & Destructor Documentation


Member Function Documentation

This function acts very similar to.

See also:
GLFBORenderTexture::attachDepthBuffer The difference between D3D & OGL is that D3D setups the DepthBuffer before rendering, while OGL setups the DepthBuffer per FBO. So the DepthBuffer (RenderBuffer) needs to be attached for OGL.

Bind FrameBufferObject.

void Ogre::GLFrameBufferObject::bindSurface ( size_t  attachment,
const GLSurfaceDesc target 
)

Bind a surface to a certain attachment point.

attachment: 0..OGRE_MAX_MULTIPLE_RENDER_TARGETS-1

Get the GL id for the FBO.

Definition at line 69 of file OgreGLFrameBufferObject.h.

Get the GL id for the multisample FBO.

Definition at line 71 of file OgreGLFrameBufferObject.h.

Definition at line 79 of file OgreGLFrameBufferObject.h.

Definition at line 80 of file OgreGLFrameBufferObject.h.

Accessors.

Initialise object (find suitable depth and stencil format).

Must be called every time the bindings change. It fails with an exception (ERR_INVALIDPARAMS) if:

  • Attachment point 0 has no binding
  • Not all bound surfaces have the same size
  • Not all bound surfaces have the same internal format

Swap buffers - only useful when using multisample buffers.

void Ogre::GLFrameBufferObject::unbindSurface ( size_t  attachment)

Unbind attachment.


Member Data Documentation

Definition at line 90 of file OgreGLFrameBufferObject.h.

Definition at line 87 of file OgreGLFrameBufferObject.h.

Definition at line 84 of file OgreGLFrameBufferObject.h.

Definition at line 82 of file OgreGLFrameBufferObject.h.

Definition at line 86 of file OgreGLFrameBufferObject.h.

Definition at line 85 of file OgreGLFrameBufferObject.h.

Definition at line 83 of file OgreGLFrameBufferObject.h.

Definition at line 88 of file OgreGLFrameBufferObject.h.


The documentation for this class was generated from the following file:

Copyright © 2012 Torus Knot Software Ltd
Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
Last modified Sun Sep 2 2012 07:27:51