# Visualization Library

A lightweight C++ OpenGL middleware for 2D/3D graphics

[Home] [Tutorials] [All Classes] [Grouped Classes]

Public Member Functions | Protected Attributes

# vl::Renderer Class Reference

The Renderer class executes the actual rendering on the given RenderQueue. More...

`#include <Renderer.hpp>`

Inheritance diagram for vl::Renderer:

List of all members.

## Public Member Functions

virtual const char * | className ()
| Returns the name of the class.
| Renderer ()
virtual | ~Renderer ()
virtual const RenderQueue * | render (const RenderQueue *in_render_queue, Camera *camera, Real frame_clock)
| Takes as input the render queue to render and returns a possibly filtered render queue for further processing.
void | setProjViewTransfCallback (ProjViewTransfCallback *callback)
const ProjViewTransfCallback * | projViewTransfCallback () const
ProjViewTransfCallback * | projViewTransfCallback ()
const std::map< unsigned int, ref< Shader > > & | shaderOverrideMask () const
| A bitmask/Shader map used to everride the Shader of those Actors whose enable mask satisfy the following condition: (Actors::enableMask() & bitmask) != 0.
std::map< unsigned int, ref < Shader > > & | shaderOverrideMask ()
| A bitmask/Shader map used to everride the Shader of those Actors whose enable mask satisfy the following condition: (Actors::enableMask() & bitmask) != 0.
bool | isEnabled (unsigned int mask)
void | setRenderTarget (RenderTarget *render_target)
| The RenderTarget on which the rendering is performed.
const RenderTarget * | renderTarget () const
| The RenderTarget on which the rendering is performed.
RenderTarget * | renderTarget ()
| The RenderTarget on which the rendering is performed.

## Protected Attributes

ref< RenderTarget > | mRenderTarget
vl::ref< EnableSet > | mDummyEnables
vl::ref< RenderStateSet > | mDummyStateSet
std::map< unsigned int, ref < Shader > > | mShaderOverrideMask
ref< ProjViewTransfCallback > | mProjViewTransfCallback

## Detailed Description

The Renderer class executes the actual rendering on the given RenderQueue.

See also:
  Rendering

Definition at line 47 of file Renderer.hpp.

## Constructor & Destructor Documentation

Renderer::Renderer | ( | ) |

Definition at line 43 of file Renderer.cpp.

References mDummyEnables, mDummyStateSet, mProjViewTransfCallback, and VL_DEBUG_SET_OBJECT_NAME.

virtual vl::Renderer::~Renderer | ( | ) | `[inline, virtual]`

Definition at line 54 of file Renderer.hpp.

## Member Function Documentation

virtual const char* vl::Renderer::className | ( | ) | `[inline, virtual]`

Returns the name of the class.

Reimplemented from vl::RendererAbstract.

Reimplemented in vl::EdgeRenderer, and vl::OcclusionCullRenderer.

Definition at line 50 of file Renderer.hpp.

const RenderQueue * Renderer::render | ( | const RenderQueue * | in_render_queue,
|  | Camera * | camera,
|  | Real | frame_clock
| ) |  | `[virtual]`

Takes as input the render queue to render and returns a possibly filtered render queue for further processing.

Renderer's implementation of this function always returns `in_render_queue`.

Implements vl::RendererAbstract.

Reimplemented in vl::EdgeRenderer, and vl::OcclusionCullRenderer.

Definition at line 78 of file Renderer.cpp.

References vl::Viewport::activate(), vl::OpenGLContext::applyEnables(), vl::OpenGLContext::applyRenderStates(), vl::GLSLProgram::applyUniformSet(), vl::OpenGLContext::areUniformsColliding(), vl::RenderQueue::at(), vl::OpenGLContext::bindVAS(), vl::Actor::dispatchOnActorRenderStarted(), vl::Scissor::enable(), vl::Actor::enableMask(), vl::RendererAbstract::enableMask(), vl::Log::error(), vl::ref< T >::get(), vl::Shader::getEnableSet(), vl::Shader::getRenderStateSet(), vl::Actor::getUniformSet(), vl::Shader::getUniformSet(), vl::RenderStateSet::glslProgram(), vl::Shader::glslProgram(), vl::GLSLProgram::handle(), vl::Viewport::height(), vl::OpenGLContext::isCleanState(), vl::OpenGLContext::isCompatible(), isEnabled(), vl::GLSLProgram::linked(), vl::RenderToken::mActor, mDummyEnables, mDummyStateSet, vl::RenderToken::mNextPass, vl::RenderToken::mRenderable, vl::RenderToken::mShader, mShaderOverrideMask, vl::RenderTarget::openglContext(), projViewTransfCallback(), vl::Renderable::render(), renderTarget(), vl::Shader::scissor(), vl::Actor::scissor(), vl::Viewport::setClearFlags(), vl::RenderQueue::size(), vl::Actor::transform(), vl::UniformSet::uniforms(), vl::GLSLProgram::uniformSet(), vl::ProjViewTransfCallback::updateMatrices(), vl::Camera::viewport(), VL_CHECK, VL_CHECK_OGL, vl::VL_glActiveTexture(), vl::VL_glClientActiveTexture(), VL_TRAP, vl::Viewport::width(), vl::Viewport::x(), and vl::Viewport::y().

void vl::Renderer::setProjViewTransfCallback | ( | ProjViewTransfCallback * | callback ) | `[inline]`

Definition at line 60 of file Renderer.hpp.

const ProjViewTransfCallback* vl::Renderer::projViewTransfCallback | ( | ) | const`[inline]`

Definition at line 62 of file Renderer.hpp.

Referenced by render(), and vl::OcclusionCullRenderer::render_pass2().

ProjViewTransfCallback* vl::Renderer::projViewTransfCallback | ( | ) | `[inline]`

Definition at line 64 of file Renderer.hpp.

const std::map<unsigned int, ref<Shader> >& vl::Renderer::shaderOverrideMask | ( | ) | const`[inline]`

A bitmask/Shader map used to everride the Shader of those Actors whose enable mask satisfy the following condition: (Actors::enableMask() & bitmask) != 0.

Definition at line 67 of file Renderer.hpp.

std::map<unsigned int, ref<Shader> >& vl::Renderer::shaderOverrideMask | ( | ) | `[inline]`

A bitmask/Shader map used to everride the Shader of those Actors whose enable mask satisfy the following condition: (Actors::enableMask() & bitmask) != 0.

Definition at line 70 of file Renderer.hpp.

bool vl::Renderer::isEnabled | ( | unsigned int | mask ) | `[inline]`

Definition at line 72 of file Renderer.hpp.

Referenced by render(), and vl::EdgeRenderer::render().

void vl::Renderer::setRenderTarget | ( | RenderTarget * | render_target ) | `[inline]`

The RenderTarget on which the rendering is performed.

Definition at line 75 of file Renderer.hpp.

const RenderTarget* vl::Renderer::renderTarget | ( | ) | const`[inline, virtual]`

The RenderTarget on which the rendering is performed.

Implements vl::RendererAbstract.

Reimplemented in vl::OcclusionCullRenderer.

Definition at line 78 of file Renderer.hpp.

Referenced by render(), vl::EdgeRenderer::render(), vl::EdgeRenderer::renderLines(), vl::EdgeRenderer::renderSolids(), and vl::Applet::resizeEvent().

RenderTarget* vl::Renderer::renderTarget | ( | ) | `[inline, virtual]`

The RenderTarget on which the rendering is performed.

Implements vl::RendererAbstract.

Reimplemented in vl::OcclusionCullRenderer.

Definition at line 81 of file Renderer.hpp.

## Member Data Documentation

ref<RenderTarget> vl::Renderer::mRenderTarget`[protected]`

Definition at line 84 of file Renderer.hpp.

vl::ref<EnableSet> vl::Renderer::mDummyEnables`[protected]`

Definition at line 87 of file Renderer.hpp.

Referenced by render(), vl::OcclusionCullRenderer::render_pass2(), and Renderer().

vl::ref<RenderStateSet> vl::Renderer::mDummyStateSet`[protected]`

Definition at line 88 of file Renderer.hpp.

Referenced by render(), vl::OcclusionCullRenderer::render_pass2(), and Renderer().

std::map<unsigned int, ref<Shader> > vl::Renderer::mShaderOverrideMask`[protected]`

Definition at line 90 of file Renderer.hpp.

Referenced by render().

ref<ProjViewTransfCallback> vl::Renderer::mProjViewTransfCallback`[protected]`

Definition at line 92 of file Renderer.hpp.

Referenced by Renderer().

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

- D:/VL/BuildSystem/VL_DISTRO/Visualization_Library_SDK/src/vlGraphics/Renderer.hpp
- D:/VL/BuildSystem/VL_DISTRO/Visualization_Library_SDK/src/vlGraphics/Renderer.cpp

Visualization Library v2011.05.1142 Reference Documentation
Copyright 2005-2011 Michele Bosi. All rights reserved.
Updated on Thu May 26 2011 22:51:44.
Permission is granted to use this page to write and publish articles regarding Visualization Library.