Package com.jme3.animation
Class CompactQuaternionArray
- All Implemented Interfaces:
Savable
,JmeCloneable
,Cloneable
Serialize and compress
Quaternion
[] by indexing same values
It is converted to float[]-
Field Summary
Fields inherited from class com.jme3.animation.CompactArray
array, index, indexPool
-
Constructor Summary
ConstructorDescriptioncreates a compact Quaternion arrayCompactQuaternionArray
(float[] dataArray, int[] index) creates a compact Quaternion array -
Method Summary
Modifier and TypeMethodDescriptionprotected Quaternion
deserialize
(int i, Quaternion store) deserialize objectprotected final Class<Quaternion>
protected final int
serialized size of one object elementvoid
read
(JmeImporter im) protected void
serialize
(int i, Quaternion store) serialize objectvoid
write
(JmeExporter ex) Methods inherited from class com.jme3.animation.CompactArray
add, clone, cloneFields, ensureCapacity, freeze, get, getCompactIndex, getCompactObjectSize, getIndex, getSerializedData, getSerializedSize, getTotalObjectSize, jmeClone, serialize, set, setInvalid, toObjectArray
-
Constructor Details
-
CompactQuaternionArray
public CompactQuaternionArray()creates a compact Quaternion array -
CompactQuaternionArray
public CompactQuaternionArray(float[] dataArray, int[] index) creates a compact Quaternion array- Parameters:
dataArray
- the data arrayindex
- the indices array
-
-
Method Details
-
getTupleSize
protected final int getTupleSize()Description copied from class:CompactArray
serialized size of one object element- Specified by:
getTupleSize
in classCompactArray<Quaternion>
- Returns:
- the number of primitive components (floats) per object
-
getElementClass
- Specified by:
getElementClass
in classCompactArray<Quaternion>
-
write
- Specified by:
write
in interfaceSavable
- Throws:
IOException
-
read
- Specified by:
read
in interfaceSavable
- Throws:
IOException
-
serialize
Description copied from class:CompactArray
serialize object- Specified by:
serialize
in classCompactArray<Quaternion>
- Parameters:
i
- compacted object indexstore
- the value to be serialized (not null, unaffected)
-
deserialize
Description copied from class:CompactArray
deserialize object- Specified by:
deserialize
in classCompactArray<Quaternion>
- Parameters:
i
- compacted object indexstore
- storage for the result- Returns:
- the deserialized value
-