|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.iris.Fissures.codec.Steim1
public class Steim1
Class for decoding or encoding Steim1-compressed data blocks to or from an array of integer values.
Steim compression scheme Copyrighted by Dr. Joseph Steim.
| Constructor Summary | |
|---|---|
Steim1()
Deprecated. |
|
| Method Summary | |
|---|---|
static int[] |
decode(byte[] b,
int numSamples,
boolean swapBytes)
Deprecated. Abbreviated, zero-bias version of decode(). |
static int[] |
decode(byte[] b,
int numSamples,
boolean swapBytes,
int bias)
Deprecated. Decode the indicated number of samples from the provided byte array and return an integer array of the decompressed values. |
static SteimFrameBlock |
encode(int[] samples,
int frames)
Deprecated. Abbreviated zero-bias version of encode(). |
static SteimFrameBlock |
encode(int[] samples,
int frames,
int bias)
Deprecated. Encode the array of integer values into a Steim 1 * compressed byte frame block. |
protected static int[] |
extractSamples(byte[] bytes,
int offset,
boolean swapBytes)
Deprecated. Extracts differences from the next 64 byte frame of the given compressed byte array (starting at offset) and returns those differences in an int array. |
static void |
main(java.lang.String[] args)
Deprecated. Static method for testing the decode() method. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Steim1()
| Method Detail |
|---|
public static int[] decode(byte[] b,
int numSamples,
boolean swapBytes,
int bias)
throws SteimException
b - input byte array to be decodednumSamples - the number of samples that can be decoded from array
bswapBytes - if true, swap reverse the endian-ness of the elements of
byte array b.bias - the first difference value will be computed from this value.
If set to 0, the method will attempt to use the X(0) constant instead.
SteimException - - encoded data length is not multiple of 64
bytes.
public static int[] decode(byte[] b,
int numSamples,
boolean swapBytes)
throws SteimException
SteimExceptiondecode(byte[],int,boolean,int)
public static SteimFrameBlock encode(int[] samples,
int frames,
int bias)
throws SteimException
samples - the data points represented as signed integersframes - the number of Steim frames to use in the encodingbias - offset for use as a constant for the first difference, otherwise
set to 0
SteimException - samples array is zero size
SteimException - number of frames is not a positive value
SteimException - cannot encode more than 63 frames
public static SteimFrameBlock encode(int[] samples,
int frames)
throws SteimException
SteimExceptionencode(int[],int,int)
protected static int[] extractSamples(byte[] bytes,
int offset,
boolean swapBytes)
bytes - byte array of compressed data differencesoffset - index to begin reading compressed bytes for decodingswapBytes - reverse the endian-ness of the compressed bytes being read
public static void main(java.lang.String[] args)
throws SteimException
args - not used
SteimException - from called method(s)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||