|
Aviatrix3D 2.1.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.j3d.geom.particle.ParticleSystem org.j3d.renderer.aviatrix3d.geom.particle.AVParticleSystem
public abstract class AVParticleSystem
Base particle system implementation for geometry implemented over Aviatrix3D scene graphs.
The node updater is registered for bounds changing events every frame. However, data changed listeners are not registered, unless per-vertex colours are being generated. If a derived class wishes to update other aspects, such as normals, texture coordinates or vertex attributes, then they will need to make their own arrangements to request the updates.
Per-vertex colours can be turned on or off by the derived class simply
by changing the return value from numColorComponents()
to be
zero.
Field Summary | |
---|---|
protected float[] |
colors
Array containing the current color values |
protected float[] |
normals
Array containing the current normals |
protected Geometry |
particleGeometry
The shape containing the geometry |
protected boolean |
sendNewArrays
Flag indicating we also need to force-feed new arrays to the particles because the user upped the particle count last frame. |
protected float[][] |
texCoords
Array containing the current texture coordinates. |
protected float[] |
vertices
Array containing the current position coordinates |
Fields inherited from class org.j3d.geom.particle.ParticleSystem |
---|
errorReporter, frameTime, genTexCoords, maxParticleCount, particleCount, particleList, texCoordInterp, timeNow |
Constructor Summary | |
---|---|
AVParticleSystem(java.lang.String systemType,
int particleCount)
Create a new particle system that represents the given type. |
Method Summary | |
---|---|
Geometry |
getNode()
Get the scene graph object that represents this particle system and can be inserted into the scene graph. |
protected void |
initializeArrays()
Set up the arrays used internally now. |
void |
setMaxParticleCount(int maxCount)
Change the maximum number of particles that can be generated. |
protected void |
updateGeometry()
Update the arrays for the geometry object. |
Methods inherited from class org.j3d.geom.particle.ParticleSystem |
---|
addParticleFunction, enableParticleCreation, enableTextureCoordinates, getMaxParticleCount, getParticleInitializer, getSystemName, initialize, insertParticleFunction, isParticleCreationEnabled, isTextureCoordinateEnabled, onRemove, removeParticleFunction, setErrorReporter, setParticleInitializer, setSystemName, setTexCoordFunction, update |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.j3d.aviatrix3d.NodeUpdateListener |
---|
updateNodeBoundsChanges, updateNodeDataChanges |
Methods inherited from interface org.j3d.geom.particle.ParticleFactory |
---|
coordinatesPerParticle, createParticle, numColorComponents, numTexCoordComponents |
Field Detail |
---|
protected float[] vertices
protected float[][] texCoords
protected float[] colors
protected float[] normals
protected Geometry particleGeometry
protected boolean sendNewArrays
Constructor Detail |
---|
public AVParticleSystem(java.lang.String systemType, int particleCount)
systemType
- An identifier describing the current system typeparticleCount
- The max nuumber of particles to createMethod Detail |
---|
protected void updateGeometry()
updateGeometry
in class org.j3d.geom.particle.ParticleSystem
public Geometry getNode()
protected void initializeArrays()
public void setMaxParticleCount(int maxCount)
setMaxParticleCount
in class org.j3d.geom.particle.ParticleSystem
maxCount
- The new maximum particle count to use
java.lang.IllegalArgumentException
- The particle count was negative
|
Aviatrix3D 2.1.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |