This class implements an OpenGL framebuffer.
More...
#include <CFrameBuffer.h>
This class implements an OpenGL framebuffer.
| chai3d::cFrameBuffer::cFrameBuffer |
( |
| ) |
|
| chai3d::cFrameBuffer::~cFrameBuffer |
( |
| ) |
|
|
virtual |
| void chai3d::cFrameBuffer::setup |
( |
cCamera * |
a_camera = NULL, |
|
|
const unsigned int |
a_width = 0, |
|
|
const unsigned int |
a_height = 0, |
|
|
const bool |
a_useImageBuffer = true, |
|
|
const bool |
a_useDepthBuffer = true |
|
) |
| |
This method initializes the cFrameBuffer.
- Parameters
-
| a_camera | Camera to be attached to framebuffer. |
| a_width | Width in pixels of framebuffer. |
| a_height | Height in pixels of framebuffer. |
| a_useImageBuffer | If true then framebuffer shall store color information. |
| a_useDepthBuffer | If true then framebuffer shall store depth information. |
This method render the scene to the framebuffer.
- Parameters
-
| a_eyeMode | When using stereo mode C_STEREO_PASSIVE_DUAL_DISPLAY, this argument specifies which eye view to render. |
| void chai3d::cFrameBuffer::copyImageBuffer |
( |
cImagePtr |
a_image | ) |
|
This method copies the OpenGL image buffer content to an image.
- Parameters
-
| a_image | Destination image. |
| void chai3d::cFrameBuffer::copyDepthBuffer |
( |
cImagePtr |
a_image | ) |
|
This method copies the OpenGL depth buffer content to an image.
- Parameters
-
| a_image | Destination image. |
| void chai3d::cFrameBuffer::setCamera |
( |
cCamera * |
a_camera | ) |
|
|
inline |
| cCamera* chai3d::cFrameBuffer::getCamera |
( |
| ) |
|
|
inline |
| unsigned int chai3d::cFrameBuffer::getWidth |
( |
| ) |
const |
|
inline |
| unsigned int chai3d::cFrameBuffer::getHeight |
( |
| ) |
const |
|
inline |
| void chai3d::cFrameBuffer::setSize |
( |
const unsigned int |
a_width, |
|
|
const unsigned int |
a_height |
|
) |
| |
This method sets the size of the framebuffer by defining the width and height in pixel.
- Parameters
-
| a_width | Width of frame buffer in pixels. |
| a_height | Height of frame buffer in pixels. |
| bool chai3d::cFrameBuffer::renderInitialize |
( |
| ) |
|
This method initializes the framebuffer so that rendering of the scene can occur. This method is for advanced users only; in practice you should simply call method renderView() to render the framebuffer.
- Returns
- true if the operation succeeds, false otherwise.
| bool chai3d::cFrameBuffer::renderFinalize |
( |
| ) |
|
This method finalizes the rendering of the framebuffer. This method is for advanced users only; in practice you should simply call method renderView() to render the framebuffer.
- Returns
- true if the operation succeeds, false otherwise.
| bool chai3d::cFrameBuffer::m_useImageBuffer |
|
protected |
| bool chai3d::cFrameBuffer::m_useDepthBuffer |
|
protected |
| unsigned int chai3d::cFrameBuffer::m_width |
|
protected |
| unsigned int chai3d::cFrameBuffer::m_height |
|
protected |
| unsigned int chai3d::cFrameBuffer::m_prevWidth |
|
protected |
| unsigned int chai3d::cFrameBuffer::m_prevHeight |
|
protected |
| cCamera* chai3d::cFrameBuffer::m_camera |
|
protected |
| GLuint chai3d::cFrameBuffer::m_fbo |
|
protected |
The documentation for this class was generated from the following files: