# Visualization Library

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

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

Public Member Functions | Protected Attributes

# vl::RenderEventCallback Class Reference

An abstract class used to react to rendering events. More...

`#include <RenderEventCallback.hpp>`

Inheritance diagram for vl::RenderEventCallback:

List of all members.

## Public Member Functions

virtual const char * | className ()
| Returns the name of the class.
| RenderEventCallback ()
virtual bool | onRenderingStarted (const RenderingAbstract *)=0
| Reimplement to react to this event.
virtual bool | onRenderingFinished (const RenderingAbstract *)=0
| Reimplement to react to this event.
virtual bool | onRendererStarted (const RendererAbstract *)=0
| Reimplement to react to this event.
virtual bool | onRendererFinished (const RendererAbstract *)=0
| Reimplement to react to this event.
void | setRemoveAfterCall (bool remove)
| Defines if the callback shall be removed after being executed.
bool | removeAfterCall () const
| Defines if the callback shall be removed after being executed.
void | setEnabled (bool enabled)
| Enabled/disabled callback.
bool | isEnabled () const
| Whether the callback is enabled or not.

## Protected Attributes

bool | mRemoveAfterCall
bool | mEnabled

## Detailed Description

An abstract class used to react to rendering events.

You can bind a callback to both Rendering and Renderer. The callbacks are executed in the same order in which they appear in the containing collection.

See also:
  - Rendering::renderEventCallbacks()
  - Renderer::renderEventCallbacks().
  - vl::RenderingAbstract, vl::Rendering
  - vl::RendererAbstract, vl::Renderer

Definition at line 53 of file RenderEventCallback.hpp.

## Constructor & Destructor Documentation

vl::RenderEventCallback::RenderEventCallback | ( | ) | `[inline]`

Definition at line 57 of file RenderEventCallback.hpp.

References VL_DEBUG_SET_OBJECT_NAME.

## Member Function Documentation

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

Returns the name of the class.

Reimplemented from vl::Object.

Reimplemented in vl::BlitFramebuffer, vl::CopyTexSubImage, vl::CopyTexSubImage1D, vl::CopyTexSubImage2D, vl::CopyTexSubImage3D, and vl::ReadPixels.

Definition at line 56 of file RenderEventCallback.hpp.

virtual bool vl::RenderEventCallback::onRenderingStarted | ( | const RenderingAbstract * | ) | `[pure virtual]`

Reimplement to react to this event.

Returns:
  `true` if the callback reacted to the given event.

Implemented in vl::BlitFramebuffer, vl::CopyTexSubImage, and vl::ReadPixels.

virtual bool vl::RenderEventCallback::onRenderingFinished | ( | const RenderingAbstract * | ) | `[pure virtual]`

Reimplement to react to this event.

Returns:
  `true` if the callback reacted to the given event.

Implemented in vl::BlitFramebuffer, vl::CopyTexSubImage, and vl::ReadPixels.

virtual bool vl::RenderEventCallback::onRendererStarted | ( | const RendererAbstract * | ) | `[pure virtual]`

Reimplement to react to this event.

Returns:
  `true` if the callback reacted to the given event.

Implemented in vl::BlitFramebuffer, vl::CopyTexSubImage, and vl::ReadPixels.

virtual bool vl::RenderEventCallback::onRendererFinished | ( | const RendererAbstract * | ) | `[pure virtual]`

Reimplement to react to this event.

Returns:
  `true` if the callback reacted to the given event.

Implemented in vl::BlitFramebuffer, vl::CopyTexSubImage, and vl::ReadPixels.

void vl::RenderEventCallback::setRemoveAfterCall | ( | bool | remove ) | `[inline]`

Defines if the callback shall be removed after being executed.

Note that the callback is removed only if the renderingCallback() method returns `true`.

Definition at line 80 of file RenderEventCallback.hpp.

References mRemoveAfterCall.

bool vl::RenderEventCallback::removeAfterCall | ( | ) | const`[inline]`

Defines if the callback shall be removed after being executed.

Note that the callback is removed only if the renderingCallback() method returns `true`.

Definition at line 84 of file RenderEventCallback.hpp.

References mRemoveAfterCall.

void vl::RenderEventCallback::setEnabled | ( | bool | enabled ) | `[inline]`

Enabled/disabled callback.

Disabled callbacks won't be notified of any event.

Definition at line 87 of file RenderEventCallback.hpp.

References mEnabled.

bool vl::RenderEventCallback::isEnabled | ( | ) | const`[inline]`

Whether the callback is enabled or not.

Disabled callbacks won't be notified of any event.

Definition at line 90 of file RenderEventCallback.hpp.

References mEnabled.

## Member Data Documentation

bool vl::RenderEventCallback::mRemoveAfterCall`[protected]`

Definition at line 93 of file RenderEventCallback.hpp.

Referenced by removeAfterCall(), and setRemoveAfterCall().

bool vl::RenderEventCallback::mEnabled`[protected]`

Definition at line 94 of file RenderEventCallback.hpp.

Referenced by isEnabled(), and setEnabled().

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

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

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.