GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> LDT / V0-5-0 > encdec / sun-gcc


Interface   Data Structures   File List   Data Fields   Globals  

HDD.h File Reference

Interface to the routines to decode a distribution of symbols previously encoded using HDE_encodeSS. More...


Typedefs

typedef struct _HDD HDD

Functions

void * HDD_construct (HDD *hde, unsigned int nhuff)
 Constructs (initializes) the specified HDD structure.
unsigned int HDD_sizeof (unsigned int nhuff)
 Returns the size, in bytes, for a handle to hold a Huffman distribution of huffman_bins.
unsigned int HDD_decodeS (HDD *hdd, const unsigned int *src, unsigned int pos, unsigned int max_pos, short *syms, unsigned int nsyms)
 Unpacks the distribution encoded with HDD_encodeSS.
unsigned int HDD_tableDecode (HDD *hdd, const unsigned int *src, unsigned int pos, unsigned int max_pos)
 Unpacks the table encoded with HDE_tableEncode.
unsigned int HDD_symbolsDecodeS (HDD *hdd, const unsigned int *src, unsigned int pos, unsigned int max_pos, short *syms, unsigned int nsyms)
 Unpacks the distribution encoded with HDD_symbolsEncodeS.


Detailed Description

Interface to the routines to decode a distribution of symbols previously encoded using HDE_encodeSS.

Author:
JJRussell - russell@slac.stanford.edu

   CVS $Id: HDD.h,v 1.2 2010/08/06 18:58:49 saxton Exp $

Function Documentation

void HDD_construct ( HDD *  hdd,
unsigned int  nhuff 
)

Constructs (initializes) the specified HDD structure.

Returns:
The next address after this structure.
Parameters:
hdd The HDD control structure to construct
nhuff The maximum number of Huffman encoding bins that this control structure is meant to support.
The size of this structure should be acquired by a call to HDD_sizeof. The parameter huffman_nbins must be the same in the call to HDD_sizeof and HDD_construct.

unsigned int HDD_decodeS ( HDD *  hdd,
const unsigned int *  src,
unsigned int  pos,
unsigned int  max_pos,
short *  syms,
unsigned int  nsyms 
)

Unpacks the distribution encoded with HDD_encodeSS.

Returns:
The next bit position to read.
Parameters:
hdd The decode handle
src The source stream
pos The current bit read position
max_pos The maximum bit position, i.e. do not read past this point
syms The array to receive the decoded symbols
nsyms The number of symbols to decode

unsigned int HDD_sizeof ( unsigned int  nhuff  ) 

Returns the size, in bytes, for a handle to hold a Huffman distribution of huffman_bins.

Parameters:
nhuff The maximum number of Huffman codes
For the most part, this only provides a working area. On host-based workstations with expandable stacks, this memory would go on the stack, except for the fact that it is variable length.

unsigned int HDD_symbolsDecodeS ( HDD *  hdd,
const unsigned int *  src,
unsigned int  pos,
unsigned int  max_pos,
short *  syms,
unsigned int  nsyms 
)

Unpacks the distribution encoded with HDD_symbolsEncodeS.

Returns:
The next bit position to read.
Parameters:
hdd The decode handle
src The source stream
pos The current bit read position
max_pos The maximum bit position, i.e. do not read past this point
syms The array to receive the decoded symbols
nsyms The number of symbols to decode

unsigned int HDD_tableDecode ( HDD *  hdd,
const unsigned int *  src,
unsigned int  pos,
unsigned int  max_pos 
)

Unpacks the table encoded with HDE_tableEncode.

Returns:
The next bit position to read.
Parameters:
hdd The decode handle
src The source stream
pos The current bit read position
max_pos The maximum bit position, i.e. do not read past this point


Generated on Mon Aug 23 09:45:05 2010 by  doxygen 1.5.3