Class Index | File Index

Classes


Class R.particles.AccumulatorParticleEngine


Extends R.particles.ParticleEngine.
An updated particle engine with an accumulator buffer so that effects such as bloom, glow, and tail can be achieved. A note of caution, using the accumulator particle engine will be slower compared with the basic particle engine.

Because of the effect used by the accumulator particle engine, background imagery will be darkened slightly.
Defined in: accumulatorparticleengine.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
Create a particle engine
Method Summary
Method Attributes Method Name and Description
 
Destroy the particle engine
 
Get the class name of this object
 
Get the properties object for the particle engine
 
Releases the particle engine back into the pool.
 
Clear the accumulator
 
Set this value to true if the particle engine is atop a background image.
 
setBlur(state)
Enable blurring of the particles in the accumulator
 
setBlurRadius(radius)
Set the blurring radius around the pixel.
 
setFadeRate(fadeRate)
Set the rate at which the particles fade out
 
update(renderContext, time, dt)
Update the particles within the render context.
Methods borrowed from class R.particles.ParticleEngine:
addEffect, addParticle, addParticles, getMaximum, setMaximum
Methods borrowed from class R.engine.BaseObject:
addEvent, addEvents, getElement, jQ, removeEvent, setElement, triggerEvent
Methods borrowed from class R.engine.PooledObject:
clearObjectDataModel, getId, getName, getObjectDataModel, isDestroyed, setName, setObjectDataModel, toString, toXML
Class Detail
R.particles.AccumulatorParticleEngine()
Create a particle engine
Method Detail
destroy()
Destroy the particle engine

{String} getClassName()
Get the class name of this object
Returns:
{String} "R.particles.AccumulatorParticleEngine"

{Object} getProperties()
Get the properties object for the particle engine
Returns:
{Object}

release()
Releases the particle engine back into the pool.

reset()
Clear the accumulator

setBackgroundState(state)
Set this value to true if the particle engine is atop a background image. This will have the effect of slightly darkening the background image. If the background is solid black, you can set this to false.
Parameters:
state
{Boolean} The background state

setBlur(state)
Enable blurring of the particles in the accumulator
Parameters:
state
{Boolean} true to enable (default: false)

setBlurRadius(radius)
Set the blurring radius around the pixel. Higher numbers result in lower frame rates.
Parameters:
radius
{Number} The radius of the blur (default: 1)

setFadeRate(fadeRate)
Set the rate at which the particles fade out
Parameters:
fadeRate
{Number} A value between 0 and 1

update(renderContext, time, dt)
Update the particles within the render context.
Parameters:
renderContext
{R.rendercontexts.AbstractRenderContext} The context the particles will be rendered within.
time
{Number} The global time within the engine.
dt
{Number} The delta between the world time and the last time the world was updated in milliseconds.

Documentation generated by JsDoc Toolkit 2.4.0 on Mon Mar 18 2013 16:09:19 GMT-0400 (EDT)