Developer Documentation
RenderManager Class Reference

Public Member Functions

bool rendererExists (QString _name)
 Check if a renderer with the given name exists. More...
 
RendererInfonewRenderer (QString _name)
 Get a new renderer Instance. More...
 
int getRendererId (QString _name)
 get renderer id with the given name More...
 
RendererInfogetRenderer (QString _name)
 get renderer with the given name More...
 
int countRenderers (ACG::SceneGraph::DrawModes::DrawMode _mode)
 count renderers for a DrawMode (excluding the default renderer) More...
 
RendererInfooperator[] (unsigned int _id)
 Get the renderer with the given id. More...
 
size_t available ()
 number of available renderers More...
 
void setActive (unsigned int _active, int _id)
 set the active renderer More...
 
void setActive (QString _active, int _id)
 set the active renderer More...
 
RendererInfoactive (int _id)
 Get the current active renderer. More...
 
unsigned int activeId (int _id)
 Get the id of the active renderer. More...
 

Private Attributes

std::vector< RendererInfoavailableRenderers_
 Vector holding all available renderers.
 
std::vector< unsigned int > activeRenderers_
 The currently active renderer ids.
 

Detailed Description

Definition at line 83 of file RendererInfo.hh.

Member Function Documentation

◆ active()

RendererInfo * RenderManager::active ( int  _id)

Get the current active renderer.

Parameters
_idviewer id
Returns
Renderer

Definition at line 182 of file RendererInfo.cc.

◆ activeId()

unsigned int RenderManager::activeId ( int  _id)

Get the id of the active renderer.

Parameters
_idviewer id
Returns
renderer id

Definition at line 195 of file RendererInfo.cc.

◆ available()

size_t RenderManager::available ( )

number of available renderers

Returns
number of available renderers

Definition at line 140 of file RendererInfo.cc.

◆ countRenderers()

int RenderManager::countRenderers ( ACG::SceneGraph::DrawModes::DrawMode  _mode)

count renderers for a DrawMode (excluding the default renderer)

Checks in the list of renderers how many support the given draw mode combination. The combination is checked as one complete block.

Parameters
_modeThe mode that should be checked.

Definition at line 119 of file RendererInfo.cc.

◆ getRenderer()

RendererInfo * RenderManager::getRenderer ( QString  _name)

get renderer with the given name

Parameters
_nameName of the renderer
Returns
pointer or 0 if it does not exist

Definition at line 101 of file RendererInfo.cc.

◆ getRendererId()

int RenderManager::getRendererId ( QString  _name)

get renderer id with the given name

Parameters
_nameName of the renderer
Returns
Id of the renderer or -1 if it does not exist

Definition at line 110 of file RendererInfo.cc.

◆ newRenderer()

RendererInfo * RenderManager::newRenderer ( QString  _name)

Get a new renderer Instance.

Parameters
_nameName of the new renderer
Returns
Pointer to renderer. If it exists, the existing one is returned!

Definition at line 89 of file RendererInfo.cc.

◆ operator[]()

RendererInfo * RenderManager::operator[] ( unsigned int  _id)

Get the renderer with the given id.

Parameters
_idId of the renderer
Returns

Definition at line 131 of file RendererInfo.cc.

◆ rendererExists()

bool RenderManager::rendererExists ( QString  _name)

Check if a renderer with the given name exists.

Parameters
_nameName of the renderer
Returns
exists or not

Definition at line 79 of file RendererInfo.cc.

◆ setActive() [1/2]

void RenderManager::setActive ( unsigned int  _active,
int  _id 
)

set the active renderer

Parameters
_idviewer id
_activeid of the renderer

Definition at line 145 of file RendererInfo.cc.

◆ setActive() [2/2]

void RenderManager::setActive ( QString  _active,
int  _id 
)

set the active renderer

Parameters
_activename of the renderer
_idviewer id

Definition at line 162 of file RendererInfo.cc.


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