123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162 |
- tiff2png
- ========
- Converts a Tagged Image File Format (TIFF) file into a
- Portable Network Graphics (PNG) file.
- 5 November 2014 - version 0.92:
- Add zlib.h include, which is no longer supplied by png.h.
- Remove non-default compile-time configurations. Fixed various warnings.
- Rewrote makefile and documentation to match modern conventions.
- Removed the static target. The build now requires GNU make.
- 12 September 2002 - version 0.91:
- No merge or version 1.0 yet, but two fixes: correct scaling for sub-8-bps
- RGB and RGBA, and correct big- and little-endian support for 16-bps images.
- (Many thanks to Rhett Sutphin for providing test images and quick feedback
- on both big- and little-endian machines!)
- I also documented a couple more potential gotchas that I can't test at the
- moment: lack of MINISWHITE support for RGB and RGBA, and lack of support
- for non-contiguous (separated-plane) tiled images. I suspect both are
- valid according to the TIFF spec (what isn't...), but I haven't verified
- this.
- (Btw, 1.0 and the final merge will still happen as soon as time permits.)
- 1 July 2002 - version 0.9:
- Willem has passed the maintainership of his fine utility to me, and this
- release merely incorporates a bunch of saved-up patches, mostly from other
- folks. Frank A. Palmieri added support for tiled TIFFs (contiguous only);
- TenThumbs (SJT) added auto-detection of 8-bit color data in 16-bit palettes
- (which _appears_ to be a long-standing bug in a number of TIFFs, including
- some immense geophysical ones from the US NOAA); Nelson Beebe pointed out
- a number of C++ comments, which aren't accepted by some C compilers; and I
- added support for wildcards under emx+gcc and added some more checks for
- out-of-memory conditions. I also updated much of this README to be a little
- more coherent. (No, less schizophrenic! No, more coherent! ;-) )
- Version 1.0 should be the next release, hopefully soon, and it will finally
- merge the rest of Willem's 0.82 changes. (That said, this utility has been
- quite stable for quite a few years already, so it can already be considered
- "post-1.0" in all but name...er, number.)
- 12 November 2000 - version 0.81c:
- Oops, I overlooked one of Willem's 16-bit changes, and both of us missed an
- earlier, critical bug in the 16-bit code. Thanks to some 16-bit grayscale
- test images supplied by Ron Emaus of Pfizer, I was able to do a bit of real
- testing and track down the latter problem; version 0.81c fixes all known
- 16-bit bugs (although I still don't have any big-endian test files). It
- also includes Willem's -invert option, support for YCbCr images with JPEG
- compression and for Log(L) images with SGILog compression, and a new Win32
- makefile (tested with MSVC 5.0, libtiff 3.5.5, libjpeg 6b, libpng 1.0.8,
- and zlib 1.1.3).
- 4 November 2000 - version 0.81b:
- Willem released a version 0.82 in July, but it doesn't include the changes
- from either 0.8 or 0.81 (see above). In particular, it still expects both
- an input name and an output name on the command line, and it doesn't check
- whether the output file exists before overwriting it, which is quite dan-
- gerous for those of us who have grown accustomed to typing "tiff2png *.tiff"
- under Unix. (In such a case, the second TIFF file would be overwritten
- with the PNG conversion of the first TIFF file.) Willem's version can be
- found at http://www.schaik.com/png/tiff2png.html, for those who want to
- try it anyway.
- In the meantime, back in September I made a version 0.81b with the following
- two bug fixes:
- - fixed 16-bit-per-sample support (copied from Willem's version 0.82)
- - fixed Makefile (no attempt to install non-existent man page)
- Presumably Willem will reintegrate his other changes (e.g., -invert option
- and contributed multipage support) at some point in the near future.
- 5 August 2000:
- Willem is back and will be taking over maintenance of tiff2png once
- again! (Also, tiff2png URL corrected above.)
- 13 February 2000 - version 0.81:
- Version 0.81 consists only of fixes/improvements to the -destdir option;
- now if no target directory is given, the current directory is assumed.
- Thanks to TenThumbs once again.
- (Well, I also fixed a compiler warning and made a minor modification to
- the makefile, but you get the general idea.)
- 26 January 2000 - version 0.8:
- I updated tiff2png 0.7 to version 0.8 in January 2000 and tested it
- with libpng 3.5.4. Changes include:
- - improved Makefile (thanks to tenthumbs@cybernex.net)
- - improved memory/resource management (TIFFClose(), fclose(), etc.)
- - added -compression option to set zlib compression level
- - added multi-file support, including -destdir option
- The last item breaks command-line compatibility with earlier versions
- (which required exactly one TIFF input name and one PNG output name),
- but it brings tiff2png more in line with gif2png--that is, you can now
- do "tiff2png *.tif *.tiff" and get the expected conversion of many TIFF
- files all at once. (Alternatively, you can do "tiff2png -destdir /here
- /there/*.tif" to convert TIFFs /there to PNGs /here. The destination
- directory must exist and be writable, of course.) The program replaces
- the ".tif" or ".tiff" extension with ".png"; if neither extension is
- found, ".png" is simply appended to the TIFF filename.
- Oh, and I also took the liberty of changing the capitalization to
- "tiff2png"; not only does that match both the actual binary name and
- gif2png's convention, it also seemed more logical. (That is, "TIFF"
- is an acronym; either all letters should be capitalized or none of them
- should be. Ditto for PNG.)
- 16 September 1999 - version 0.7:
- I updated tiff2png 0.6 of May 1996 to version 0.7 in July 1999. My
- changes include the following:
- - slightly generalized Makefile, including static-library build
- - updated libpng interface
- - new libpng error handler (avoids jmp_buf size mismatches between
- library and application)
- - new usage() function
- - PNG pHYs support (aspect ratio, resolution)
- - optional new -faxpect option (only if compiled with FAXPECT defined)
- The last item is somewhat special-purpose, which is why it's ifdef'd. At
- least in my tests with efax 0.9, a Supra fax modem, and the various fax
- machines to which I have access at work (including all of their "fineness"
- options), *all* incoming faxes arrive with doubled horizontal resolution.
- With -faxpect, tiff2png will detect if the aspect ratio is close to 2:1
- and, if so, halve the horizontal resolution to give a near-1:1 aspect
- ratio. The algorithm is trivial: if both neighboring pixels are white,
- the result pixel is white; if both black, black; and if there's one of
- each, the result is mid-level gray (127). (This necessarily means the
- output file is 2-bit palette-based, not grayscale, since only 8-bit PNG
- grayscale includes the mid-level gray, and compression can't recover the
- factor-of-four increase in pixel depth.) The results look pretty decent.
- Also note that even libtiff 3.4beta028 needs the OLDTIFF macro defined
- (see the Makefile comments), at least in all the cases I was able to test.
- I don't know what the difference is between my system and Willem's.
- Finally, I've removed the (very) old libtiff from the tiff2png 0.7 tar
- distribution; newer versions are available from the SGI web site mentioned
- above (ftp://ftp.sgi.com/graphics/tiff/).
|