From Solid Graphics Wiki

Jump to: navigation, search
Namespace: SKL
Member of: (this function is not member of any class)
Include: SklCompress.h
Lib (Release): SKL.lib
Lib (Debug): SKL_D.lib

The DecompressData uncompresses chunk of binary data in memory.

bool DecompressData
         const void* srcBuffer,
         void* dstBuffer,
         unsigned int* dstBufferSize


srcBuffer Pointer to data previously compressed by the CompressData function.
dstBuffer After the DecompressData function returns the memory buffer pointed by dstBuffer will contain the uncompressed data.
dstBufferSize Before calling the DecompressData function the variable pointed by dstBufferSize must be set to size/capacity of the dstBuffer in bytes. The dstBuffer must be allocated to at least the decompressedDataSize parameter value returned by the GetCompressedDataInfo using the srcBuffer as parameter. After the DecompressData function returns the variable pointed by dstBufferSize will be set to number of bytes written into the dstBuffer.

Return Value

The function returns true in case of success, in case of error it returns false and the content of variables pointed by dstBuffer and dstBufferSize is undefined.

See Also


SolidKit Library Documentation

Personal tools