awips2/pythonPackages/pil/libImaging/Lzw.h
root 06a8b51d6d Initial revision of AWIPS2 11.9.0-7p5
Former-commit-id: 64fa9254b946eae7e61bbc3f513b7c3696c4f54f
2012-01-06 08:55:05 -06:00

52 lines
884 B
C

/*
* The Python Imaging Library.
* $Id: Lzw.h 2134 2004-10-06 08:55:20Z fredrik $
*
* declarations for the TIFF LZW decoder.
*
* Copyright (c) Fredrik Lundh 1995-96.
*/
/* Max size for LZW code words */
#define LZWBITS 12
#define LZWTABLE (1<<LZWBITS)
#define LZWBUFFER (1<<LZWBITS)
typedef struct {
/* CONFIGURATION */
/* Filter type */
int filter;
/* PRIVATE CONTEXT (set by decoder) */
/* Input bit buffer */
INT32 bitbuffer;
int bitcount;
/* Code buffer */
int codesize;
int codemask;
/* Constant symbol codes */
int clear, end;
/* Symbol history */
int lastcode;
unsigned char lastdata;
/* History buffer */
int bufferindex;
unsigned char buffer[LZWTABLE];
/* Symbol table */
unsigned INT16 link[LZWTABLE];
unsigned char data[LZWTABLE];
int next;
} LZWSTATE;