2012.03.15 17:54 "Re: [Tiff] RFC3949 TIFF-FX support", by Frank Warmerdam
Steve,
I would suggest submitting a patch via a ticket.
Can these fields be safely merged into the static TIFFField tiffFields[] array in tif_dirinfo.c? Are there any conflicts with normal definitions?
Are there sample files I can use for testing?
It seems we have had TIFF-FX discussions before and they went no where for some reason, but I don't recall any details.
Best regards,
Frank
On Thu, Mar 15, 2012 at 9:03 AM, Steve Underwood <steveu@coppice.org> wrote:
> Hi,
>
> RFC3949 defines additional TIFF tags to support the full featured > carriage of FAXes as TIFF files. I have been using the following
> definitions in my own software for a while, to extend libtiff to support > these flags. I Hope these additions can now go into the libtiff
> distribution, so they will be part of general TIFF support, and > utilities like tiffinfo will understand these tags.
>
> Regards,
> Steve
>
>
>
> #define TIFFTAG_INDEXED 346
> #define TIFFTAG_GLOBALPARAMETERSIFD 400
> #define TIFFTAG_PROFILETYPE 401
> #define PROFILETYPE_UNSPECIFIED 0
> #define PROFILETYPE_G3_FAX 1
> #define TIFFTAG_FAXPROFILE 402
> #define FAXPROFILE_S 1
> #define FAXPROFILE_F 2
> #define FAXPROFILE_J 3
> #define FAXPROFILE_C 4
> #define FAXPROFILE_L 5
> #define FAXPROFILE_M 6
> #define TIFFTAG_CODINGMETHODS 403
> #define CODINGMETHODS_T4_1D (1 << 1)
> #define CODINGMETHODS_T4_2D (1 << 2)
> #define CODINGMETHODS_T6 (1 << 3)
> #define CODINGMETHODS_T85 (1 << 4)
> #define CODINGMETHODS_T42 (1 << 5)
> #define CODINGMETHODS_T43 (1 << 6)
> #define TIFFTAG_VERSIONYEAR 404
> #define TIFFTAG_MODENUMBER 405
> #define TIFFTAG_DECODE 433
> #define TIFFTAG_IMAGEBASECOLOR 434
> #define TIFFTAG_T82OPTIONS 435
> #define TIFFTAG_STRIPROWCOUNTS 559
> #define TIFFTAG_IMAGELAYER 34732
>
> #define COMPRESSION_T85 9
> #define COMPRESSION_T43 10
>
>
> /* TIFF-FX related extensions to the tag set supported by libtiff */
> static const TIFFFieldInfo tiff_fx_tiff_field_info[] =
> {
> {TIFFTAG_INDEXED, 1, 1, TIFF_SHORT, FIELD_CUSTOM, FALSE, FALSE,
> (char *) "Indexed"},
> {TIFFTAG_GLOBALPARAMETERSIFD, 1, 1, TIFF_LONG, FIELD_CUSTOM, FALSE,
> FALSE, (char *) "GlobalParametersIFD"},
> {TIFFTAG_PROFILETYPE, 1, 1, TIFF_LONG, FIELD_CUSTOM, FALSE, FALSE,
> (char *) "ProfileType"},
> {TIFFTAG_FAXPROFILE, 1, 1, TIFF_BYTE, FIELD_CUSTOM, FALSE, FALSE,
> (char *) "FaxProfile"},
> {TIFFTAG_CODINGMETHODS, 1, 1, TIFF_LONG, FIELD_CUSTOM, FALSE,
> FALSE, (char *) "CodingMethods"},
> {TIFFTAG_VERSIONYEAR, 4, 4, TIFF_BYTE, FIELD_CUSTOM, FALSE, FALSE,
> (char *) "VersionYear"},
> {TIFFTAG_MODENUMBER, 1, 1, TIFF_BYTE, FIELD_CUSTOM, FALSE, FALSE,
> (char *) "ModeNumber"},
> {TIFFTAG_DECODE, TIFF_VARIABLE, TIFF_VARIABLE, TIFF_SRATIONAL,
> FIELD_CUSTOM, FALSE, FALSE, (char *) "Decode"},
> {TIFFTAG_IMAGEBASECOLOR, TIFF_SPP, TIFF_SPP, TIFF_SHORT,
> FIELD_CUSTOM, FALSE, FALSE, (char *) "ImageBaseColor"},
> {TIFFTAG_T82OPTIONS, 1, 1, TIFF_LONG, FIELD_CUSTOM, FALSE, FALSE,
> (char *) "T82Options"},
> {TIFFTAG_STRIPROWCOUNTS, TIFF_VARIABLE, TIFF_VARIABLE, TIFF_LONG, > FIELD_CUSTOM, FALSE, TRUE, (char *) "StripRowCounts"},
> {TIFFTAG_IMAGELAYER, 2, 2, TIF