HashPack, HashUnpack
HashPack, HashUnpack
Packs/unpacks the
IppsHashState
or IppsHashState_rmf
context into/from a user-defined buffer.Syntax
IppStatus ippsHashPack (const IppsHashState*
pCtx
,
Ipp8u*
pBuffer
,
int
bufSize
);
IppStatus ippsHashPack_rmf(const IppsHashState_rmf*
pCtx
, Ipp8u*
pBuffer
, int
bufferSize
);
IppStatus ippsHashUnpack (const Ipp8u*
pBuffer
, IppsHashState*
pCtx
);
IppStatus ippsHashUnpack_rmf(const Ipp8u*
pBuffer
, IppsHashState_rmf*
pCtx
);
Include Files
ippcp.h
Parameters
- pCtx
- Pointer to theIppsHashStateorIppsHashState_rmfcontext.
- pBuffer
- Pointer to the user-defined buffer.
- bufSize,bufferSize
- The size of the user-defined buffer in bytes.
Description
The
HashPack
function transforms the *pCtx
context to a position-independent form and stores it in the the *pBuffer
buffer. The HashUnpack
function performs the inverse operation, that is, transforms the contents of the *pBuffer
buffer into a normal IppsHashState
or IppsHashState_rmf
context. The HashPack
and HashUnpack
functions enable replacing the position-dependent IppsHashState
or IppsHashState_rmf
context in the memory. The value of the
bufSize
parameter must be not less than the size of IppsHashState
or IppsHashState_rmf
context. Call the HashGetSize
function prior to HashPack
to determine the size of the buffer.This function has a
reduced memory footprint
version. To learn more, see Reduced Memory Footprint Functions.Return Values
- ippStsNoErr
- Indicates no error. Any other value indicates an error or warning.
- ippStsNullPtrErr
- Indicates an error condition if any of the specified pointers isNULL.
- ippStsMemErr
- Indicates an error condition if the value ofbufSizeis less than the size of theIppsHashStatecontext.
- ippStsContextMatchErr
- Indicates an error condition in aippsHashPack_rmfcall if the context parameter does not match the operation.
- ippStsNoMem
- Indicates an error condition if the value ofbufferSizeis less than the size of theIppsHashState_rmfcontext.