Package com.jme3.renderer.queue
Class GeometryList
java.lang.Object
com.jme3.renderer.queue.GeometryList
This class is a special purpose list of 
Geometry objects for render
 queuing.- 
Constructor SummaryConstructorsConstructorDescriptionGeometryList(GeometryComparator comparator) Initializes the GeometryList to use the givenGeometryComparatorto use for comparing geometries.
- 
Method SummaryModifier and TypeMethodDescriptionvoidAdds a geometry to the list.voidclear()Resets list size to 0.get(int index) Returns the element at the given index.Returns the GeometryComparator that this Geometry list uses for sorting.iterator()voidSets the element at the given index.voidSet the camera that will be set on the geometry comparators viaGeometryComparator.setCamera(com.jme3.renderer.Camera).voidsetComparator(GeometryComparator comparator) intsize()Returns the number of elements in this GeometryList.voidsort()Sorts the elements in the list according to their Comparator.Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.IterableforEach, spliterator
- 
Constructor Details- 
GeometryListInitializes the GeometryList to use the givenGeometryComparatorto use for comparing geometries.- Parameters:
- comparator- The comparator to use.
 
 
- 
- 
Method Details- 
setComparator
- 
getComparatorReturns the GeometryComparator that this Geometry list uses for sorting.- Returns:
- the pre-existing instance
 
- 
setCameraSet the camera that will be set on the geometry comparators viaGeometryComparator.setCamera(com.jme3.renderer.Camera).- Parameters:
- cam- Camera to use for sorting.
 
- 
sizepublic int size()Returns the number of elements in this GeometryList.- Returns:
- Number of elements in the list
 
- 
setSets the element at the given index.- Parameters:
- index- The index to set
- value- The value
 
- 
getReturns the element at the given index.- Parameters:
- index- The index to lookup
- Returns:
- Geometry at the index
 
- 
addAdds a geometry to the list. List size is doubled if there is no room.- Parameters:
- g- The geometry to add.
 
- 
clearpublic void clear()Resets list size to 0.
- 
sortpublic void sort()Sorts the elements in the list according to their Comparator.
- 
iterator
 
-