Class BufferedParticleBatch<T extends ParticleControllerRenderData>

    • Constructor Detail

      • BufferedParticleBatch

        protected BufferedParticleBatch​(java.lang.Class<T> type)
    • Method Detail

      • ensureCapacity

        public void ensureCapacity​(int capacity)
        Ensure the batch can contain the passed in amount of particles
      • resetCapacity

        public void resetCapacity()
      • allocParticlesData

        protected abstract void allocParticlesData​(int capacity)
      • setCamera

        public void setCamera​(Camera camera)
      • flush

        protected abstract void flush​(int[] offsets)
        Sends the data to the gpu. This method must use the calculated offsets to build the particles meshes. The offsets represent the position at which a particle should be placed into the vertex array.
        Parameters:
        offsets - the calculated offsets
      • getBufferedCount

        public int getBufferedCount()