Visualization Library

A lightweight C++ OpenGL middleware for 2D/3D graphics
[Home] [Tutorials] [All Classes] [Grouped Classes]
Public Member Functions | Protected Member Functions

vl::Renderable Class Reference

An abstract class that represents all the objects that can be rendered. More...

#include <Renderable.hpp>

Inheritance diagram for vl::Renderable:
vl::Object vl::Clear vl::DrawPixels vl::Geometry vl::Text vl::BezierSurface

List of all members.

Public Member Functions

virtual const char * className ()
 Returns the name of the class.
 Renderable ()
 Constructor.
virtual ~Renderable ()
 Destructor.
virtual void render (const Actor *actor, const Camera *camera) const =0
 Renders the Renderable.
long long boundsUpdateTick () const
void computeBounds ()
void setBoundsDirty (bool dirty)
bool boundsDirty () const
void setBoundingBox (const AABB &aabb)
const AABBboundingBox () const
void setBoundingSphere (const Sphere &sphere)
const SphereboundingSphere () const
unsigned int displayList () const
void setDisplayList (unsigned int disp_list)
bool displayListEnabled () const
void setDisplayListEnabled (bool enabled)
bool displayListDirty () const
void setDisplayListDirty (bool dirty)
bool vboEnabled () const
void setVBOEnabled (bool enabled)
bool vboDirty () const
void setVBODirty (bool dirty)
virtual void updateVBOs (bool)
 Uploads the data stored in the local buffers on the GPU memory.
virtual void deleteVBOs ()
 Destroyes the VBO (VertexBufferObjects) associated to this Geometry attributes.
void deleteDisplayList ()
void compileDisplayList (Actor *act, Camera *camera)

Protected Member Functions

virtual void computeBounds_Implementation ()=0

Detailed Description

An abstract class that represents all the objects that can be rendered.

In order to render a Renderable you have to bind it to an Actor. An Actor glues together a Renderable, an Effect and eventually a Transform. Note that the same Renderable can be associated to more than one Actor.

See also:
Actor, Effect, Transform, Geometry

Constructor & Destructor Documentation

vl::Renderable::Renderable (  ) [inline]

Constructor.

virtual vl::Renderable::~Renderable (  ) [inline, virtual]

Destructor.


Member Function Documentation

virtual const char* vl::Renderable::className (  ) [inline, virtual]

Returns the name of the class.

Reimplemented from vl::Object.

Reimplemented in vl::BezierSurface, vl::Clear, vl::DrawPixels, vl::Geometry, and vl::Text.

virtual void vl::Renderable::render ( const Actor actor,
const Camera camera 
) const [pure virtual]

Renders the Renderable.

Implemented in vl::Clear, vl::DrawPixels, vl::Geometry, and vl::Text.

long long vl::Renderable::boundsUpdateTick (  ) const [inline]
void vl::Renderable::computeBounds (  ) [inline]
void vl::Renderable::setBoundsDirty ( bool  dirty ) [inline]
bool vl::Renderable::boundsDirty (  ) const [inline]
void vl::Renderable::setBoundingBox ( const AABB aabb ) [inline]
const AABB& vl::Renderable::boundingBox (  ) const [inline]
void vl::Renderable::setBoundingSphere ( const Sphere sphere ) [inline]
const Sphere& vl::Renderable::boundingSphere (  ) const [inline]
unsigned int vl::Renderable::displayList (  ) const [inline]
void vl::Renderable::setDisplayList ( unsigned int  disp_list ) [inline]
bool vl::Renderable::displayListEnabled (  ) const [inline]
void vl::Renderable::setDisplayListEnabled ( bool  enabled ) [inline]
bool vl::Renderable::displayListDirty (  ) const [inline]
void vl::Renderable::setDisplayListDirty ( bool  dirty ) [inline]
bool vl::Renderable::vboEnabled (  ) const [inline]
void vl::Renderable::setVBOEnabled ( bool  enabled ) [inline]
bool vl::Renderable::vboDirty (  ) const [inline]
void vl::Renderable::setVBODirty ( bool  dirty ) [inline]
virtual void vl::Renderable::updateVBOs ( bool   ) [inline, virtual]

Uploads the data stored in the local buffers on the GPU memory.

If 'discard_local_data' is set to true the memory used by the local buffers is released.

Reimplemented in vl::Geometry.

virtual void vl::Renderable::deleteVBOs (  ) [inline, virtual]

Destroyes the VBO (VertexBufferObjects) associated to this Geometry attributes.

If 'clear_primitives' all the VBOs associated the DrawCall objects are also deleted.

Note:
This function does not touch the local (non GPU) data stored in the buffers associated to the vertex attributes and DrawCall.

Reimplemented in vl::Geometry.

void vl::Renderable::deleteDisplayList (  ) [inline]
void vl::Renderable::compileDisplayList ( Actor act,
Camera camera 
) [inline]
virtual void vl::Renderable::computeBounds_Implementation (  ) [protected, pure virtual]

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

Visualization Library v2010.11.1123 Reference Documentation
Copyright 2005-2009 Michele Bosi. All rights reserved.
Updated on Thu Nov 18 2010 02:08:11.
Permission is granted to use this page to write and publish articles regarding Visualization Library.