Graphics::IRenderManager class

This class manages the rendering process in the game.

It can be used to add IRenderable objects to the render queue. When added, an index in the queue must be specified; this index is important since defines at which moment the object is rendered. The minimum index is defined as Graphics::kRenderQueueMain; lower indices are used to render the user interface and might cause problems.

Derived classes

class cRenderManager

Public types

struct RenderLayer

Public static functions

static auto Get() -> IRenderManager*
Gets the active render manager.

Constructors, destructors, conversion operators

~IRenderManager() pure virtual

Public functions

auto AddRef() -> int pure virtual
auto Release() -> int pure virtual
auto Initialize() -> bool pure virtual
auto Dispose() -> bool pure virtual
auto func14h() -> int pure virtual
auto func18h() -> int pure virtual
auto GetParameters() -> RenderererParams& pure virtual
auto GetAdapterCount() -> int pure virtual
auto func24h() -> int pure virtual
auto func28h() -> int pure virtual
auto func2Ch() -> int pure virtual
auto func30h() -> int pure virtual
auto func34h() -> int pure virtual
auto func38h() -> int pure virtual
auto func3Ch() -> int pure virtual
auto RenderLayers(int, int startLayer, int endLayer, int, bool, int flags) -> int pure virtual
auto func44h() -> int pure virtual
auto func48h() -> int pure virtual
void AddRenderable(IRenderable* object, int layerIndex, int flags = 0) pure virtual
Adds a IRenderable object to the specified queue index; the same renderable can be assigned to multiple layers.
void AddRenderable(LambdaRenderable::Render_t renderFunction, int layerIndex, int flags = 0)
Adds a renderable function to the specified queue index; the same renderable can be assigned to multiple layers.
auto RemoveRenderable(int nQueueIndex) -> bool pure virtual
Removes the IRenderable object assigned to the specified queue index.
void ClearRenderables() pure virtual
Removes all renderables from the manager.
auto GetRenderable(int layerIndex) -> IRenderable* pure virtual
Returns the renderable assigned to the given layer, or nullptr if there is none.
auto AddRenderableExtraFlags(int layerIndex, int flags) -> int pure virtual
auto RemoveRenderableExtraFlags(int layerIndex, int flags) -> int pure virtual
auto GetRenderableExtraFlags(int layerIndex) -> int pure virtual
auto GetRenderablesCount() const -> int pure virtual
auto GetRenderableAt(int index) -> IRenderable* pure virtual
auto GetRenderLayerAt(int index) -> RenderLayer& pure virtual

Function documentation

void Graphics::IRenderManager::AddRenderable(IRenderable* object, int layerIndex, int flags = 0) pure virtual

Adds a IRenderable object to the specified queue index; the same renderable can be assigned to multiple layers.

Parameters
object Pointer to the renderable object
layerIndex The index of the layer the given object renders.
flags

If there already was a renderable there, it will get removed.

void Graphics::IRenderManager::AddRenderable(LambdaRenderable::Render_t renderFunction, int layerIndex, int flags = 0)

Adds a renderable function to the specified queue index; the same renderable can be assigned to multiple layers.

Parameters
renderFunction Renderable function, can be a lambdas
layerIndex The index of the layer the given object renders.
flags

If there already was a renderable there, it will get removed.

bool Graphics::IRenderManager::RemoveRenderable(int nQueueIndex) pure virtual

Removes the IRenderable object assigned to the specified queue index.

Parameters
nQueueIndex

IRenderable* Graphics::IRenderManager::GetRenderable(int layerIndex) pure virtual

Returns the renderable assigned to the given layer, or nullptr if there is none.

Parameters
layerIndex