compress.h
来自「嵌入式系统中文件系统源代码」· C头文件 代码 · 共 52 行
H
52 行
/**************************************************************
;* *
;* INSTUTITE FOR INFORMATION INDUSTRY *
;* COMPRESSION HEADER -- RAMDISK 3.5 *
;* November 04, 1999 *
;* *
;*************************************************************/
#ifndef _COMPRESS_H
#define _COMPRESS_H
/*************************************************************
Function: rd_compress
Description:
compress the buffer
Input:
buffer - the data to be compressed
size - the size of data to be compressed
Output:
buffer - the compressed data
Return value:
the compressed data size
-1 if failed
Note:
Note that the original buffer contents are destroyed
after compression. Remember to set the buffer
information in the file handle to empty.
**************************************************************/
//long rd_compress_none(unsigned char *buffer, long size);
long rd_compress_zlib(unsigned char *buffer, long size);
/*************************************************************
Function: rd_uncompress
Description:
decompress a block to buffer
Input:
buffer - the data to be decompressed
size - the size of data to be decompressed
Output:
NONE
Return value:
the uncompressed data size
-1 if failed
**************************************************************/
//long rd_uncompress_none(struct diskBlock *block, unsigned char *buffer);
long rd_uncompress_zlib(struct diskBlock *block, unsigned char *buffer);
#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?