|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jocl.cloth.ClothSimulationCoreJOCL
class ClothSimulationCoreJOCL
The core of a cloth Simulation
implemented with OpenCL.
Constructor Summary | |
---|---|
ClothSimulationCoreJOCL(CLSetup clSetup,
ParticleData p,
ResourceHandle<org.jocl.cl_mem> positions,
ResourceHandle<org.jocl.cl_mem> candidatePositions,
EdgeData[] e,
ResourceHandle<java.nio.FloatBuffer> renderingPositions)
Creates a new cloth simulation core |
Method Summary | |
---|---|
void |
performTimeStep(float dt)
Perform a simulation step with the given size |
void |
prepareRendering()
Perform any steps necessary to render the current simulation state |
void |
shutdown()
Shut down the simulation and free all allocated resources |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
ClothSimulationCoreJOCL(CLSetup clSetup, ParticleData p, ResourceHandle<org.jocl.cl_mem> positions, ResourceHandle<org.jocl.cl_mem> candidatePositions, EdgeData[] e, ResourceHandle<java.nio.FloatBuffer> renderingPositions)
clSetup
- The OpenCL setupp
- The ParticleData
positions
- The positionscandidatePositions
- The candidate positionse
- The EdgeData
renderingPositions
- If the buffers are not shared
between OpenGL and OpenCL, then this is the handle to the
rendering buffer. Otherwise, this is null
.Method Detail |
---|
public void prepareRendering()
Simulation
prepareRendering
in interface Simulation
public void performTimeStep(float dt)
Simulation
performTimeStep
in interface Simulation
dt
- The step sizepublic void shutdown()
Simulation
shutdown
in interface Simulation
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |