2 * original code: WDOSX-Pack v1.07, (c) 1999-2001 by Joergen Ibsen / Jibz
3 * for data and executable compression software: http://www.ibsensoftware.com/
15 #ifndef WDX_EXCLUDE_CRC
16 /* poly: 0xedb88320L: ISO 3309, ITU-T V.42 */
17 extern uint32_t wdxCRC32 (const void *src
, int len
) __attribute__((pure
));
20 #ifndef WDX_EXCLUDE_PACKER
22 * return -1 or size of the packed data
23 * uncompressible data may be expanded by up to 1 bit per byte:
24 * i.e. the destination should be length+((length+7)/8)+2 bytes
26 extern int wdxPack (void *dest
, int destSize
, const void *source
, int length
);
28 /* returs max size of the packed data with the given length */
29 extern int wdxPackBufferSize (int inSize
) __attribute__((const));
32 #ifndef WDX_EXCLUDE_UNPACKER
34 * return -1 or size of the unpacked data
36 extern int wdxUnpack (void *bufOut
, int outSize
, const void *bufIn
, int inSize
);