|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectjavaFlacEncoder.EncodedElement
javaFlacEncoder.EncodedElement_32
public class EncodedElement_32
EncodedElement which uses an integer array as a backing, rather than the byte array.
| Field Summary |
|---|
| Fields inherited from class javaFlacEncoder.EncodedElement |
|---|
offset |
| Constructor Summary | |
|---|---|
EncodedElement_32()
|
|
EncodedElement_32(int size,
int off)
|
|
| Method Summary | |
|---|---|
EncodedElement |
addInt(int input,
int bitCount)
Add a number of bits from an int to the end of this list's data. |
static void |
addInt(int value,
int count,
int startPos,
int[] dest)
This method adds a given number of bits of an int to a byte array. |
void |
clear(int size,
int off)
Completely clear this element and use the given size and offset for the new data array. |
EncodedElement |
convertToEncodedElement()
|
byte[] |
getData()
Get the byte array stored by this object(null if not set). |
int[] |
getData32()
|
EncodedElement |
packIntByBits(int[] inputA,
int[] inputBits,
int inputOffset,
int countA)
Pack a number of bits from each int of an array(within given limits)to the end of this list. |
static void |
packIntByBits(int[] inputA,
int[] inputBits,
int inputOffset,
int countA,
int startPosIn,
int[] dest)
Pack a number of bits from each int of an array(within given limits)to the end of this list. |
| Methods inherited from class javaFlacEncoder.EncodedElement |
|---|
addInt, addLong, addLong, attachEnd, clear, getCRC16, getEnd_S, getEnd, getTotalBits, packInt, packInt, packIntByBits, padToByte, print, print |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EncodedElement_32()
public EncodedElement_32(int size,
int off)
| Method Detail |
|---|
public void clear(int size,
int off)
EncodedElement
clear in class EncodedElementsize - Size of data array to use(in bytes)off - Offset to use for this element. Usablebits will also be set to
this value.
public static void addInt(int value,
int count,
int startPos,
int[] dest)
value - int to store bits fromcount - number of low-order bits to storestartPos - start bit location in array to begin writingdest - array to store bits in. dest MUST have enough space to store
the given data, or this function will fail.public int[] getData32()
public static void packIntByBits(int[] inputA,
int[] inputBits,
int inputOffset,
int countA,
int startPosIn,
int[] dest)
inputA - Array containing input values.inputBits - Array containing number of bits to use for each index
packed. This array should be equal in size to the inputA array.inputOffset - Index of first usable index.countA - Number of indices to pack.startPosIn - First usable bit-level index in destination array(byte
index = startPosIn/8, bit within that byte = startPosIn%8)dest - Destination array to store input values in. This array *must*
be large enough to store all values or this method will fail in an
undefined manner.
public EncodedElement packIntByBits(int[] inputA,
int[] inputBits,
int inputOffset,
int countA)
packIntByBits in class EncodedElementinputA - Array containing input values.inputBits - Array containing number of bits to use for each index
packed. This array should be equal in size to the inputA array.inputOffset - Index of first usable index.countA - Number of indices to pack.
public byte[] getData()
EncodedElement
public EncodedElement convertToEncodedElement()
public EncodedElement addInt(int input,
int bitCount)
addInt in class EncodedElementinput - Int containing bits to append to end.bitCount - Number of bits to append.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||