EncodeLZ77FixedHuff

Performs fixed Huffman encoding.

Syntax

IppStatus ippsEncodeLZ77FixedHuff_8u (IppLZ77Pair** ppSrc, int* pSrcLen, Ipp8u** ppDst, int* pDstLen, IppLZ77flush flush, IppLZ77_8u* pLZ77State);

Parameters

ppSrc

Double pointer to the source buffer.

pSrcLen

Pointer to the length of the source buffer.

ppDst

Double pointer to the destination buffer.

pDstLen

Pointer to the length of the destination buffer.

flush

Specifies the encoding mode for data blocks (see flush Parameter).

pLZ77State

Pointer to the LZ77 encoding state structure.

Description

The function ippsEncodeLZ77FixedHuff is declared in the ippdc.h file. This function performs encoding with the fixed Huffman codes (see RFC1951 specification) of the input data stream of the IppLZ77Pair type that is produced by the function ippsEncodeLZ77.

The function ippsEncodeLZ77FixedHuff writes the marker of the end of the block to the output stream and aligns the output data in accordance with the specified parameter flush.

If the function returns one of the ippStsNoErr, ippStsDstSizeLessExpected, or ippStsStreamEnd statuses, the values of the pointers to the source and destination data buffers and to their lengths are changed and their new values are returned.

The function uses the LZ77 encoding state structure pLZ77State that must be previously initialized by the function ippsEncodeLZ77InitAlloc or ippsEncodeLZ77Init.

Return Values

ippStsNoErr

Indicates no error.

ippStsNullPtrErr

Indicates an error if one of the specified pointers is NULL.

ippStsSizeErr

Indicates an error if DstLen is less than or equal to 0.

ippStsDstSizeLessExpected

Indicates a warning that the size of the destination buffer is insufficient for completing the operation.

ippStsStreamEnd

Indicates a warning that the end of the stream occurs. The function returns this status if the parameter flush is set to IppLZ77FinishFlush.

Submit feedback on this help topic

Copyright © 2000 - 2011, Intel Corporation. All rights reserved.