Mercurial > libavcodec.hg
comparison tiff.c @ 4774:0860efc2f02b libavcodec
tiff encoder by (Bartlomiej Wolowiec b.wolowiec students mimuw edu pl)
author | michael |
---|---|
date | Tue, 03 Apr 2007 13:43:57 +0000 |
parents | 48952197d91f |
children | bca8924ed36c |
comparison
equal
deleted
inserted
replaced
4773:65ee324848ac | 4774:0860efc2f02b |
---|---|
22 #include "avcodec.h" | 22 #include "avcodec.h" |
23 #ifdef CONFIG_ZLIB | 23 #ifdef CONFIG_ZLIB |
24 #include <zlib.h> | 24 #include <zlib.h> |
25 #endif | 25 #endif |
26 #include "lzw.h" | 26 #include "lzw.h" |
27 | 27 #include "tiff.h" |
28 /* abridged list of TIFF tags */ | 28 |
29 enum TiffTags{ | |
30 TIFF_WIDTH = 0x100, | |
31 TIFF_HEIGHT, | |
32 TIFF_BPP, | |
33 TIFF_COMPR, | |
34 TIFF_INVERT = 0x106, | |
35 TIFF_STRIP_OFFS = 0x111, | |
36 TIFF_ROWSPERSTRIP = 0x116, | |
37 TIFF_STRIP_SIZE, | |
38 TIFF_PLANAR = 0x11C, | |
39 TIFF_XPOS = 0x11E, | |
40 TIFF_YPOS = 0x11F, | |
41 TIFF_PREDICTOR = 0x13D, | |
42 TIFF_PAL = 0x140 | |
43 }; | |
44 | |
45 enum TiffCompr{ | |
46 TIFF_RAW = 1, | |
47 TIFF_CCITT_RLE, | |
48 TIFF_G3, | |
49 TIFF_G4, | |
50 TIFF_LZW, | |
51 TIFF_JPEG, | |
52 TIFF_NEWJPEG, | |
53 TIFF_ADOBE_DEFLATE, | |
54 TIFF_PACKBITS = 0x8005, | |
55 TIFF_DEFLATE = 0x80B2 | |
56 }; | |
57 | |
58 enum TiffTypes{ | |
59 TIFF_BYTE = 1, | |
60 TIFF_STRING, | |
61 TIFF_SHORT, | |
62 TIFF_LONG, | |
63 TIFF_LONGLONG | |
64 }; | |
65 | |
66 /** sizes of various TIFF field types */ | |
67 static const int type_sizes[6] = { | |
68 0, 1, 100, 2, 4, 8 | |
69 }; | |
70 | 29 |
71 typedef struct TiffContext { | 30 typedef struct TiffContext { |
72 AVCodecContext *avctx; | 31 AVCodecContext *avctx; |
73 AVFrame picture; | 32 AVFrame picture; |
74 | 33 |