Class PxParticleCloth

java.lang.Object
physx.NativeObject
physx.particles.PxParticleCloth

public class PxParticleCloth extends NativeObject
Particle cloth structure. Holds information about a single piece of cloth that is part of a #PxParticleClothBuffer.
  • Field Details

    • SIZEOF

      public static final int SIZEOF
    • ALIGNOF

      public static final int ALIGNOF
      See Also:
  • Constructor Details

    • PxParticleCloth

      protected PxParticleCloth(long address)
    • PxParticleCloth

      public PxParticleCloth()
  • Method Details

    • wrapPointer

      public static PxParticleCloth wrapPointer(long address)
    • arrayGet

      public static PxParticleCloth arrayGet(long baseAddress, int index)
    • createAt

      public static PxParticleCloth createAt(long address)
      Parameters:
      address - Pre-allocated memory, where the object is created.
      Returns:
      Stack allocated object of PxParticleCloth
    • createAt

      public static <T> PxParticleCloth createAt(T allocator, NativeObject.Allocator<T> allocate)
      Type Parameters:
      T - Allocator class, e.g. LWJGL's MemoryStack.
      Parameters:
      allocator - Object to use for allocation, e.g. an instance of LWJGL's MemoryStack.
      allocate - Method to call on allocator to obtain the target address, e.g. MemoryStack::nmalloc.
      Returns:
      Stack allocated object of PxParticleCloth
    • destroy

      public void destroy()
    • getStartVertexIndex

      public int getStartVertexIndex()
      Index of the first particle of this cloth in the position/velocity buffers of the parent #PxParticleClothBuffer
    • setStartVertexIndex

      public void setStartVertexIndex(int value)
      Index of the first particle of this cloth in the position/velocity buffers of the parent #PxParticleClothBuffer
    • getNumVertices

      public int getNumVertices()
      The number of particles of this piece of cloth
    • setNumVertices

      public void setNumVertices(int value)
      The number of particles of this piece of cloth
    • getClothBlendScale

      public float getClothBlendScale()
      Used internally.
    • setClothBlendScale

      public void setClothBlendScale(float value)
      Used internally.
    • getRestVolume

      public float getRestVolume()
      The rest volume of this piece of cloth, used for inflatable simulation.
    • setRestVolume

      public void setRestVolume(float value)
      The rest volume of this piece of cloth, used for inflatable simulation.
    • getPressure

      public float getPressure()
      The factor of the rest volume to specify the target volume for this piece of cloth, used for inflatable simulation.
    • setPressure

      public void setPressure(float value)
      The factor of the rest volume to specify the target volume for this piece of cloth, used for inflatable simulation.
    • getStartTriangleIndex

      public int getStartTriangleIndex()
      The index of the first triangle of this piece of cloth in the triangle list.
    • setStartTriangleIndex

      public void setStartTriangleIndex(int value)
      The index of the first triangle of this piece of cloth in the triangle list.
    • getNumTriangles

      public int getNumTriangles()
      The number of triangles of this piece of cloth.
    • setNumTriangles

      public void setNumTriangles(int value)
      The number of triangles of this piece of cloth.