nn::cx::CompressDeflate Function

Syntax

#include <nn/cx.h>

s32 CompressDeflate(
     void * pDst,
     size_t dstSize,
     const void * pSrc,
     size_t srcSize,
     void * pWork
);

Parameters

Name Description
out pDst Buffer where compressed data is written.
in dstSize Size of the buffer pointed to by pDst.
in pSrc Buffer storing the data to be compressed.
in srcSize Size of the data to be compressed.
in pWork Work buffer. It requires a region equal to DEFLATE_COMPRESS_WORK_SIZE bytes.

Return Values

When compression succeeds, returns the data size after compression. Returns an ErrorCode value if unsuccessful.

Description

Performs deflate compression appended to the cx common header.

You can use the GetCompressionType and GetUncompressedSize functions on data compressed with this function.

Data compressed with this function can be decompressed with the UncompressDeflate function.

Revision History

2012/05/17
Initial version.

CONFIDENTIAL