home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / SLAX 6.0.8 / slax-6.0.8.iso / slax / base / 006-devel.lzm / usr / include / lzo / lzo1f.h < prev    next >
Encoding:
C/C++ Source or Header  |  2007-06-09  |  3.4 KB  |  105 lines

  1. /* lzo1f.h -- public interface of the LZO1F compression algorithm
  2.  
  3.    This file is part of the LZO real-time data compression library.
  4.  
  5.    Copyright (C) 2005 Markus Franz Xaver Johannes Oberhumer
  6.    Copyright (C) 2004 Markus Franz Xaver Johannes Oberhumer
  7.    Copyright (C) 2003 Markus Franz Xaver Johannes Oberhumer
  8.    Copyright (C) 2002 Markus Franz Xaver Johannes Oberhumer
  9.    Copyright (C) 2001 Markus Franz Xaver Johannes Oberhumer
  10.    Copyright (C) 2000 Markus Franz Xaver Johannes Oberhumer
  11.    Copyright (C) 1999 Markus Franz Xaver Johannes Oberhumer
  12.    Copyright (C) 1998 Markus Franz Xaver Johannes Oberhumer
  13.    Copyright (C) 1997 Markus Franz Xaver Johannes Oberhumer
  14.    Copyright (C) 1996 Markus Franz Xaver Johannes Oberhumer
  15.    All Rights Reserved.
  16.  
  17.    The LZO library is free software; you can redistribute it and/or
  18.    modify it under the terms of the GNU General Public License,
  19.    version 2, as published by the Free Software Foundation.
  20.  
  21.    The LZO library is distributed in the hope that it will be useful,
  22.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  23.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  24.    GNU General Public License for more details.
  25.  
  26.    You should have received a copy of the GNU General Public License
  27.    along with the LZO library; see the file COPYING.
  28.    If not, write to the Free Software Foundation, Inc.,
  29.    51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  30.  
  31.    Markus F.X.J. Oberhumer
  32.    <markus@oberhumer.com>
  33.    http://www.oberhumer.com/opensource/lzo/
  34.  */
  35.  
  36.  
  37. #ifndef __LZO1F_H_INCLUDED
  38. #define __LZO1F_H_INCLUDED
  39.  
  40. #ifndef __LZOCONF_H_INCLUDED
  41. #include "lzoconf.h"
  42. #endif
  43.  
  44. #ifdef __cplusplus
  45. extern "C" {
  46. #endif
  47.  
  48.  
  49. /***********************************************************************
  50. //
  51. ************************************************************************/
  52.  
  53. /* Memory required for the wrkmem parameter.
  54.  * When the required size is 0, you can also pass a NULL pointer.
  55.  */
  56.  
  57. #define LZO1F_MEM_COMPRESS      ((lzo_uint32) (16384L * lzo_sizeof_dict_t))
  58. #define LZO1F_MEM_DECOMPRESS    (0)
  59.  
  60.  
  61. /* decompression */
  62. LZO_EXTERN(int)
  63. lzo1f_decompress        ( const lzo_bytep src, lzo_uint  src_len,
  64.                                 lzo_bytep dst, lzo_uintp dst_len,
  65.                                 lzo_voidp wrkmem /* NOT USED */ );
  66.  
  67. /* safe decompression with overrun testing */
  68. LZO_EXTERN(int)
  69. lzo1f_decompress_safe   ( const lzo_bytep src, lzo_uint  src_len,
  70.                                 lzo_bytep dst, lzo_uintp dst_len,
  71.                                 lzo_voidp wrkmem /* NOT USED */ );
  72.  
  73.  
  74. /***********************************************************************
  75. //
  76. ************************************************************************/
  77.  
  78. LZO_EXTERN(int)
  79. lzo1f_1_compress        ( const lzo_bytep src, lzo_uint  src_len,
  80.                                 lzo_bytep dst, lzo_uintp dst_len,
  81.                                 lzo_voidp wrkmem );
  82.  
  83.  
  84. /***********************************************************************
  85. // better compression ratio at the cost of more memory and time
  86. ************************************************************************/
  87.  
  88. #define LZO1F_999_MEM_COMPRESS  ((lzo_uint32) (5 * 16384L * sizeof(short)))
  89.  
  90. LZO_EXTERN(int)
  91. lzo1f_999_compress      ( const lzo_bytep src, lzo_uint  src_len,
  92.                                 lzo_bytep dst, lzo_uintp dst_len,
  93.                                 lzo_voidp wrkmem );
  94.  
  95.  
  96.  
  97. #ifdef __cplusplus
  98. } /* extern "C" */
  99. #endif
  100.  
  101. #endif /* already included */
  102.  
  103.  
  104. /* vim:set ts=4 et: */
  105.