IRRQuadRenderer Class Reference

A Renderer drawing particles as quads with Irrlicht. More...

Inheritance diagram for IRRQuadRenderer:
IRRRenderer QuadRendererInterface Oriented3DRendererInterface Renderer Registerable BufferHandler

List of all members.

Public Member Functions

 IRRQuadRenderer (irr::IrrlichtDevice *d, float scaleX=1.0f, float scaleY=1.0f)
 Constructor of IRRQuadRenderer.
void setTexture (irr::video::ITexture *texture)
 Sets the texture to map on particles.
void setAtlasDimensions (irr::core::dimension2du dim)
 Sets the atlas dimension of the texture in an Irrlicht way.
irr::video::ITexture * getTexture () const
 Gets the texture of this renderer.
irr::video::SMaterialLayer & getMaterialLayer ()
 Gets the material texture layer.
const irr::video::SMaterialLayer & getMaterialLayer () const
 Gets the material texture layer in a constant way.
irr::core::dimension2du getAtlasDimensions () const
 Gets the atlas dimension of the texture in an Irrlicht way.
virtual void render (const Group &group)
 Renders a Group of particles.
void createBuffers (const Group &group)
 Creates the buffers for this buffer handler in the given group.

Static Public Member Functions

static IRRQuadRenderercreate (irr::IrrlichtDevice *d, float scaleX=1.0f, float scaleY=1.0f)
 Creates and registers a new IRRQuadRenderer.

Detailed Description

A Renderer drawing particles as quads with Irrlicht.

The orientation of the quads depends on the orientation parameters set. This orientation is computed during rendering by the CPU (further improvement of SPARK will allow to make the computation on GPU side).

Below are the parameters of Particle that are used in this Renderer (others have no effects) :

Since:
1.04.00

Definition at line 54 of file SPK_IRRQuadRenderer.h.


Constructor & Destructor Documentation

IRRQuadRenderer ( irr::IrrlichtDevice *  d,
float  scaleX = 1.0f,
float  scaleY = 1.0f 
)

Constructor of IRRQuadRenderer.

Parameters:
d : the Irrlicht device
scaleX the scale of the width of the quad
scaleY the scale of the height of the quad

Member Function Documentation

IRRQuadRenderer * create ( irr::IrrlichtDevice *  d,
float  scaleX = 1.0f,
float  scaleY = 1.0f 
) [static]

Creates and registers a new IRRQuadRenderer.

Parameters:
d : the Irrlicht device
scaleX the scale of the width of the quad
scaleY the scale of the height of the quad
Returns:
A new registered IRRQuadRenderer
Since:
1.04.00

Definition at line 165 of file SPK_IRRQuadRenderer.h.

void createBuffers ( const Group group  )  [virtual]

Creates the buffers for this buffer handler in the given group.

If the buffers for this type of buffer handler already exists within the Group, they are priorly destroyed.
The type of buffers created depends on the state of the buffer handler at the time this method is called.

This method has to be overridden in derived classes that use buffers

Parameters:
group : the Group in which to create the buffers for this buffer handler

Reimplemented from BufferHandler.

irr::core::dimension2du getAtlasDimensions (  )  const

Gets the atlas dimension of the texture in an Irrlicht way.

Returns:
the atlas dimension of the texture

Definition at line 197 of file SPK_IRRQuadRenderer.h.

const irr::video::SMaterialLayer & getMaterialLayer (  )  const

Gets the material texture layer in a constant way.

Returns:
the material texture layer

Definition at line 192 of file SPK_IRRQuadRenderer.h.

irr::video::SMaterialLayer & getMaterialLayer (  ) 

Gets the material texture layer.

Returns:
the material texture layer

Definition at line 187 of file SPK_IRRQuadRenderer.h.

irr::video::ITexture * getTexture (  )  const

Gets the texture of this renderer.

Returns:
the texture of this renderer

Definition at line 182 of file SPK_IRRQuadRenderer.h.

virtual void render ( const Group group  )  [virtual]

Renders a Group of particles.

Parameters:
group : the Group to render

Implements Renderer.

void setAtlasDimensions ( irr::core::dimension2du  dim  ) 

Sets the atlas dimension of the texture in an Irrlicht way.

see setQuadAtlasDimension(unsigned int,unsigned int) for more information

Parameters:
dim : the atlas dimension of the texture

Definition at line 177 of file SPK_IRRQuadRenderer.h.

void setTexture ( irr::video::ITexture *  texture  ) 

Sets the texture to map on particles.

Note that this only works with points being rendered as SPK::POINT_SPRITE

Parameters:
texture : the texture to set

Definition at line 172 of file SPK_IRRQuadRenderer.h.


Generated on Wed Apr 27 21:09:27 2011 for SPARK Particle Engine by  doxygen 1.6.1