Package com.jme3.bullet.animation
Class VectorSet
java.lang.Object
com.jme3.bullet.animation.VectorSet
A simplified collection of Vector3f values without duplicates, implemented
 using a Collection.
 
This class is shared between JBullet and Native Bullet.
- 
Constructor SummaryConstructorsConstructorDescriptionVectorSet(int numVectors) Instantiate an empty set with the specified initial capacity and default load factor.
- 
Method SummaryModifier and TypeMethodDescriptionvoidAdd the value of the specified Vector3f to this set.booleanTest whether this set contains the value of the specified Vector3f.Calculate the sample mean for each axis over the Vector3f values in this set.intCalculate the number of Vector3f values in this set.toBuffer()Access the buffer containing all the Vector3f values in this set.
- 
Constructor Details- 
VectorSetpublic VectorSet(int numVectors) Instantiate an empty set with the specified initial capacity and default load factor.- Parameters:
- numVectors- the initial capacity of the hash table (>0)
 
 
- 
- 
Method Details- 
addAdd the value of the specified Vector3f to this set.- Parameters:
- vector- the value to add (not null, unaffected)
 
- 
containsTest whether this set contains the value of the specified Vector3f.- Parameters:
- vector- the value to find (not null, unaffected)
- Returns:
- true if found, otherwise false
 
- 
meanCalculate the sample mean for each axis over the Vector3f values in this set.- Parameters:
- storeResult- (modified if not null)
- Returns:
- the sample mean for each axis (either storeResult or a new Vector3f)
 
- 
numVectorspublic int numVectors()Calculate the number of Vector3f values in this set.- Returns:
- the count (≥0)
 
- 
toBufferAccess the buffer containing all the Vector3f values in this set. No further add() is allowed.- Returns:
- a new buffer, flipped
 
 
-