This class provides support for OpenGL display lists.
More...
#include <CDisplayList.h>
|
| | cDisplayList () |
| | Constructor of cDisplayList. More...
|
| |
| | ~cDisplayList () |
| | Destructor of cDisplayList. More...
|
| |
| void | invalidate () |
| | This method invalidates the current display list. Request for update. More...
|
| |
| bool | render (const int a_displayContext, const bool a_useDisplayList) |
| | This method renders the display list. More...
|
| |
| bool | begin (const int a_displayContext, const bool a_useDisplayList) |
| | This method begins the creation of a display list. More...
|
| |
| void | end (const int a_displayContext, const bool a_executeDisplayList) |
| | This method finalizes the creation of a display list. More...
|
| |
| unsigned int | getDisplayListGL (const int a_displayContext) |
| | This method returns the OpenGL display list number. More...
|
| |
This class provides support for OpenGL display lists.
| chai3d::cDisplayList::cDisplayList |
( |
| ) |
|
Constructor of cDisplayList.
The display list is set to zero as it has not yet been created. We also initialize the flag which tells us if a display list is currently being created.
| chai3d::cDisplayList::~cDisplayList |
( |
| ) |
|
| void chai3d::cDisplayList::invalidate |
( |
| ) |
|
This method invalidates the current display list. We inform the display list that it will need to be updated the next time the object is rendered. We free any graphic card memory which contains the current display list.
| bool chai3d::cDisplayList::render |
( |
const int |
a_displayContext, |
|
|
const bool |
a_useDisplayList |
|
) |
| |
This method renders the display list. We pass a boolean from the object which indicates if the display list should be used. If the display list is valid and is used for rendering the object, the method returns true, otherwise false.
- Parameters
-
| a_displayContext | Display context number. |
| a_useDisplayList | If set to true, then display list is rendered. |
- Returns
- true is display list was rendered successfully, otherwise false if the display list was invalid.
| bool chai3d::cDisplayList::begin |
( |
const int |
a_displayContext, |
|
|
const bool |
a_useDisplayList |
|
) |
| |
This method begins the creation of a display list.
- Parameters
-
| a_displayContext | Display context number. |
| a_useDisplayList | If true, then display list is created. |
- Returns
- true if the OpenGL display list has been successfully allocated.
| void chai3d::cDisplayList::end |
( |
const int |
a_displayContext, |
|
|
const bool |
a_executeDisplayList |
|
) |
| |
This method finalizes and compiles the display list. Optionally render the display list as nothing will have yet been rendered at the screen during display list compilation which began after calling method begin().
- Parameters
-
| a_displayContext | Display context number. |
| a_executeDisplayList | If true, the the display list is rendered immediately after display list has been completed. |
| unsigned int chai3d::cDisplayList::getDisplayListGL |
( |
const int |
a_displayContext | ) |
|
|
inline |
| unsigned int chai3d::cDisplayList::m_displayList[C_MAX_DISPLAY_CONTEXTS] |
|
protected |
| bool chai3d::cDisplayList::m_flagCreatingDisplayList[C_MAX_DISPLAY_CONTEXTS] |
|
protected |
| bool chai3d::cDisplayList::m_flagMarkedForDeletion[C_MAX_DISPLAY_CONTEXTS] |
|
protected |
The documentation for this class was generated from the following files: