• Main Page
  • Related Pages
  • Modules
  • Data Structures
  • Files
  • File List
  • Globals

libavcodec/lzw.h

Go to the documentation of this file.
00001 /*
00002  * LZW decoder
00003  * Copyright (c) 2003 Fabrice Bellard
00004  * Copyright (c) 2006 Konstantin Shishkov
00005  *
00006  * This file is part of FFmpeg.
00007  *
00008  * FFmpeg is free software; you can redistribute it and/or
00009  * modify it under the terms of the GNU Lesser General Public
00010  * License as published by the Free Software Foundation; either
00011  * version 2.1 of the License, or (at your option) any later version.
00012  *
00013  * FFmpeg is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00016  * Lesser General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU Lesser General Public
00019  * License along with FFmpeg; if not, write to the Free Software
00020  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
00021  */
00022 
00030 #ifndef AVCODEC_LZW_H
00031 #define AVCODEC_LZW_H
00032 
00033 #include "bitstream.h"
00034 
00035 enum FF_LZW_MODES{
00036     FF_LZW_GIF,
00037     FF_LZW_TIFF
00038 };
00039 
00040 /* clients should not know what LZWState is */
00041 typedef void LZWState;
00042 
00043 /* first two functions de/allocate memory for LZWState */
00044 void ff_lzw_decode_open(LZWState **p);
00045 void ff_lzw_decode_close(LZWState **p);
00046 int ff_lzw_decode_init(LZWState *s, int csize, const uint8_t *buf, int buf_size, int mode);
00047 int ff_lzw_decode(LZWState *s, uint8_t *buf, int len);
00048 const uint8_t* ff_lzw_cur_ptr(LZWState *lzw);
00049 void ff_lzw_decode_tail(LZWState *lzw);
00050 
00052 struct LZWEncodeState;
00053 extern const int ff_lzw_encode_state_size;
00054 
00055 void ff_lzw_encode_init(struct LZWEncodeState * s, uint8_t * outbuf, int outsize, int maxbits);
00056 int ff_lzw_encode(struct LZWEncodeState * s, const uint8_t * inbuf, int insize);
00057 int ff_lzw_encode_flush(struct LZWEncodeState * s);
00058 
00059 #endif /* AVCODEC_LZW_H */

Generated on Tue Nov 4 2014 12:59:22 for ffmpeg by  doxygen 1.7.1