├── .travis.yml ├── CMakeLists.txt ├── COPYRIGHT ├── ChangeLog ├── HOWTO-RELEASE ├── Makefile.am ├── Makefile.in ├── Makefile.vc ├── README ├── RELEASE-DATE ├── SConstruct ├── TODO ├── VERSION ├── aclocal.m4 ├── autogen.sh ├── cmake └── dist.cmake ├── config ├── compile ├── config.guess ├── config.sub ├── depcomp ├── install-sh ├── ltmain.sh ├── missing └── mkinstalldirs ├── configure ├── configure.ac ├── contrib ├── Makefile.am ├── Makefile.in ├── README ├── acorn │ ├── Makefile.acorn │ ├── Makefile.am │ ├── Makefile.in │ ├── ReadMe │ ├── SetVars │ ├── cleanlib │ ├── convert │ └── install ├── addtiffo │ ├── Makefile.am │ ├── Makefile.in │ ├── Makefile.vc │ ├── README │ ├── addtiffo.c │ ├── tif_overview.c │ ├── tif_ovrcache.c │ └── tif_ovrcache.h ├── dbs │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ ├── tiff-bi.c │ ├── tiff-grayscale.c │ ├── tiff-palette.c │ ├── tiff-rgb.c │ └── xtiff │ │ ├── Imakefile │ │ ├── Makefile.am │ │ ├── Makefile.in │ │ ├── README │ │ ├── patchlevel.h │ │ ├── xtiff.c │ │ └── xtifficon.h ├── iptcutil │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ ├── iptcutil.c │ ├── test.iptc │ └── test.txt ├── mac-cw │ ├── Makefile.am │ ├── Makefile.in │ ├── Makefile.script │ ├── README │ ├── mac_main.c │ ├── mac_main.h │ ├── metrowerks.note │ ├── mkg3_main.c │ └── version.h ├── mac-mpw │ ├── BUILD.mpw │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ ├── libtiff.make │ ├── mactrans.c │ ├── port.make │ ├── tools.make │ └── top.make ├── mfs │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ └── mfs_file.c ├── ojpeg │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ └── jdhuff_add.c ├── pds │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ ├── tif_imageiter.c │ ├── tif_imageiter.h │ ├── tif_pdsdirread.c │ └── tif_pdsdirwrite.c ├── ras │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ ├── ras2tif.c │ └── tif2ras.c ├── stream │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ ├── tiffstream.cpp │ └── tiffstream.h ├── tags │ ├── Makefile.am │ ├── Makefile.in │ ├── README │ ├── listtif.c │ ├── maketif.c │ ├── xtif_dir.c │ ├── xtiffio.h │ └── xtiffiop.h └── win_dib │ ├── Makefile.am │ ├── Makefile.in │ ├── Makefile.w95 │ ├── README.Tiffile │ ├── README.tiff2dib │ ├── Tiffile.cpp │ └── tiff2dib.c ├── dist.info ├── html ├── Makefile.am ├── Makefile.in ├── TIFFTechNote2.html ├── addingtags.html ├── bugs.html ├── build.html ├── contrib.html ├── document.html ├── images.html ├── images │ ├── Makefile.am │ ├── Makefile.in │ ├── back.gif │ ├── bali.jpg │ ├── cat.gif │ ├── cover.jpg │ ├── cramps.gif │ ├── dave.gif │ ├── info.gif │ ├── jello.jpg │ ├── jim.gif │ ├── note.gif │ ├── oxford.gif │ ├── quad.jpg │ ├── ring.gif │ ├── smallliz.jpg │ ├── strike.gif │ └── warning.gif ├── index.html ├── internals.html ├── intro.html ├── libtiff.html ├── man │ ├── Makefile.am │ ├── Makefile.in │ ├── TIFFClose.3tiff.html │ ├── TIFFDataWidth.3tiff.html │ ├── TIFFError.3tiff.html │ ├── TIFFFlush.3tiff.html │ ├── TIFFGetField.3tiff.html │ ├── TIFFOpen.3tiff.html │ ├── TIFFPrintDirectory.3tiff.html │ ├── TIFFRGBAImage.3tiff.html │ ├── TIFFReadDirectory.3tiff.html │ ├── TIFFReadEncodedStrip.3tiff.html │ ├── TIFFReadEncodedTile.3tiff.html │ ├── TIFFReadRGBAImage.3tiff.html │ ├── TIFFReadRGBAStrip.3tiff.html │ ├── TIFFReadRGBATile.3tiff.html │ ├── TIFFReadRawStrip.3tiff.html │ ├── TIFFReadRawTile.3tiff.html │ ├── TIFFReadScanline.3tiff.html │ ├── TIFFReadTile.3tiff.html │ ├── TIFFSetDirectory.3tiff.html │ ├── TIFFSetField.3tiff.html │ ├── TIFFWarning.3tiff.html │ ├── TIFFWriteDirectory.3tiff.html │ ├── TIFFWriteEncodedStrip.3tiff.html │ ├── TIFFWriteEncodedTile.3tiff.html │ ├── TIFFWriteRawStrip.3tiff.html │ ├── TIFFWriteRawTile.3tiff.html │ ├── TIFFWriteScanline.3tiff.html │ ├── TIFFWriteTile.3tiff.html │ ├── TIFFbuffer.3tiff.html │ ├── TIFFcodec.3tiff.html │ ├── TIFFcolor.3tiff.html │ ├── TIFFmemory.3tiff.html │ ├── TIFFquery.3tiff.html │ ├── TIFFsize.3tiff.html │ ├── TIFFstrip.3tiff.html │ ├── TIFFswab.3tiff.html │ ├── TIFFtile.3tiff.html │ ├── fax2ps.1.html │ ├── fax2tiff.1.html │ ├── gif2tiff.1.html │ ├── index.html │ ├── libtiff.3tiff.html │ ├── pal2rgb.1.html │ ├── ppm2tiff.1.html │ ├── ras2tiff.1.html │ ├── raw2tiff.1.html │ ├── rgb2ycbcr.1.html │ ├── sgi2tiff.1.html │ ├── thumbnail.1.html │ ├── tiff2bw.1.html │ ├── tiff2pdf.1.html │ ├── tiff2ps.1.html │ ├── tiff2rgba.1.html │ ├── tiffcmp.1.html │ ├── tiffcp.1.html │ ├── tiffdither.1.html │ ├── tiffdump.1.html │ ├── tiffgt.1.html │ ├── tiffinfo.1.html │ ├── tiffmedian.1.html │ ├── tiffset.1.html │ ├── tiffsplit.1.html │ └── tiffsv.1.html ├── misc.html ├── support.html ├── tools.html ├── v3.4beta007.html ├── v3.4beta016.html ├── v3.4beta018.html ├── v3.4beta024.html ├── v3.4beta028.html ├── v3.4beta029.html ├── v3.4beta031.html ├── v3.4beta032.html ├── v3.4beta033.html ├── v3.4beta034.html ├── v3.4beta035.html ├── v3.4beta036.html ├── v3.5.1.html ├── v3.5.2.html ├── v3.5.3.html ├── v3.5.4.html ├── v3.5.5.html ├── v3.5.6-beta.html ├── v3.5.7.html ├── v3.6.0.html ├── v3.6.1.html ├── v3.7.0.html ├── v3.7.0alpha.html ├── v3.7.0beta.html ├── v3.7.0beta2.html ├── v3.7.1.html ├── v3.7.2.html ├── v3.7.3.html ├── v3.7.4.html ├── v3.8.0.html ├── v3.8.1.html └── v3.8.2.html ├── libtiff ├── Makefile.am ├── Makefile.in ├── Makefile.vc ├── SConstruct ├── libtiff.def ├── mkg3states.c ├── t4.h ├── tif_acorn.c ├── tif_apple.c ├── tif_atari.c ├── tif_aux.c ├── tif_close.c ├── tif_codec.c ├── tif_color.c ├── tif_compress.c ├── tif_config.h.cmake ├── tif_config.h.in ├── tif_config.h.vc ├── tif_dir.c ├── tif_dir.h ├── tif_dirinfo.c ├── tif_dirread.c ├── tif_dirwrite.c ├── tif_dumpmode.c ├── tif_error.c ├── tif_extension.c ├── tif_fax3.c ├── tif_fax3.h ├── tif_fax3sm.c ├── tif_flush.c ├── tif_getimage.c ├── tif_jpeg.c ├── tif_luv.c ├── tif_lzw.c ├── tif_msdos.c ├── tif_next.c ├── tif_ojpeg.c ├── tif_open.c ├── tif_packbits.c ├── tif_pixarlog.c ├── tif_predict.c ├── tif_predict.h ├── tif_print.c ├── tif_read.c ├── tif_stream.cxx ├── tif_strip.c ├── tif_swab.c ├── tif_thunder.c ├── tif_tile.c ├── tif_unix.c ├── tif_version.c ├── tif_warning.c ├── tif_win3.c ├── tif_win32.c ├── tif_write.c ├── tif_zip.c ├── tiff.h ├── tiffconf.h.cmake ├── tiffconf.h.in ├── tiffconf.h.vc ├── tiffio.h ├── tiffio.hxx ├── tiffiop.h ├── tiffvers.h └── uvcode.h ├── m4 ├── acinclude.m4 ├── libtool.m4 ├── ltoptions.m4 ├── ltsugar.m4 └── ltversion.m4 ├── man ├── Makefile.am ├── Makefile.in ├── TIFFClose.3tiff ├── TIFFDataWidth.3tiff ├── TIFFError.3tiff ├── TIFFFlush.3tiff ├── TIFFGetField.3tiff ├── TIFFOpen.3tiff ├── TIFFPrintDirectory.3tiff ├── TIFFRGBAImage.3tiff ├── TIFFReadDirectory.3tiff ├── TIFFReadEncodedStrip.3tiff ├── TIFFReadEncodedTile.3tiff ├── TIFFReadRGBAImage.3tiff ├── TIFFReadRGBAStrip.3tiff ├── TIFFReadRGBATile.3tiff ├── TIFFReadRawStrip.3tiff ├── TIFFReadRawTile.3tiff ├── TIFFReadScanline.3tiff ├── TIFFReadTile.3tiff ├── TIFFSetDirectory.3tiff ├── TIFFSetField.3tiff ├── TIFFWarning.3tiff ├── TIFFWriteDirectory.3tiff ├── TIFFWriteEncodedStrip.3tiff ├── TIFFWriteEncodedTile.3tiff ├── TIFFWriteRawStrip.3tiff ├── TIFFWriteRawTile.3tiff ├── TIFFWriteScanline.3tiff ├── TIFFWriteTile.3tiff ├── TIFFbuffer.3tiff ├── TIFFcodec.3tiff ├── TIFFcolor.3tiff ├── TIFFmemory.3tiff ├── TIFFquery.3tiff ├── TIFFsize.3tiff ├── TIFFstrip.3tiff ├── TIFFswab.3tiff ├── TIFFtile.3tiff ├── bmp2tiff.1 ├── fax2ps.1 ├── fax2tiff.1 ├── gif2tiff.1 ├── libtiff.3tiff ├── pal2rgb.1 ├── ppm2tiff.1 ├── ras2tiff.1 ├── raw2tiff.1 ├── rgb2ycbcr.1 ├── sgi2tiff.1 ├── thumbnail.1 ├── tiff2bw.1 ├── tiff2pdf.1 ├── tiff2ps.1 ├── tiff2rgba.1 ├── tiffcmp.1 ├── tiffcp.1 ├── tiffdither.1 ├── tiffdump.1 ├── tiffgt.1 ├── tiffinfo.1 ├── tiffmedian.1 ├── tiffset.1 ├── tiffsplit.1 └── tiffsv.1 ├── nmake.opt ├── port ├── Makefile.am ├── Makefile.in ├── Makefile.vc ├── dummy.c ├── getopt.c ├── lfind.c ├── strcasecmp.c └── strtoul.c ├── test ├── Makefile.am ├── Makefile.in ├── ascii_tag.c ├── check_tag.c ├── long_tag.c ├── short_tag.c ├── strip.c ├── strip_rw.c ├── test_arrays.c └── test_arrays.h └── tools ├── Makefile.am ├── Makefile.in ├── Makefile.vc ├── bmp2tiff.c ├── fax2ps.c ├── fax2tiff.c ├── gif2tiff.c ├── pal2rgb.c ├── ppm2tiff.c ├── ras2tiff.c ├── rasterfile.h ├── raw2tiff.c ├── rgb2ycbcr.c ├── sgi2tiff.c ├── sgisv.c ├── thumbnail.c ├── tiff2bw.c ├── tiff2pdf.c ├── tiff2ps.c ├── tiff2rgba.c ├── tiffcmp.c ├── tiffcp.c ├── tiffdither.c ├── tiffdump.c ├── tiffgt.c ├── tiffinfo.c ├── tiffmedian.c ├── tiffset.c ├── tiffsplit.c └── ycbcr.c /.travis.yml: -------------------------------------------------------------------------------- 1 | # 2 | # LuaDist Travis-CI Hook 3 | # 4 | 5 | # We assume C build environments 6 | language: C 7 | 8 | # Try using multiple Lua Implementations 9 | env: 10 | - TOOL="gcc" # Use native compiler (GCC usually) 11 | - TOOL="clang" # Use clang 12 | - TOOL="i686-w64-mingw32" # 32bit MinGW 13 | - TOOL="x86_64-w64-mingw32" # 64bit MinGW 14 | - TOOL="arm-linux-gnueabihf" # ARM hard-float (hf), linux 15 | 16 | # Crosscompile builds may fail 17 | matrix: 18 | allow_failures: 19 | - env: TOOL="i686-w64-mingw32" 20 | - env: TOOL="x86_64-w64-mingw32" 21 | - env: TOOL="arm-linux-gnueabihf" 22 | 23 | # Install dependencies 24 | install: 25 | - git clone git://github.com/LuaDist/Tools.git ~/_tools 26 | - ~/_tools/travis/travis install 27 | 28 | # Bootstap 29 | before_script: 30 | - ~/_tools/travis/travis bootstrap 31 | 32 | # Build the module 33 | script: 34 | - ~/_tools/travis/travis build 35 | 36 | # Execute additional tests or commands 37 | after_script: 38 | - ~/_tools/travis/travis test 39 | 40 | # Only watch the master branch 41 | branches: 42 | only: 43 | - master 44 | 45 | # Notify the LuaDist Dev group if needed 46 | notifications: 47 | recipients: 48 | - luadist-dev@googlegroups.com 49 | email: 50 | on_success: change 51 | on_failure: always 52 | -------------------------------------------------------------------------------- /COPYRIGHT: -------------------------------------------------------------------------------- 1 | Copyright (c) 1988-1997 Sam Leffler 2 | Copyright (c) 1991-1997 Silicon Graphics, Inc. 3 | 4 | Permission to use, copy, modify, distribute, and sell this software and 5 | its documentation for any purpose is hereby granted without fee, provided 6 | that (i) the above copyright notices and this permission notice appear in 7 | all copies of the software and related documentation, and (ii) the names of 8 | Sam Leffler and Silicon Graphics may not be used in any advertising or 9 | publicity relating to the software without the specific, prior written 10 | permission of Sam Leffler and Silicon Graphics. 11 | 12 | THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 13 | EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 14 | WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 15 | 16 | IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 17 | ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 18 | OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 19 | WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 20 | LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 21 | OF THIS SOFTWARE. 22 | -------------------------------------------------------------------------------- /HOWTO-RELEASE: -------------------------------------------------------------------------------- 1 | HOWTO-RELEASE: 2 | 3 | Notes on releasing. You will need appropriate autoconf, automake and libtool 4 | utilities to release a package. 5 | 6 | 1. Commit any unsaved changes. 7 | 8 | 2. "make clean" 9 | 10 | 3. Create html/vX.X.html. Take ChangeLog entries and html-ify in there. 11 | Easist thing to do is take html/vX.(X-1).html and use it as a template. 12 | Add that file to the list of EXTRA_DIST files in the html/Makefile.am. 13 | 14 | 3.5. Update html/index.html to refer to this new page as the current release. 15 | 16 | 4. Increment version in configure.ac. Put 'alpha' or 'beta' after 17 | the version, if applicable. 18 | 19 | eg. 20 | 3.5.7 21 | or 22 | 3.5.8beta 23 | 24 | Version should be updated in two places: in the second argument of the 25 | AC_INIT macro and in LIBTIFF_xxx_VERSION variables. 26 | 27 | 5. autoconf 28 | 29 | 6. sh configure 30 | 31 | 7. make release -- this will update "RELEASE-DATE" and "VERSION" in the top 32 | level dir, and libtiff/tiffvers.h. 33 | 34 | 8. Please verify that the version info in RELEASE-DATE, VERSION and 35 | libtiff/tiffvers.h is right. 36 | 37 | 9. make; make distcheck (to test). 38 | 39 | 10. make distclean 40 | 41 | 11. cvs commit 42 | 43 | 12. cvs tag Release-v3-5-7 (or the appropriate name for the release) 44 | 45 | 13. configure; make dist 46 | Two files with names tiff-version.tar.gz and tiff-version.zip will 47 | be created in the top level package directory. 48 | 49 | 14. Copy to ftp.remotesensing.org ftp site. 50 | scp tiff-*.tar.gz ftp.remotesensing.org:/var/ftp/libtiff/ 51 | scp tiff-*.zip ftp.remotesensing.org:/var/ftp/libtiff/ 52 | 53 | 15. Announce to list, tiff@lists.maptools.org 54 | 55 | 16. Update libtiff page on freshmeat with new version announcement. 56 | 57 | 58 | -------------------------------------------------------------------------------- /Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | docdir = $(LIBTIFF_DOCDIR) 27 | 28 | AUTOMAKE_OPTIONS = dist-zip foreign 29 | ACLOCAL_AMFLAGS = -I ./m4 30 | 31 | docfiles = \ 32 | COPYRIGHT \ 33 | ChangeLog \ 34 | README \ 35 | RELEASE-DATE \ 36 | TODO \ 37 | VERSION 38 | 39 | EXTRA_DIST = \ 40 | HOWTO-RELEASE \ 41 | Makefile.vc \ 42 | SConstruct \ 43 | autogen.sh \ 44 | nmake.opt 45 | 46 | dist_doc_DATA = $(docfiles) 47 | 48 | SUBDIRS = port libtiff tools contrib test man html 49 | 50 | release: 51 | (rm -f RELEASE-DATE && echo $(LIBTIFF_RELEASE_DATE) > RELEASE-DATE) 52 | (rm -f VERSION && echo $(LIBTIFF_VERSION) > VERSION) 53 | (rm -f ./libtiff/tiffvers.h && sed 's,LIBTIFF_VERSION,$(LIBTIFF_VERSION),;s,LIBTIFF_RELEASE_DATE,$(LIBTIFF_RELEASE_DATE),' ./libtiff/tiffvers.h.in > ./libtiff/tiffvers.h) 54 | 55 | -------------------------------------------------------------------------------- /Makefile.vc: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.vc,v 1.5 2006/03/23 14:54:00 dron Exp $ 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | # 24 | # Makefile for MS Visual C and Watcom C compilers. 25 | # Edit nmake.opt file if you want to ajust building options. 26 | # 27 | # To build: 28 | # C:\libtiff> nmake /f makefile.vc 29 | 30 | !INCLUDE nmake.opt 31 | 32 | all: port lib tools 33 | 34 | port:: 35 | cd port 36 | $(MAKE) /f Makefile.vc 37 | cd.. 38 | 39 | lib: port 40 | cd libtiff 41 | $(MAKE) /f Makefile.vc 42 | cd.. 43 | 44 | tools: lib 45 | cd tools 46 | $(MAKE) /f Makefile.vc 47 | cd .. 48 | 49 | clean: 50 | cd port 51 | $(MAKE) /f Makefile.vc clean 52 | cd.. 53 | cd libtiff 54 | $(MAKE) /f Makefile.vc clean 55 | cd.. 56 | cd tools 57 | $(MAKE) /f Makefile.vc clean 58 | cd .. 59 | 60 | -------------------------------------------------------------------------------- /README: -------------------------------------------------------------------------------- 1 | $Header: /cvs/maptools/cvsroot/libtiff/README,v 1.5 2004/10/30 13:44:45 dron Exp $ 2 | 3 | 4 | TIFF Software Distribution 5 | -------------------------- 6 | This file is just a placeholder; all the documentation is now in 7 | HTML in the html directory. To view the documentation point your 8 | favorite WWW viewer at html/index.html; e.g. 9 | 10 | netscape html/index.html 11 | 12 | If you don't have an HTML viewer then you can read the HTML source 13 | or fetch a PostScript version of this documentation from the directory 14 | 15 | ftp://ftp.remotesensing.org/pub/libtiff/ 16 | 17 | If you can't hack either of these options then basically what you 18 | want to do is: 19 | 20 | % ./configure 21 | % make 22 | % su 23 | # make install 24 | 25 | More information, email contacts, and mailing list information can be 26 | found online at http://www.remotesensing.org/libtiff/. 27 | 28 | 29 | Use and Copyright 30 | ----------------- 31 | Silicon Graphics has seen fit to allow us to give this work away. It 32 | is free. There is no support or guarantee of any sort as to its 33 | operations, correctness, or whatever. If you do anything useful with 34 | all or parts of it you need to honor the copyright notices. I would 35 | also be interested in knowing about it and, hopefully, be acknowledged. 36 | 37 | The legal way of saying that is: 38 | 39 | Copyright (c) 1988-1997 Sam Leffler 40 | Copyright (c) 1991-1997 Silicon Graphics, Inc. 41 | 42 | Permission to use, copy, modify, distribute, and sell this software and 43 | its documentation for any purpose is hereby granted without fee, provided 44 | that (i) the above copyright notices and this permission notice appear in 45 | all copies of the software and related documentation, and (ii) the names of 46 | Sam Leffler and Silicon Graphics may not be used in any advertising or 47 | publicity relating to the software without the specific, prior written 48 | permission of Sam Leffler and Silicon Graphics. 49 | 50 | THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 51 | EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 52 | WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 53 | 54 | IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 55 | ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 56 | OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 57 | WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 58 | LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 59 | OF THIS SOFTWARE. 60 | -------------------------------------------------------------------------------- /RELEASE-DATE: -------------------------------------------------------------------------------- 1 | 20060323 2 | -------------------------------------------------------------------------------- /TODO: -------------------------------------------------------------------------------- 1 | # $Header: /cvs/maptools/cvsroot/libtiff/TODO,v 1.6 2002/10/10 05:28:43 warmerda Exp $ 2 | 3 | o gif2tiff segaulting on selected images 4 | o tiffcmp read data by strip/tile instead of scanline 5 | o YCbCr sampling support 6 | o extracate colorspace conversion support 7 | o look at isolating all codecs from TIFF library 8 | o JPEG colormode order dependency problem 9 | o Write documentation on how do extend tags, and how the custom field 10 | stuff all works. 11 | 12 | 13 | -------------------------------------------------------------------------------- /VERSION: -------------------------------------------------------------------------------- 1 | 3.8.2 2 | -------------------------------------------------------------------------------- /autogen.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -x 3 | #libtoolize --force --copy 4 | aclocal -I ./m4 5 | autoheader 6 | automake --foreign --add-missing --copy 7 | autoconf 8 | 9 | -------------------------------------------------------------------------------- /contrib/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README 27 | 28 | SUBDIRS = acorn addtiffo dbs iptcutil mac-cw mac-mpw mfs ojpeg pds ras stream tags win_dib 29 | 30 | -------------------------------------------------------------------------------- /contrib/README: -------------------------------------------------------------------------------- 1 | This directory contains various contributions from libtiff users. 2 | 3 | -------------------------------------------------------------------------------- /contrib/acorn/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = Makefile.acorn ReadMe SetVars cleanlib convert install 27 | 28 | -------------------------------------------------------------------------------- /contrib/acorn/SetVars: -------------------------------------------------------------------------------- 1 | Set LibTIFF$Dir 2 | Set LibTIFF$Path . 3 | Set C$Path ,LibTIFF: 4 | -------------------------------------------------------------------------------- /contrib/acorn/cleanlib: -------------------------------------------------------------------------------- 1 | IfThere LibTIFF:o.* THEN Wipe LibTIFF:o.* ~CFR~V 2 | IfThere LibTIFF:c.tif_fax3sm THEN Delete LibTIFF:c.tif_fax3sm 3 | IfThere LibTIFF:mkg3states THEN Delete LibTIFF:mkg3states 4 | IfThere LibTIFF:h.version THEN Delete LibTIFF:h.version 5 | IfThere LibTIFF:mkversion THEN Delete LibTIFF:mkversion 6 | -------------------------------------------------------------------------------- /contrib/addtiffo/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | LIBTIFF = $(top_builddir)/libtiff/libtiff.la 27 | 28 | EXTRA_DIST = README Makefile.vc 29 | 30 | noinst_PROGRAMS = addtiffo 31 | 32 | addtiffo_SOURCES = addtiffo.c tif_overview.c tif_ovrcache.c tif_ovrcache.h 33 | addtiffo_LDADD = $(LIBTIFF) 34 | 35 | INCLUDES = -I$(top_srcdir)/libtiff 36 | 37 | -------------------------------------------------------------------------------- /contrib/addtiffo/Makefile.vc: -------------------------------------------------------------------------------- 1 | # 2 | # If libtiff.a is installed in /usr/lib or /usr/local/lib just point 3 | # LIBTIFF_DIR there. It doesn't need a full libtiff tree. 4 | # 5 | !INCLUDE ..\..\nmake.opt 6 | 7 | LIBTIFF_DIR = ..\..\libtiff 8 | # 9 | INCL = -I..\..\libtiff 10 | LIBS = $(LIBTIFF_DIR)\libtiff.lib 11 | 12 | addtiffo: addtiffo.obj tif_overview.obj tif_ovrcache.obj 13 | $(CC) $(CFLAGS) addtiffo.obj tif_overview.obj tif_ovrcache.obj \ 14 | $(LIBS) /Feaddtiffo.exe 15 | 16 | 17 | addtiffo.obj: addtiffo.c 18 | $(CC) -c $(CFLAGS) addtiffo.c 19 | 20 | tif_overview.obj: tif_overview.c 21 | $(CC) -c $(CFLAGS) tif_overview.c 22 | 23 | tif_ovrcache.obj: tif_ovrcache.c 24 | $(CC) -c $(CFLAGS) tif_ovrcache.c 25 | 26 | clean: 27 | -del *.obj 28 | -del addtiffo.exe 29 | -------------------------------------------------------------------------------- /contrib/dbs/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | SUBDIRS = xtiff 27 | 28 | LIBTIFF = $(top_builddir)/libtiff/libtiff.la 29 | 30 | EXTRA_DIST = README 31 | 32 | noinst_PROGRAMS = tiff-bi tiff-grayscale tiff-palette tiff-rgb 33 | 34 | tiff_bi_SOURCES = tiff-bi.c 35 | tiff_bi_LDADD = $(LIBTIFF) 36 | tiff_grayscale_SOURCES = tiff-grayscale.c 37 | tiff_grayscale_LDADD = $(LIBTIFF) 38 | tiff_palette_SOURCES = tiff-palette.c 39 | tiff_palette_LDADD = $(LIBTIFF) 40 | tiff_rgb_SOURCES = tiff-rgb.c 41 | tiff_rgb_LDADD = $(LIBTIFF) 42 | 43 | INCLUDES = -I$(top_srcdir)/libtiff 44 | 45 | -------------------------------------------------------------------------------- /contrib/dbs/README: -------------------------------------------------------------------------------- 1 | Wed May 9 09:11:35 PDT 1990 2 | 3 | This directory contains programs from Dan Sears 4 | (dbs@decwrl.dec.com). Contact him directly if 5 | you have questions/problems. 6 | 7 | Sam 8 | -------------------------------------------------------------------------------- /contrib/dbs/tiff-bi.c: -------------------------------------------------------------------------------- 1 | /* $Id: tiff-bi.c,v 1.2 2004/05/03 16:46:36 dron Exp $ */ 2 | 3 | /* 4 | * tiff-bi.c -- create a Class B (bilevel) TIFF file 5 | * 6 | * Copyright 1990 by Digital Equipment Corporation, Maynard, Massachusetts. 7 | * 8 | * All Rights Reserved 9 | * 10 | * Permission to use, copy, modify, and distribute this software and its 11 | * documentation for any purpose and without fee is hereby granted, 12 | * provided that the above copyright notice appear in all copies and that 13 | * both that copyright notice and this permission notice appear in 14 | * supporting documentation, and that the name of Digital not be 15 | * used in advertising or publicity pertaining to distribution of the 16 | * software without specific, written prior permission. 17 | * 18 | * DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING 19 | * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL 20 | * DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR 21 | * ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, 23 | * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS 24 | * SOFTWARE. 25 | */ 26 | 27 | #include 28 | #include 29 | 30 | #include "tiffio.h" 31 | 32 | #define WIDTH 512 33 | #define HEIGHT WIDTH 34 | 35 | int main(int argc, char **argv) 36 | { 37 | int i; 38 | unsigned char * scan_line; 39 | TIFF * tif; 40 | 41 | if (argc != 2) { 42 | fprintf(stderr, "Usage: %s tiff-image\n", argv[0]); 43 | return 0; 44 | } 45 | 46 | if ((tif = TIFFOpen(argv[1], "w")) == NULL) { 47 | fprintf(stderr, "can't open %s as a TIFF file\n", argv[1]); 48 | return 0; 49 | } 50 | 51 | TIFFSetField(tif, TIFFTAG_IMAGEWIDTH, WIDTH); 52 | TIFFSetField(tif, TIFFTAG_IMAGELENGTH, HEIGHT); 53 | TIFFSetField(tif, TIFFTAG_BITSPERSAMPLE, 1); 54 | TIFFSetField(tif, TIFFTAG_COMPRESSION, COMPRESSION_NONE); 55 | TIFFSetField(tif, TIFFTAG_PHOTOMETRIC, PHOTOMETRIC_MINISBLACK); 56 | TIFFSetField(tif, TIFFTAG_SAMPLESPERPIXEL, 1); 57 | TIFFSetField(tif, TIFFTAG_ROWSPERSTRIP, 1); 58 | TIFFSetField(tif, TIFFTAG_PLANARCONFIG, PLANARCONFIG_CONTIG); 59 | TIFFSetField(tif, TIFFTAG_RESOLUTIONUNIT, RESUNIT_NONE); 60 | 61 | scan_line = (unsigned char *) malloc(WIDTH / 8); 62 | 63 | for (i = 0; i < (WIDTH / 8) / 2; i++) 64 | scan_line[i] = 0; 65 | 66 | for (i = (WIDTH / 8) / 2; i < (WIDTH / 8); i++) 67 | scan_line[i] = 255; 68 | 69 | for (i = 0; i < HEIGHT / 2; i++) 70 | TIFFWriteScanline(tif, scan_line, i, 0); 71 | 72 | for (i = 0; i < (WIDTH / 8) / 2; i++) 73 | scan_line[i] = 255; 74 | 75 | for (i = (WIDTH / 8) / 2; i < (WIDTH / 8); i++) 76 | scan_line[i] = 0; 77 | 78 | for (i = HEIGHT / 2; i < HEIGHT; i++) 79 | TIFFWriteScanline(tif, scan_line, i, 0); 80 | 81 | free(scan_line); 82 | TIFFClose(tif); 83 | return 0; 84 | } 85 | -------------------------------------------------------------------------------- /contrib/dbs/xtiff/Imakefile: -------------------------------------------------------------------------------- 1 | # 2 | # Imakefile -- to generate a Makefile for xtiff, use: 3 | # /usr/local/X11/mit/config/imake \ 4 | # -I/usr/local/X11/mit/config \ 5 | # -DTOPDIR=/usr/local/X11/mit \ 6 | # -DCURDIR=/usr/local/X11/mit \ 7 | # -DDESTDIR=/usr/local/X11/mit 8 | # 9 | 10 | SYS_LIBRARIES = -lm 11 | LOCAL_LIBRARIES = XawClientLibs 12 | DEPLIBS = XawClientDepLibs 13 | TIFF = ../../../libtiff 14 | EXTRA_LIBRARIES = $(TIFF)/libtiff.so -lm 15 | EXTRA_INCLUDES = -I$(TIFF) 16 | 17 | SimpleProgramTarget(xtiff) 18 | -------------------------------------------------------------------------------- /contrib/dbs/xtiff/Makefile.am: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.am,v 1.2 2006/03/23 14:54:01 dron Exp $ 2 | # 3 | # Tag Image File Format (TIFF) Software 4 | # 5 | # Copyright (C) 2004, Andrey Kiselev 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | 26 | # Process this file with automake to produce Makefile.in. 27 | 28 | EXTRA_DIST = Imakefile README patchlevel.h xtiff.c xtifficon.h 29 | 30 | -------------------------------------------------------------------------------- /contrib/dbs/xtiff/README: -------------------------------------------------------------------------------- 1 | xtiff 2.0 2 | 3 | xtiff is a tool for viewing a TIFF file in an X window. It was written to 4 | handle as many different kinds of TIFF files as possible while remaining 5 | simple, portable and efficient. xtiff requires X11 R4, the Athena Widgets 6 | and Sam Leffler's libtiff package (which can be found on ucbvax.berkeley.edu). 7 | -------------------------------------------------------------------------------- /contrib/dbs/xtiff/patchlevel.h: -------------------------------------------------------------------------------- 1 | #define PATCHLEVEL 0 2 | -------------------------------------------------------------------------------- /contrib/dbs/xtiff/xtifficon.h: -------------------------------------------------------------------------------- 1 | #define xtifficon_width 32 2 | #define xtifficon_height 32 3 | static char xtifficon_bits[] = { 4 | 0xff, 0x00, 0x00, 0xc0, 0xfe, 0x01, 0x7e, 0xc0, 0xfc, 0x03, 0x7e, 0x60, 5 | 0xf8, 0x07, 0x06, 0x30, 0xf8, 0x07, 0x1e, 0x18, 0xf0, 0x0f, 0x1e, 0x0c, 6 | 0xe0, 0x1f, 0x06, 0x06, 0xc0, 0x3f, 0x06, 0x06, 0xc0, 0x3f, 0x06, 0x03, 7 | 0x80, 0x7f, 0x80, 0x01, 0x00, 0xff, 0xc0, 0x00, 0x00, 0xfe, 0x61, 0x00, 8 | 0x00, 0xfe, 0x31, 0x7e, 0x7e, 0xfc, 0x33, 0x7e, 0x7e, 0xf8, 0x1b, 0x06, 9 | 0x18, 0xf0, 0x0d, 0x1e, 0x18, 0xf0, 0x0e, 0x1e, 0x18, 0x60, 0x1f, 0x06, 10 | 0x18, 0xb0, 0x3f, 0x06, 0x18, 0x98, 0x7f, 0x06, 0x18, 0x98, 0x7f, 0x00, 11 | 0x00, 0x0c, 0xff, 0x00, 0x00, 0x06, 0xfe, 0x01, 0x00, 0x63, 0xfc, 0x03, 12 | 0x80, 0x61, 0xfc, 0x03, 0xc0, 0x60, 0xf8, 0x07, 0xc0, 0x60, 0xf0, 0x0f, 13 | 0x60, 0x60, 0xe0, 0x1f, 0x30, 0x60, 0xe0, 0x1f, 0x18, 0x60, 0xc0, 0x3f, 14 | 0x0c, 0x60, 0x80, 0x7f, 0x06, 0x00, 0x00, 0xff}; 15 | -------------------------------------------------------------------------------- /contrib/iptcutil/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | LIBTIFF = $(top_builddir)/libtiff/libtiff.la 27 | 28 | EXTRA_DIST = README test.iptc test.txt 29 | 30 | noinst_PROGRAMS = iptcutil 31 | 32 | iptcutil_SOURCES = iptcutil.c 33 | iptcutil_LDADD = $(LIBTIFF) 34 | 35 | INCLUDES = -I$(top_srcdir)/libtiff 36 | 37 | -------------------------------------------------------------------------------- /contrib/iptcutil/README: -------------------------------------------------------------------------------- 1 | 2 | Program: IPTCUTIL.C 3 | 4 | Purpose: Convert between IPTC binary and a "special" IPTC text file format. 5 | 6 | Usage: iptcutil -t | -b [-i file] [-o file] output 7 | 8 | Notes: You tell the program the "type" of input file via the -t and -b 9 | switches. The -t says that the input is text, while the -b says 10 | that the input is binary IPTC. You can use either the -i or the 11 | -o switches to tell the program what the input and output files 12 | will be, or use simple piping. 13 | 14 | Author: William T. Radcliffe (billr@corbis.com) 15 | Parts of this program were derived from other places. The original 16 | binary to text conversion was taken from the PHP distribution and 17 | the tokenizer was written many years ago, by someone else as well. 18 | 19 | This software is provided freely "as is", without warranty of any kind, 20 | express or implied, including but not limited to the warranties of 21 | merchantability, fitness for a particular purpose and noninfringement. 22 | In no event shall William T. Radcliffe be liable for any claim, damages or 23 | other liability, whether in an action of contract, tort or otherwise, 24 | arising from, out of or in connection with IPTCUTIL 25 | 26 | -------------------------------------------------------------------------------- /contrib/iptcutil/test.iptc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/contrib/iptcutil/test.iptc -------------------------------------------------------------------------------- /contrib/iptcutil/test.txt: -------------------------------------------------------------------------------- 1 | 2#0="�" 2 | 2#120#Caption="Chairman of the US House Judiciary Committee, Henry Hyde,R-IL, makes his opening statement during impeachment hearings 11 December on Capitol Hill in Washington, DC. The committee is debating the articles of impechment and my take a vote on the impeachment of US President BIll Clinton on charges that he obstucted justice, lied and abused the power of his office as early as today. AFP PHOTO Paul J. RICHARDS " 3 | 2#122#Caption Writer="kb/lt" 4 | 2#100#Country Code="USA" 5 | 2#105#Headline="Old fart squeezing two fingers." 6 | 2#30#Release Date="19981211" 7 | 2#35#Release Time="000000+0000" 8 | 2#40#Special Instructions="This is a test. This is only a test. ABCDEFGHIJKLMNOPQRSTUVWXYZ 1234567890" 9 | 2#80#Byline="PAUL J. RICHARDS" 10 | 2#85#Byline Title="STF" 11 | 2#110#Credit="AFP" 12 | 2#65#Originating Program="MacDesk Reporter" 13 | 2#115#Source="AFP" 14 | 2#5#Image Name="US-HYDE" 15 | 2#55#Created Date="19981211" 16 | 2#90#City="WASHINGTON" 17 | 2#95#Province State="DC" 18 | 2#101#Country="UNITED STATES" 19 | 2#103#Original Transmission Reference="DCA03" 20 | 2#15#Category="POL" 21 | 2#20#Supplemental Category="GOVERNMENT" 22 | 2#10#Priority="5" 23 | 2#25#Keyword="fart" 24 | 2#25#Keyword="squeezing" 25 | 2#25#Keyword="old" 26 | 2#25#Keyword="fingers" 27 | 2#75#Object Cycle="a" 28 | 2#60#Created Time="000000+0000" 29 | 2#70#Program Version="2.0.3" 30 | 2#130="3S" 31 | 2#135="GB" 32 | 2#231="Kaya A. Hoffmann 12/14/98 12:00:44 PM Copy To : Selects - \\KINYANI\Selects������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������" 33 | -------------------------------------------------------------------------------- /contrib/mac-cw/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = Makefile.script README mac_main.c mac_main.h metrowerks.note mkg3_main.c version.h 27 | 28 | -------------------------------------------------------------------------------- /contrib/mac-cw/README: -------------------------------------------------------------------------------- 1 | ---------------------------------------------------- 2 | Build instructions for LIBTIFF - CodeWarrior (6.1): 3 | ---------------------------------------------------- 4 | 5 | In this directory you will find a Makefile.script Applescript 6 | file, which should be run in order to build the libtiff code 7 | using MetroWerks CodeWarrior. 8 | 9 | Refer to the "metrowerks.note" instructions on building the 10 | library for 68k and PowerPC native code, as well as building 11 | some of the libtiff tools, which are rather unix-like, but 12 | at least give an example of how to link everything together. 13 | 14 | Questions, comments, bug reports to Niles Ritter 15 | (ndr@tazboy.jpl.nasa.gov). Sam Leffler takes no responsibility 16 | for the viability of this stuff. 17 | 18 | -Niles. 19 | -------------------------------------------------------------------------------- /contrib/mac-cw/mac_main.c: -------------------------------------------------------------------------------- 1 | /* 2 | * mac_main.c -- The REAL entry point which 3 | * calls the tools main code. For the tools 4 | * the symbol "main" has been #defined to "tool_main" 5 | * so that this entry point may be used to access 6 | * the user-input first. 7 | */ 8 | 9 | #undef main 10 | 11 | int 12 | main() 13 | { 14 | int argc; 15 | char **argv; 16 | 17 | argc=ccommand(&argv); 18 | 19 | return tool_main(argc,argv); // Call the tool "main()" routine 20 | } 21 | -------------------------------------------------------------------------------- /contrib/mac-cw/mac_main.h: -------------------------------------------------------------------------------- 1 | /* 2 | * mac_main.h -- redefines main entry point 3 | */ 4 | 5 | #ifndef _mac_main_h 6 | #define _mac_main_h 7 | 8 | #undef main 9 | #define main tool_main 10 | 11 | #endif /* _mac_main_h */ 12 | 13 | -------------------------------------------------------------------------------- /contrib/mac-cw/mkg3_main.c: -------------------------------------------------------------------------------- 1 | /* 2 | * mkg3_main.c -- passes fake arguments into main 3 | */ 4 | 5 | #undef main 6 | 7 | int 8 | main() 9 | { 10 | static char *argv[4] = { 11 | "mkg3states", "-c", "const", "tif_fax3sm.c" }; 12 | 13 | return tool_main(4,argv); // Call the tool "main()" routine 14 | } 15 | -------------------------------------------------------------------------------- /contrib/mac-cw/version.h: -------------------------------------------------------------------------------- 1 | #define VERSION \ 2 | "LIBTIFF, Version 3.4beta028 \n"\ 3 | "Copyright (c) 1988-1995 Sam Leffler\n"\ 4 | "Copyright (c) 1991-1996 Silicon Graphics, Inc." 5 | -------------------------------------------------------------------------------- /contrib/mac-mpw/BUILD.mpw: -------------------------------------------------------------------------------- 1 | # BUILD.mpw: 2 | # 3 | # Full build for Apple Macintosh Programmer's Workshop (MPW). 4 | # 5 | # This is an executable MPW script which creates various 6 | # utilities, sets up the MPW makefiles and runs the builds. 7 | # This script should be run at the top level TIFF directory with: 8 | # 9 | # directory ::: 10 | # :contrib:mac-mpw:BUILD.mpw 11 | # 12 | # NOTE: The full build requires that MPW have at least 6 MB 13 | # allocated to it to compile the CCITT Fax codec tables. To 14 | # deactivate CCITT compression edit the file :contrib:mac:libtiff.make 15 | # first and follow the directions for disabling Fax decoding. 16 | # 17 | # All TIFF tools are built as MPW tools, executable from the 18 | # MPW shell or other compatible tool server. 19 | # 20 | # Written by: Niles Ritter (ndr@tazboy.jpl.nasa.gov). 21 | # 22 | 23 | echo "############# Full Scratch Build for MPW #############" 24 | 25 | # Create the ascii->mpw translation tool; this is used to 26 | # convert standard ASCII files into ones using the special 27 | # MPW characters, which don't live comfortably in unix tar files. 28 | # 29 | echo "######## Creating ASCII->MPW translator ########" 30 | set contrib ':contrib:mac-mpw:' 31 | directory {contrib} 32 | createmake -tool mactrans mactrans.c > dev:null 33 | make -f mactrans.make | streamedit -e "/CSANELib/||/Math/||/ToolLibs/ del" > mactrans.bld 34 | execute mactrans.bld > dev:null 35 | delete -y mactrans.make mactrans.bld mactrans.c.o || set status 0 36 | directory ::: #An mpw trick for going up two levels 37 | 38 | # Create the top-level Makefile and run it 39 | echo "######## Creating Makefile ########" 40 | catenate {contrib}top.make | {contrib}mactrans > Makefile 41 | 42 | echo "######## Running Makefile ########" 43 | make > build.mpw 44 | execute build.mpw 45 | echo "############# MPW Build Complete #############" 46 | exit 0 47 | 48 | -------------------------------------------------------------------------------- /contrib/mac-mpw/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = BUILD.mpw README libtiff.make mactrans.c port.make tools.make top.make 27 | 28 | -------------------------------------------------------------------------------- /contrib/mac-mpw/README: -------------------------------------------------------------------------------- 1 | ###################### 2 | About contrib:mac-mpw: 3 | ###################### 4 | 5 | This directory contains all of the utilities and makefile source 6 | to build the LIBTIFF library and tools from the MPW Shell. The 7 | file BUILD.mpw in this directory is an executable script 8 | which uses all of these files to create the MPW makefiles and 9 | run them. 10 | 11 | The .make files are not MPW makefiles as such, 12 | but are when run through the "mactrans" program, which turns 13 | the ascii "%nn" metacharacters into the standard weird MPW 14 | make characters. 15 | 16 | This translation trick is necessary to protect the files when 17 | they are put into unix tarfiles, which tend to mangle the 18 | special characters. 19 | 20 | --Niles Ritter (ndr@tazboy.jpl.nasa.gov) 21 | -------------------------------------------------------------------------------- /contrib/mac-mpw/mactrans.c: -------------------------------------------------------------------------------- 1 | /* 2 | * mactrans.c -- Hack filter used to generate MPW files 3 | * with special characters from pure ASCII, denoted "%nn" 4 | * where nn is hex. (except for "%%", which is literal '%'). 5 | * 6 | * calling sequence: 7 | * 8 | * catenate file | mactrans [-toascii | -fromascii] > output 9 | * 10 | * Written by: Niles Ritter. 11 | */ 12 | #include 13 | #include 14 | #include 15 | 16 | void to_ascii(void); 17 | void from_ascii(void); 18 | 19 | main(int argc, char *argv[]) 20 | { 21 | if (argc<2 || argv[1][1]=='f') from_ascii(); 22 | else to_ascii(); 23 | exit (0); 24 | } 25 | 26 | void from_ascii(void) 27 | { 28 | char c; 29 | int d; 30 | while ((c=getchar())!=EOF) 31 | { 32 | if (c!='%' || (c=getchar())=='%') putchar(c); 33 | else 34 | { 35 | ungetc(c,stdin); 36 | scanf("%2x",&d); 37 | *((unsigned char *)&c) = d; 38 | putchar(c); 39 | } 40 | } 41 | } 42 | 43 | void to_ascii(void) 44 | { 45 | char c; 46 | int d; 47 | while ((c=getchar())!=EOF) 48 | { 49 | if (isascii(c)) putchar (c); 50 | else 51 | { 52 | d = *((unsigned char *)&c); 53 | printf("%%%2x",d); 54 | } 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /contrib/mac-mpw/port.make: -------------------------------------------------------------------------------- 1 | # 2 | # Tag Image File Format Library 3 | # 4 | # Copyright (c) 1995 Sam Leffler 5 | # Copyright (c) 1995 Silicon Graphics, Inc. 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | # 26 | DEPTH= :: 27 | SRCDIR= : 28 | 29 | NULL = 30 | CC = C 31 | AR = Lib 32 | AROPTS = 33 | RM= delete -y 34 | 35 | IPATH = -I {DEPTH} -I {SRCDIR} 36 | COPTS = 37 | OPTIMIZER= 38 | CFLAGS = {COPTS} {OPTIMIZER} {IPATH} 39 | 40 | CFILES = 41 | OBJECTS = getopt.c.o 42 | TARGETS = libport.o 43 | 44 | .c.o %c4 .c 45 | {CC} -model far {COptions} {CFLAGS} -s {Default} {DepDir}{Default}.c -o {TargDir}{Default}.c.o 46 | 47 | all %c4 {TARGETS} 48 | 49 | libport.o %c4 {OBJECTS} 50 | {AR} {OBJECTS} -o libport.o 51 | 52 | clean %c4 53 | {RM} {TARGETS} {OBJECTS} || set status 0 54 | -------------------------------------------------------------------------------- /contrib/mfs/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README mfs_file.c 27 | 28 | -------------------------------------------------------------------------------- /contrib/mfs/README: -------------------------------------------------------------------------------- 1 | Date: Mon, 23 Jun 1997 13:30:48 +0200 2 | To: 3 | 4 | From: "Mike Johnson" 5 | Subject: libtiff - Thanks 6 | 7 | Return-Path: mikehunt@swipnet.se 8 | Delivery-Date: Mon, 23 Jun 1997 06:53:39 -0700 9 | 10 | Hi Sam, 11 | 12 | I noticed in the README from libtiff that you would like to know about 13 | what people have done with libtiff, so I thought I would drop you a 14 | line. 15 | 16 | We have used libtiff to create and convert TIFF images of financial 17 | documents which are sent from and to major document processing systems 18 | in Sweden and Denmark. 19 | 20 | I would like to express my deep gratitude to yourself and Sillicon 21 | Graphics for making this excellent library available for public use. 22 | There is obviously a lot of work that has gone in to libtiff and the 23 | quality of the code and documentation is an example to others. 24 | 25 | One thing that libtiff did not do was work on a memory area rather than 26 | files. In my applications I had already read a TIFF or other format 27 | file in to memory and did not want to waste I/O writing it out again 28 | for libtiff's benefit. I therefore constructed a set of functions to 29 | pass up to TIFFClientOpen to simulate a file in memory. I have attached 30 | my mfs (memory file system) source code for you to use or junk, as you 31 | see fit. :-) 32 | 33 | Once again, thanks very much for making my life simpler. 34 | 35 | Best Regards, 36 | 37 | Mike Johnson. 38 | -------------------------------------------------------------------------------- /contrib/ojpeg/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README jdhuff_add.c 27 | 28 | -------------------------------------------------------------------------------- /contrib/ojpeg/README: -------------------------------------------------------------------------------- 1 | 2 | For the broadest possible support for OJPEG files the following steps are 3 | necessary: 4 | 5 | o Ensure you are able to build with JPEG support (see config.site). 6 | 7 | o Uncomment OJPEG="yes" statement in config.site file or 8 | #define OJPEG_SUPPORT somewhere. This can be put in tiffconf.h for 9 | instance. 10 | 11 | o Append the jdhuff_add.c code to the end of jdhuff.c within the IJG JPEG 12 | libraries jdhuff.c file and recompile libjpeg (jpeg-6b tested). 13 | 14 | o Rebuild cleanly. 15 | 16 | 17 | OJPEG support implemented by Scott Marovich at HP (marovich@hpl.hp.com). 18 | 19 | --- 20 | 21 | For notes on further improved JPEG-in-TIFF support also see the following 22 | bug in bugzilla: 23 | 24 | http://bugzilla.remotesensing.org/show_bug.cgi?id=156 25 | -------------------------------------------------------------------------------- /contrib/ojpeg/jdhuff_add.c: -------------------------------------------------------------------------------- 1 | /* 2 | * BEWARE OF KLUDGE: This subroutine is a hack for decoding illegal JPEG-in- 3 | * TIFF encapsulations produced by Microsoft's Wang Imaging 4 | * for Windows application with the public-domain TIFF Library. Based upon an 5 | * examination of selected output files, this program apparently divides a JPEG 6 | * bit-stream into consecutive horizontal TIFF "strips", such that the JPEG 7 | * encoder's/decoder's DC coefficients for each image component are reset before 8 | * each "strip". Moreover, a "strip" is not necessarily encoded in a multiple 9 | * of 8 bits, so one must sometimes discard 1-7 bits at the end of each "strip" 10 | * for alignment to the next input-Byte storage boundary. IJG JPEG Library 11 | * decoder state is not normally exposed to client applications, so this sub- 12 | * routine provides the TIFF Library with a "hook" to make these corrections. 13 | * It should be called after "jpeg_start_decompress()" and before 14 | * "jpeg_finish_decompress()", just before decoding each "strip" using 15 | * "jpeg_read_raw_data()" or "jpeg_read_scanlines()". 16 | * 17 | * This kludge is not sanctioned or supported by the Independent JPEG Group, and 18 | * future changes to the IJG JPEG Library might invalidate it. Do not send bug 19 | * reports about this code to IJG developers. Instead, contact the author for 20 | * advice: Scott B. Marovich , Hewlett-Packard Labs, 6/01. 21 | */ 22 | GLOBAL(void) 23 | jpeg_reset_huff_decode (register j_decompress_ptr cinfo,register float *refbw) 24 | { register huff_entropy_ptr entropy = (huff_entropy_ptr)cinfo->entropy; 25 | register int ci = 0; 26 | 27 | /* Re-initialize DC predictions */ 28 | do entropy->saved.last_dc_val[ci] = -refbw[ci << 1]; 29 | while (++ci < cinfo->comps_in_scan); 30 | /* Discard encoded input bits, up to the next Byte boundary */ 31 | entropy->bitstate.bits_left &= ~7; 32 | } 33 | -------------------------------------------------------------------------------- /contrib/pds/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README tif_imageiter.c tif_imageiter.h tif_pdsdirread.c tif_pdsdirwrite.c 27 | 28 | -------------------------------------------------------------------------------- /contrib/pds/tif_imageiter.h: -------------------------------------------------------------------------------- 1 | typedef struct _TIFFImageIter TIFFImageIter; 2 | 3 | /* The callback function is called for each "block" of image pixel data after 4 | it has been read from the file and decoded. This image pixel data is in the 5 | buffer pp, and this data represents the image pixels from (x,y) to 6 | (x+w,y+h). It is stored in pixel format, so each pixel contains 7 | img->samplesperpixel consecutive samples each containing img->bitspersample 8 | bits of data. The array pp is ordered in h consecutive rows of w+fromskew 9 | pixels each. */ 10 | typedef void (*ImageIterTileContigRoutine) 11 | (TIFFImageIter*, void *, uint32, uint32, uint32, uint32, int32, 12 | unsigned char*); 13 | #define DECLAREContigCallbackFunc(name) \ 14 | static void name(\ 15 | TIFFImageIter* img, \ 16 | void* user_data, \ 17 | uint32 x, uint32 y, \ 18 | uint32 w, uint32 h, \ 19 | int32 fromskew, \ 20 | u_char* pp \ 21 | ) 22 | 23 | typedef void (*ImageIterTileSeparateRoutine) 24 | (TIFFImageIter*, void *, uint32, uint32, uint32, uint32, int32, 25 | unsigned char*, unsigned char*, unsigned char*, unsigned char*); 26 | #define DECLARESepCallbackFunc(name) \ 27 | static void name(\ 28 | TIFFImageIter* img, \ 29 | void* user_data, \ 30 | uint32 x, uint32 y, \ 31 | uint32 w, uint32 h,\ 32 | int32 fromskew, \ 33 | u_char* r, u_char* g, u_char* b, u_char* a\ 34 | ) 35 | 36 | struct _TIFFImageIter { 37 | TIFF* tif; /* image handle */ 38 | int stoponerr; /* stop on read error */ 39 | int isContig; /* data is packed/separate */ 40 | int alpha; /* type of alpha data present */ 41 | uint32 width; /* image width */ 42 | uint32 height; /* image height */ 43 | uint16 bitspersample; /* image bits/sample */ 44 | uint16 samplesperpixel; /* image samples/pixel */ 45 | uint16 orientation; /* image orientation */ 46 | uint16 photometric; /* image photometric interp */ 47 | uint16* redcmap; /* colormap pallete */ 48 | uint16* greencmap; 49 | uint16* bluecmap; 50 | /* get image data routine */ 51 | int (*get)(TIFFImageIter*, void *udata, uint32, uint32); 52 | union { 53 | void (*any)(TIFFImageIter*); 54 | ImageIterTileContigRoutine contig; 55 | ImageIterTileSeparateRoutine separate; 56 | } callback; /* fn to exec for each block */ 57 | }; 58 | -------------------------------------------------------------------------------- /contrib/ras/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README ras2tif.c tif2ras.c 27 | 28 | -------------------------------------------------------------------------------- /contrib/ras/README: -------------------------------------------------------------------------------- 1 | Sun May 19 22:28:16 PDT 1991 2 | 3 | These programs are from Patrick Naughton (naughton@wind.sun.com). 4 | I've tried to update them to reflect changes to the library, but 5 | I am unable to verify that they operate properly, because they 6 | require the Sun pixrect library. 7 | 8 | Please contact Patrick directly if you have questions/problems. 9 | 10 | Sam 11 | -------------------------------------------------------------------------------- /contrib/stream/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README tiffstream.cpp tiffstream.h 27 | 28 | -------------------------------------------------------------------------------- /contrib/stream/README: -------------------------------------------------------------------------------- 1 | Subject: tiff stream interface (contrib) 2 | Date: Thu, 30 Mar 2000 10:48:51 -0800 3 | From: "Avi Bleiweiss" 4 | To: , 5 | 6 | Here at Shutterfly we have augmented the file based tiff library to support 7 | C++ streams. The implementation is an adaptor class, which takes any C++ 8 | stream from the user and in return it deposits i/o operation method pointers 9 | (e.g. read, write, seek and close) into the tiff's library client state. 10 | 11 | The class TiffStream has an overloaded factory method - makeFileStream - 12 | which takes the C++ stream as an argument, calls TIFFClientOpen and returns 13 | a tiff handle. The class retains the tiff handle in its local state and 14 | provides a helper function (getTiffHandle) to query the handle at any time. 15 | Additional helper method - getStreamSize - provides the stream size to the 16 | user. The implementation assumes client responsibility to delete the stream 17 | object. The class calls TIFFClose at destruction time. 18 | 19 | Attached are a definition (tiffstream.h) and an implementation 20 | (tiffstream.cpp) files of the TiffStream class. No changes are required to 21 | the tiff core piece and the class sits on top of the library. The code is 22 | fairly tested at this point and is used internally in Shutterfly imaging 23 | software. The code is portable across WindowsNT/Linux/Solaris. 24 | 25 | We at Shutterfly believe this software has benefits to the larger community 26 | of tiff library users and would like to contribute this software to be part 27 | of the tiff distributed package. Let me know of any issue. 28 | 29 | Thanks 30 | Avi 31 | -------------------------------------------------------------------------------- /contrib/stream/tiffstream.h: -------------------------------------------------------------------------------- 1 | // tiff stream interface class definition 2 | 3 | #ifndef _TIFF_STREAM_H_ 4 | #define _TIFF_STREAM_H_ 5 | 6 | #include 7 | 8 | #include "tiffio.h" 9 | 10 | class TiffStream { 11 | 12 | public: 13 | // ctor/dtor 14 | TiffStream(); 15 | ~TiffStream(); 16 | 17 | public: 18 | enum SeekDir { 19 | beg, 20 | cur, 21 | end, 22 | }; 23 | 24 | public: 25 | // factory methods 26 | TIFF* makeFileStream(iostream* str); 27 | TIFF* makeFileStream(istream* str); 28 | TIFF* makeFileStream(ostream* str); 29 | 30 | public: 31 | // tiff client methods 32 | static tsize_t read(thandle_t fd, tdata_t buf, tsize_t size); 33 | static tsize_t write(thandle_t fd, tdata_t buf, tsize_t size); 34 | static toff_t seek(thandle_t fd, toff_t offset, int origin); 35 | static toff_t size(thandle_t fd); 36 | static int close(thandle_t fd); 37 | static int map(thandle_t fd, tdata_t* phase, toff_t* psize); 38 | static void unmap(thandle_t fd, tdata_t base, tsize_t size); 39 | 40 | public: 41 | // query method 42 | TIFF* getTiffHandle() const { return m_tif; } 43 | unsigned int getStreamLength() { return m_streamLength; } 44 | 45 | private: 46 | // internal methods 47 | unsigned int getSize(thandle_t fd); 48 | unsigned int tell(thandle_t fd); 49 | bool seekInt(thandle_t fd, unsigned int offset, int origin); 50 | bool isOpen(thandle_t fd); 51 | 52 | private: 53 | thandle_t m_this; 54 | TIFF* m_tif; 55 | static const char* m_name; 56 | istream* m_inStream; 57 | ostream* m_outStream; 58 | iostream* m_ioStream; 59 | int m_streamLength; 60 | 61 | }; 62 | 63 | #endif // _TIFF_STREAM_H_ -------------------------------------------------------------------------------- /contrib/tags/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = README listtif.c maketif.c xtif_dir.c xtiffio.h xtiffiop.h 27 | 28 | -------------------------------------------------------------------------------- /contrib/tags/listtif.c: -------------------------------------------------------------------------------- 1 | /* 2 | * listtif.c -- lists a tiff file. 3 | */ 4 | 5 | #include "xtiffio.h" 6 | #include 7 | 8 | void main(int argc,char *argv[]) 9 | { 10 | char *fname="newtif.tif"; 11 | int flags; 12 | 13 | TIFF *tif=(TIFF*)0; /* TIFF-level descriptor */ 14 | 15 | if (argc>1) fname=argv[1]; 16 | 17 | tif=XTIFFOpen(fname,"r"); 18 | if (!tif) goto failure; 19 | 20 | /* We want the double array listed */ 21 | flags = TIFFPRINT_MYMULTIDOUBLES; 22 | 23 | TIFFPrintDirectory(tif,stdout,flags); 24 | XTIFFClose(tif); 25 | exit (0); 26 | 27 | failure: 28 | printf("failure in listtif\n"); 29 | if (tif) XTIFFClose(tif); 30 | exit (-1); 31 | } 32 | 33 | -------------------------------------------------------------------------------- /contrib/tags/maketif.c: -------------------------------------------------------------------------------- 1 | /* 2 | * maketif.c -- creates a little TIFF file, with 3 | * the XTIFF extended tiff example tags. 4 | */ 5 | 6 | #include 7 | #include "xtiffio.h" 8 | 9 | 10 | void SetUpTIFFDirectory(TIFF *tif); 11 | void WriteImage(TIFF *tif); 12 | 13 | #define WIDTH 20 14 | #define HEIGHT 20 15 | 16 | void main() 17 | { 18 | TIFF *tif=(TIFF*)0; /* TIFF-level descriptor */ 19 | 20 | tif=XTIFFOpen("newtif.tif","w"); 21 | if (!tif) goto failure; 22 | 23 | SetUpTIFFDirectory(tif); 24 | WriteImage(tif); 25 | 26 | XTIFFClose(tif); 27 | exit (0); 28 | 29 | failure: 30 | printf("failure in maketif\n"); 31 | if (tif) XTIFFClose(tif); 32 | exit (-1); 33 | } 34 | 35 | 36 | void SetUpTIFFDirectory(TIFF *tif) 37 | { 38 | double mymulti[6]={0.0,1.0,2.0, 3.1415926, 5.0,1.0}; 39 | uint32 mysingle=3456; 40 | char *ascii="This file was produced by Steven Spielberg. NOT"; 41 | 42 | TIFFSetField(tif,TIFFTAG_IMAGEWIDTH,WIDTH); 43 | TIFFSetField(tif,TIFFTAG_IMAGELENGTH,HEIGHT); 44 | TIFFSetField(tif,TIFFTAG_COMPRESSION,COMPRESSION_NONE); 45 | TIFFSetField(tif,TIFFTAG_PHOTOMETRIC,PHOTOMETRIC_MINISBLACK); 46 | TIFFSetField(tif,TIFFTAG_PLANARCONFIG,PLANARCONFIG_CONTIG); 47 | TIFFSetField(tif,TIFFTAG_BITSPERSAMPLE,8); 48 | TIFFSetField(tif,TIFFTAG_ROWSPERSTRIP,20); 49 | 50 | /* Install the extended TIFF tag examples */ 51 | TIFFSetField(tif,TIFFTAG_EXAMPLE_MULTI,6,mymulti); 52 | TIFFSetField(tif,TIFFTAG_EXAMPLE_SINGLE,mysingle); 53 | TIFFSetField(tif,TIFFTAG_EXAMPLE_ASCII,ascii); 54 | } 55 | 56 | 57 | void WriteImage(TIFF *tif) 58 | { 59 | int i; 60 | char buffer[WIDTH]; 61 | 62 | memset(buffer,0,sizeof(buffer)); 63 | for (i=0;itif_clientdata, "WriteImage","failure in WriteScanline\n"); 66 | } 67 | 68 | 69 | 70 | 71 | -------------------------------------------------------------------------------- /contrib/tags/xtiffio.h: -------------------------------------------------------------------------------- 1 | /* 2 | * xtiffio.h -- Public interface to Extended TIFF tags 3 | * 4 | * This is a template for defining a client module 5 | * which supports tag extensions to the standard libtiff 6 | * set. Only portions of the code marked "XXX" need to 7 | * be changed to support your tag set. 8 | * 9 | * written by: Niles D. Ritter 10 | */ 11 | 12 | #ifndef __xtiffio_h 13 | #define __xtiffio_h 14 | 15 | #include "tiffio.h" 16 | 17 | /* 18 | * XXX Define your private Tag names and values here 19 | */ 20 | 21 | /* These tags are not valid, but are provided for example */ 22 | #define TIFFTAG_EXAMPLE_MULTI 61234 23 | #define TIFFTAG_EXAMPLE_SINGLE 61235 24 | #define TIFFTAG_EXAMPLE_ASCII 61236 25 | 26 | /* 27 | * XXX Define Printing method flags. These 28 | * flags may be passed in to TIFFPrintDirectory() to 29 | * indicate that those particular field values should 30 | * be printed out in full, rather than just an indicator 31 | * of whether they are present or not. 32 | */ 33 | #define TIFFPRINT_MYMULTIDOUBLES 0x80000000 34 | 35 | /********************************************************************** 36 | * Nothing below this line should need to be changed by the user. 37 | **********************************************************************/ 38 | 39 | #if defined(__cplusplus) 40 | extern "C" { 41 | #endif 42 | 43 | extern TIFF* XTIFFOpen(const char* name, const char* mode); 44 | extern TIFF* XTIFFFdOpen(int fd, const char* name, const char* mode); 45 | extern void XTIFFClose(TIFF *tif); 46 | 47 | #if defined(__cplusplus) 48 | } 49 | #endif 50 | 51 | #endif /* __xtiffio_h */ 52 | 53 | -------------------------------------------------------------------------------- /contrib/tags/xtiffiop.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Private Extended TIFF library interface. 3 | * 4 | * uses private LIBTIFF interface. 5 | * 6 | * The portions of this module marked "XXX" should be 7 | * modified to support your tags instead. 8 | * 9 | * written by: Niles D. Ritter 10 | * 11 | */ 12 | 13 | #ifndef __xtiffiop_h 14 | #define __xtiffiop_h 15 | 16 | #include "tiffiop.h" 17 | #include "xtiffio.h" 18 | 19 | /********************************************************************** 20 | * User Configuration 21 | **********************************************************************/ 22 | 23 | /* XXX - Define number of your extended tags here */ 24 | #define NUM_XFIELD 3 25 | #define XFIELD_BASE (FIELD_LAST-NUM_XFIELD) 26 | 27 | /* XXX - Define your Tag Fields here */ 28 | #define FIELD_EXAMPLE_MULTI (XFIELD_BASE+0) 29 | #define FIELD_EXAMPLE_SINGLE (XFIELD_BASE+1) 30 | #define FIELD_EXAMPLE_ASCII (XFIELD_BASE+2) 31 | 32 | 33 | /* XXX - Define Private directory tag structure here */ 34 | struct XTIFFDirectory { 35 | uint16 xd_num_multi; /* dir-count for the multi tag */ 36 | double* xd_example_multi; 37 | uint32 xd_example_single; 38 | char* xd_example_ascii; 39 | }; 40 | typedef struct XTIFFDirectory XTIFFDirectory; 41 | 42 | /********************************************************************** 43 | * Nothing below this line should need to be changed by the user. 44 | **********************************************************************/ 45 | 46 | struct xtiff { 47 | TIFF *xtif_tif; /* parent TIFF pointer */ 48 | uint32 xtif_flags; 49 | #define XTIFFP_PRINT 0x00000001 50 | XTIFFDirectory xtif_dir; /* internal rep of current directory */ 51 | TIFFVSetMethod xtif_vsetfield; /* inherited tag set routine */ 52 | TIFFVGetMethod xtif_vgetfield; /* inherited tag get routine */ 53 | TIFFPrintMethod xtif_printdir; /* inherited dir print method */ 54 | }; 55 | typedef struct xtiff xtiff; 56 | 57 | 58 | #define PARENT(xt,pmember) ((xt)->xtif_ ## pmember) 59 | #define TIFFMEMBER(tf,pmember) ((tf)->tif_ ## pmember) 60 | #define XTIFFDIR(tif) ((xtiff *)TIFFMEMBER(tif,clientdir)) 61 | 62 | /* Extended TIFF flags */ 63 | #define XTIFF_INITIALIZED 0x80000000 64 | 65 | #endif /* __xtiffiop_h */ 66 | -------------------------------------------------------------------------------- /contrib/win_dib/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = Makefile.w95 README.Tiffile README.tiff2dib Tiffile.cpp tiff2dib.c 27 | 28 | -------------------------------------------------------------------------------- /contrib/win_dib/README.Tiffile: -------------------------------------------------------------------------------- 1 | Frank, 2 | 3 | I attached a file that uses RGBA interface (tif_getimage.c) to read a tiff 4 | file and convert to a DIB. It's advantage is that it is easy to read *any* 5 | tiff file suported by libtiff and easily convert it to a DIB. The disadvantage 6 | is that bilevel (B&W) bitmaps (and all other non-rgba images) are also 7 | converted to RGBA, thus taking up 32x as much memory as needed (4 bytes per 8 | pixel, rather than 1 bit). I read tiff files, but don't need to 9 | write them. And my files are typically small, so the overhead is mostly 10 | inconsequential. But for bilevel images, I overrode the get() and put() 11 | routines of the RGBA interface to just copy the data from the input raster 12 | to the output raster, rather than expanding out to full 32 bit format. It 13 | would be nice if there were a simple way to handle all palletized images, 14 | but that would take more custom routines, and it's not that important to me. 15 | 16 | Usage: 17 | 18 | m_pDIB = (PBITMAPINFOHEADER)::ReadTIFF(pathName); 19 | if (m_pDIB != 0) { 20 | m_format = IMAGETYPE_TIF; 21 | } 22 | 23 | This is intended as Win32, but the modifications for new get() and put() 24 | routines may be independent of platform. 25 | 26 | Thanks for your work supporting the forum and the library! 27 | 28 | Regards, 29 | 30 | Mark James 31 | mark@james.net 32 | -------------------------------------------------------------------------------- /contrib/win_dib/README.tiff2dib: -------------------------------------------------------------------------------- 1 | 2 | Date: 04 Dec 95 10:34:23 EST 3 | From: Philippe <100423.3705@compuserve.com> 4 | To: TIFF/sam Leffler 5 | Subject: TIFF library and Windows 95 6 | Message-Id: <951204153422_100423.3705_BHG101-1@CompuServe.COM> 7 | 8 | Sam, 9 | 10 | First, let me thanks all of you how have worked 11 | on that great TIFF library ! 12 | 13 | Here is some information that may help someone. 14 | 15 | I build the library under Windows 95 as a 32-bit library. 16 | The contribution of Scott Wagner (tif_win32.c) worked fine, but 17 | the makefile "makefile.msc" was unsable because it was 18 | written for DOS or Windows 3.1 and all the files names 19 | are limited to 8 characters. 20 | 21 | Here is the makefile I used : makefile.w95 22 | 23 | Also, I had to disable fax3 support because I wasn't able 24 | to build (as it is) the tool "mkg3states" to generate the include 25 | file "g3states.h". 26 | This source file must be modify to be build under Windows 95. 27 | 28 | To build the library under Windows 95 with Visual C++ 2.0, 29 | I had to : 30 | 31 | - undefine CCITT_SUPPORT in "tiffconf.h" 32 | 33 | - create the file version.h with this line : 34 | #define VERSION "3.4beta024" 35 | 36 | - build the makefile "makefile.w95" 37 | 38 | I also join the source file "tif2dib.c" that I created, 39 | it contain the function LoadTIFFinDIB that load 40 | a TIFF file and build a memory DIB with it and return the 41 | HANDLE (HDIB) of the memory bloc containing this DIB. 42 | Since DIB is the "natural" bitmap format for Windows 3.1, 95 and NT, 43 | this function sould be usefull for some Windows 95 (or NT) developer. 44 | 45 | 46 | Sorry for my approximate english ... 47 | 48 | Regards, 49 | 50 | Philippe Tenenhaus 100423.3705@compuserve.com 51 | Paris 52 | -------------------------------------------------------------------------------- /dist.info: -------------------------------------------------------------------------------- 1 | --- This file is part of LuaDist project 2 | 3 | name = "libtiff" 4 | version = "3.8.2" 5 | 6 | desc = "TIFF library." 7 | author = "Sam Leffler" 8 | license = "BSD-like" 9 | url = "http://www.remotesensing.org/libtiff" 10 | maintainer = "Peter Kapec" 11 | 12 | depends = { 13 | "zlib >= 1.2.3", 14 | "libjpeg >= 7", 15 | } 16 | 17 | -------------------------------------------------------------------------------- /html/Makefile.am: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.am,v 1.16 2006/03/23 14:54:01 dron Exp $ 2 | # 3 | # Tag Image File Format (TIFF) Software 4 | # 5 | # Copyright (C) 2004, Andrey Kiselev 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | 26 | # Process this file with automake to produce Makefile.in. 27 | 28 | docdir = $(LIBTIFF_DOCDIR)/html 29 | 30 | docfiles = \ 31 | addingtags.html \ 32 | bugs.html \ 33 | build.html \ 34 | contrib.html \ 35 | document.html \ 36 | images.html \ 37 | index.html \ 38 | internals.html \ 39 | intro.html \ 40 | libtiff.html \ 41 | misc.html \ 42 | support.html \ 43 | TIFFTechNote2.html \ 44 | tools.html \ 45 | v3.4beta007.html \ 46 | v3.4beta016.html \ 47 | v3.4beta018.html \ 48 | v3.4beta024.html \ 49 | v3.4beta028.html \ 50 | v3.4beta029.html \ 51 | v3.4beta031.html \ 52 | v3.4beta032.html \ 53 | v3.4beta033.html \ 54 | v3.4beta034.html \ 55 | v3.4beta035.html \ 56 | v3.4beta036.html \ 57 | v3.5.1.html \ 58 | v3.5.2.html \ 59 | v3.5.3.html \ 60 | v3.5.4.html \ 61 | v3.5.5.html \ 62 | v3.5.6-beta.html \ 63 | v3.5.7.html \ 64 | v3.6.0.html \ 65 | v3.6.1.html \ 66 | v3.7.0alpha.html \ 67 | v3.7.0beta.html \ 68 | v3.7.0beta2.html \ 69 | v3.7.0.html \ 70 | v3.7.1.html \ 71 | v3.7.2.html \ 72 | v3.7.3.html \ 73 | v3.7.4.html \ 74 | v3.8.0.html \ 75 | v3.8.1.html \ 76 | v3.8.2.html 77 | 78 | dist_doc_DATA = $(docfiles) 79 | 80 | SUBDIRS = images man 81 | 82 | -------------------------------------------------------------------------------- /html/bugs.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | Bugs and the TIFF Mailing List 4 | 5 | 6 | 7 |

8 | 9 | Bugs, Bugzilla, and the TIFF Mailing List 10 |

11 | 12 |

13 | This software is free. Please let us know when you find a problem or 14 | fix a bug. 15 | 16 |

17 | Thanks to remotesensing.org, libtiff now uses bugzilla to track bugs. 18 |

19 | If you think you've discovered a bug, please first check to see if it is 20 | already known by looking at the list of already reported bugs. You can do so 21 | by visiting the buglist at 22 | http://bugzilla.remotesensing.org/buglist.cgi?product=libtiff. Also verify that 23 | the problem is still reproducable with the current development software 24 | from CVS. 25 |

26 | If you'd like to enter a new bug, you can do so at http://bugzilla.remotesensing.org/enter_bug.cgi?product=libtiff. 27 |

28 | 29 | Of course, reporting bugs is no substitute for discussion. The 30 | tiff@lists.maptools.org mailing 31 | list is for users of this software, and discussion TIFF issues in general. 32 | It is managed with the Mailman software, and the web interface for subscribing 33 | and managing your access to the list is at:

34 | 35 | http://lists.maptools.org/mailman/listinfo/tiff

36 | 37 | Posts to the list are only accepted from members of the list in order 38 | to limit the amount of spam propagated. Also, to be approved as a member 39 | you will need to email the list administrator with a brief description of 40 | why you are interested in TIFF so we can weed out spammers.

41 | 42 | A Long Term 43 | Archive including recent messages, and most messages back to 1993, 44 | with search capabilities is available, and 45 | has been prepared and hosted by AWare 46 | Systems.

47 | 48 | 49 |


50 | 51 | Last updated: $Date: 2005/07/26 14:43:24 $ 52 | 53 | 54 | -------------------------------------------------------------------------------- /html/document.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | TIFF Documentation 5 | 6 | 7 | 8 | 9 |

10 | 11 | TIFF Documentation 12 |

13 | 14 |

15 | A copy of the 6.0 specification is available from Adobe at 16 | http://partners.adobe.com/public/developer/en/tiff/TIFF6.pdf, or from the libtiff 17 | ftp site at 18 | ftp://ftp.remotesensing.org/pub/libtiff/TIFF6.pdf.

19 | 20 |

21 | Draft TIFF Technical Note #2 covers problems 22 | with the TIFF 6.0 design for embedding JPEG-compressed data in TIFF, and 23 | describes an alternative.

24 | 25 | Other Adobe information on TIFF can be retrieved from: 26 | 27 | 28 | http://partners.adobe.com/public/developer/tiff/index.html 29 | 30 |

31 | Joris Van Damme maintains a list of known tags and their descriptions and 32 | definitions. It is available online at 33 | 34 | http://www.awaresystems.be/imaging/tiff/tifftags.html 35 | 36 |

37 | There is a FAQ, related both to TIFF format and libtiff library: 38 | 39 | http://www.awaresystems.be/imaging/tiff/faq.html 40 | 41 |

42 | There is a preliminary BigTIFF Design for 43 | a TIFF variation supporting files larger than 4GB. 44 | 45 |


46 | 47 |
48 | Last updated: $Date: 2004/12/02 14:51:19 $ 49 |
50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /html/images.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | TIFF Test Images 5 | 6 | 7 | 8 | 9 |

10 | 11 | TIFF Test Images 12 |

13 | 14 |

15 | Test images are available for most formats supported by the library. 16 | Most of the images included in the test kit are also part of this 17 | documentation (albeit in TIFF rather than GIF or JFIF). 18 | The images are kept in a separate archive that should be located in 19 | the same directory as this software. 20 | 21 |
22 | 23 |

24 | The latest archive of test images is located at 25 | 26 | ftp://ftp.remotesensing.org/pub/libtiff/pics-3.8.0.tar.gz 27 | 28 |

29 | There are two other good sources for TIFF test images: 30 | the contributed software contrib/dbs includes several 31 | programs that generate test images suitable for debugging, and 32 | the tiffcp program can be used to generate a variety 33 | of images with different storage characteristics. 34 | 35 |

36 |


37 | 38 | Last updated: $Date: 2006/01/02 23:50:44 $ 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /html/images/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | docdir = $(LIBTIFF_DOCDIR)/html/images 27 | 28 | docfiles = \ 29 | back.gif \ 30 | bali.jpg \ 31 | cat.gif \ 32 | cover.jpg \ 33 | cramps.gif \ 34 | dave.gif \ 35 | info.gif \ 36 | jello.jpg \ 37 | jim.gif \ 38 | note.gif \ 39 | oxford.gif \ 40 | quad.jpg \ 41 | ring.gif \ 42 | smallliz.jpg \ 43 | strike.gif \ 44 | warning.gif 45 | 46 | dist_doc_DATA = $(docfiles) 47 | -------------------------------------------------------------------------------- /html/images/back.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/back.gif -------------------------------------------------------------------------------- /html/images/bali.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/bali.jpg -------------------------------------------------------------------------------- /html/images/cat.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/cat.gif -------------------------------------------------------------------------------- /html/images/cover.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/cover.jpg -------------------------------------------------------------------------------- /html/images/cramps.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/cramps.gif -------------------------------------------------------------------------------- /html/images/dave.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/dave.gif -------------------------------------------------------------------------------- /html/images/info.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/info.gif -------------------------------------------------------------------------------- /html/images/jello.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/jello.jpg -------------------------------------------------------------------------------- /html/images/jim.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/jim.gif -------------------------------------------------------------------------------- /html/images/note.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/note.gif -------------------------------------------------------------------------------- /html/images/oxford.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/oxford.gif -------------------------------------------------------------------------------- /html/images/quad.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/quad.jpg -------------------------------------------------------------------------------- /html/images/ring.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/ring.gif -------------------------------------------------------------------------------- /html/images/smallliz.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/smallliz.jpg -------------------------------------------------------------------------------- /html/images/strike.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/strike.gif -------------------------------------------------------------------------------- /html/images/warning.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/LuaDist/libtiff/43d5bd6d2da90e9bf254cd42c377e4d99008f00b/html/images/warning.gif -------------------------------------------------------------------------------- /html/intro.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Introduction to the TIFF Documentation 5 | 6 | 7 | 8 | 9 |

10 | 11 | Introduction to the TIFF Documentation 12 |

13 | 14 | 15 |

16 | The following definitions are used throughout this documentation. 17 | They are consistent with the terminology used in the TIFF 6.0 specification. 18 | 19 |

20 |
Sample 21 |
The unit of information stored in an image; often called a 22 | channel elsewhere. Sample values are numbers, usually unsigned 23 | integers, but possibly in some other format if the SampleFormat 24 | tag is specified in a TIFF 25 |
Pixel 26 |
A collection of one or more samples that go together. 27 |
Row 28 |
An Nx1 rectangular collection of pixels. 29 |
Tile 30 |
An NxM rectangular organization of data (or pixels). 31 |
Strip 32 |
A tile whose width is the full image width. 33 |
Compression 34 |
A scheme by which pixel or sample data are stored in 35 | an encoded form, specifically with the intent of reducing the 36 | storage cost. 37 |
Codec 38 |
Software that implements the decoding and encoding algorithms 39 | of a compression scheme. 40 | 41 | 42 |

43 | In order to better understand how TIFF works (and consequently this 44 | software) it is important to recognize the distinction between the 45 | physical organization of image data as it is stored in a TIFF and how 46 | the data is interpreted and manipulated as pixels in an image. TIFF 47 | supports a wide variety of storage and data compression schemes that 48 | can be used to optimize retrieval time and/or minimize storage space. 49 | These on-disk formats are independent of the image characteristics; it 50 | is the responsibility of the TIFF reader to process the on-disk storage 51 | into an in-memory format suitable for an application. Furthermore, it 52 | is the responsibility of the application to properly interpret the 53 | visual characteristics of the image data. TIFF defines a framework for 54 | specifying the on-disk storage format and image characteristics with 55 | few restrictions. This permits significant complexity that can be 56 | daunting. Good applications that handle TIFF work by handling as wide 57 | a range of storage formats as possible, while constraining the 58 | acceptable image characteristics to those that make sense for the 59 | application. 60 | 61 | 62 |

63 |


64 | 65 | Last updated: $Date: 1999/08/09 20:21:21 $ 66 | 67 | 68 | 69 | -------------------------------------------------------------------------------- /html/man/TIFFClose.3tiff.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | TIFFClose 8 | 9 | 10 | 11 |

TIFFClose

12 | NAME
13 | SYNOPSIS
14 | DESCRIPTION
15 | DIAGNOSTICS
16 | SEE ALSO
17 | 18 |
19 | 20 |

NAME

21 | 22 | 24 | 25 | 26 | 30 |
27 |

TIFFClose − close a previously opened 28 | TIFF file

29 |
31 | 32 |

SYNOPSIS

33 | 34 | 36 | 37 | 38 | 43 |
39 |

#include <tiffio.h>

40 | 41 |

void TIFFClose(TIFF *tif)

42 |
44 | 45 |

DESCRIPTION

46 | 47 | 49 | 50 | 51 | 57 |
52 |

TIFFClose closes a file that was previously opened 53 | with TIFFOpen(3TIFF). Any buffered data are flushed 54 | to the file, including the contents of the current directory 55 | (if modified); and all resources are reclaimed.

56 |
58 | 59 |

DIAGNOSTICS

60 | 61 | 63 | 64 | 65 | 70 |
66 |

All error messages are directed to the routine. Likewise, 67 | warning messages are directed to the 68 | TIFFWarning(3TIFF) routine.

69 |
71 | 72 |

SEE ALSO

73 | 74 | 76 | 77 | 78 | 84 |
79 |

libtiff(3TIFF), TIFFOpen(3TIFF)

80 | 81 |

Libtiff library home page: 82 | http://www.remotesensing.org/libtiff/

83 |
85 |
86 | 87 | 88 | -------------------------------------------------------------------------------- /html/man/TIFFDataWidth.3tiff.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | TIFFDataWidth 8 | 9 | 10 | 11 |

TIFFDataWidth

12 | NAME
13 | SYNOPSIS
14 | DESCRIPTION
15 | RETURN VALUES
16 | SEE ALSO
17 | 18 |
19 | 20 |

NAME

21 | 22 | 24 | 25 | 26 | 29 |
27 |

TIFFDataWidth − Get the size of TIFF data types

28 |
30 | 31 |

SYNOPSIS

32 | 33 | 35 | 36 | 37 | 43 |
38 |

#include <tiffio.h>

39 | 40 |

int TIFFDataWidth(TIFFDataType 41 | type)

42 |
44 | 45 |

DESCRIPTION

46 | 47 | 49 | 50 | 51 | 68 |
52 |

TIFFDataWidth returns a size of type in 53 | bytes. Currently following data types are supported:
54 | TIFF_BYTE
55 | TIFF_ASCII
56 | TIFF_SBYTE
57 | TIFF_UNDEFINED
58 | TIFF_SHORT
59 | TIFF_SSHORT
60 | TIFF_LONG
61 | TIFF_SLONG
62 | TIFF_FLOAT
63 | TIFF_IFD
64 | TIFF_RATIONAL
65 | TIFF_SRATIONAL
66 | TIFF_DOUBLE

67 |
69 | 70 |

RETURN VALUES

71 | 72 | 74 | 75 | 76 | 81 |
77 |

TIFFDataWidth returns a number of bytes occupied 78 | by the item of given type. 0 returned when uknown data type 79 | supplied.

80 |
82 | 83 |

SEE ALSO

84 | 85 | 87 | 88 | 89 | 95 |
90 |

libtiff(3TIFF),

91 | 92 |

Libtiff library home page: 93 | http://www.remotesensing.org/libtiff/

94 |
96 |
97 | 98 | 99 | -------------------------------------------------------------------------------- /html/man/TIFFsize.3tiff.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | TIFFSIZE 8 | 9 | 10 | 11 |

TIFFSIZE

12 | NAME
13 | SYNOPSIS
14 | DESCRIPTION
15 | DIAGNOSTICS
16 | SEE ALSO
17 | 18 |
19 | 20 |

NAME

21 | 22 | 24 | 25 | 26 | 31 |
27 |

TIFFScanlineSize, TIFFRasterScanlineSize, − return 28 | the size of various items associated with an open 29 | TIFF file

30 |
32 | 33 |

SYNOPSIS

34 | 35 | 37 | 38 | 39 | 46 |
40 |

#include <tiffio.h>

41 | 42 |

tsize_t TIFFRasterScanlineSize(TIFF 43 | *tif)
44 | tsize_t TIFFScanlineSize(TIFF *
tif)

45 |
47 | 48 |

DESCRIPTION

49 | 50 | 52 | 53 | 54 | 66 |
55 |

TIFFScanlineSize returns the size in bytes of a 56 | row of data as it would be returned in a call to 57 | TIFFReadScanline, or as it would be expected in a 58 | call to TIFFWriteScanline.

59 | 60 |

TIFFRasterScanlineSize returns the size in bytes 61 | of a complete decoded and packed raster scanline. Note that 62 | this value may be different from the value returned by 63 | TIFFScanlineSize if data is stored as separate 64 | planes.

65 |
67 | 68 |

DIAGNOSTICS

69 | 70 | 72 | 73 | 74 | 77 |
75 |

None.

76 |
78 | 79 |

SEE ALSO

80 | 81 | 83 | 84 | 85 | 92 |
86 |

TIFFOpen(3TIFF), TIFFReadScanline(3TIFF), 87 | libtiff(3TIFF)

88 | 89 |

Libtiff library home page: 90 | http://www.remotesensing.org/libtiff/

91 |
93 |
94 | 95 | 96 | -------------------------------------------------------------------------------- /html/v3.4beta018.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta018 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

34 | 35 |


36 | 37 | CHANGES IN THE SOFTWARE CONFIGURATION: 38 | 39 |
    40 |
  • configure now recognizes IRIX 6.x systems 41 |
  • configure now uses ENVOPTS when searching for an ANSI 42 | C compiler; this fixes a problem configuring the software under 43 | HP/UX with the native C compiler 44 |
  • configure now correctly recognizes memory-mapped files are supported 45 | under AIX 46 |
47 | 48 |


49 | 50 | CHANGES IN LIBTIFF: 51 | 52 |
    53 |
  • make install now properly installs the include files 54 |
  • some portability fixes from Bjorn Brox 55 |
  • the G3/G4 codec now warns about decoded rows that are longer than 56 | the image/tile width 57 |
  • changes from Frank Cringle to make the library work with the 58 | gcc-specific bounds checking software 59 |
  • miscellaneous fixes to TIFFPrintDirectory 60 |
  • bug fix to correct a problem where TIFFWriteRawStrip 61 | could not be used to automatically grow an image's length 62 |
63 | 64 |


65 | 66 | CHANGES IN THE TOOLS: 67 | 68 |
    69 |
  • fixes from Frank Cringle to update fax2tiff 70 |
  • portability fixes to tiff2bw and tiffcmp 71 |
  • tiffdump now uses the byte swapping routines in the library 72 |
73 | 74 | TIFF home page.
75 | 76 |
77 | 78 |
79 | Sam Leffler / sam@engr.sgi.com 80 | Last updated $Date: 1999/08/09 20:21:21 $. 81 |
82 | 83 | 84 | 85 | -------------------------------------------------------------------------------- /html/v3.4beta029.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta029 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

34 | 35 |


36 | 37 | CHANGES IN THE SOFTWARE CONFIGURATION: 38 | 39 |
    40 |
  • configure now relativizes pathname references given in 41 | -L options (as frequently specified when configuring 42 | ancillary packages) 43 |
  • problems related to configuring the software on Ultrix 4.4 have 44 | been corrected 45 |
  • the shell to use in Makefiles and scripts can now be set with the 46 | SCRIPT_SH configuration parameter 47 |
  • comments in config.site now correctly indicate how to setup the 48 | use of ancillary packages 49 |
50 | 51 |


52 | 53 | CHANGES IN LIBTIFF: 54 | 55 |
    56 |
  • mods for building the software on a Mac using the 57 | MetroWerks CodeWarrior compilers 58 |
  • a bug in the CCITT T.4/T.6 decoder was fixed where the last codeword in 59 | a strip/tile might not be decoded; this was seen only when decoding 60 | multi-strip images 61 |
  • a bug in the CCITT RLE codecs was fixed whereby the pseudo tags were not 62 | being properly registered 63 |
64 | 65 |


66 | 67 | CHANGES IN THE CONTRIBUTED SOFTWARE: 68 | 69 |
    70 |
  • contrib/mac-cw contains information and code from Niles Ritter 71 | <ndr@tazboy.jpl.nasa.gov> 72 | about building the software with the MetroWerks CodeWarrior compilers 73 | on Macintosh systems 74 |
75 | 76 | TIFF home page.
77 | 78 |
79 | 80 |
81 | Sam Leffler / sam@engr.sgi.com 82 | Last updated $Date: 1999/08/09 20:21:21 $. 83 |
84 | 85 | 86 | 87 | -------------------------------------------------------------------------------- /html/v3.4beta032.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta032 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

35 | 36 |


37 | 38 | CHANGES IN THE SOFTWARE CONFIGURATION: 39 | 40 |
    41 |
  • various fixups and subtle improvements to configure 42 | from Richard Mlynarik 43 |
44 | 45 |


46 | 47 | CHANGES IN LIBTIFF: 48 | 49 |
    50 |
  • a new codec from Pixar designed for high-resolution color images; 51 | note that this codec is not configured by default 52 |
  • a bug fix for reading tags with a single FLOAT value 53 |
  • change to the TIFFGetField calling convention: 54 | a tag that has a single value of 55 | type DOUBLE is now retrieved by passing a 56 | ``double*'' instead of a 57 | ``double**'' (this change makes the handling of tags with 58 | DOUBLE values identical to the handling of tags with 59 | FLOAT values) 60 |
  • fix to VMS support for the handling of floating point values 61 |
62 | 63 |


64 | 65 | CHANGES IN THE TOOLS: 66 | 67 |
    68 |
  • tiffdump now handles tags with FLOAT and DOUBLE 69 | values 70 |
71 | 72 |


73 | 74 | CHANGES IN THE CONTRIBUTED SOFTWARE: 75 | 76 |
    77 |
  • updates to the Acorn OS support from Peter Greenham 78 |
79 | 80 | TIFF home page.
81 | 82 |
83 | 84 |
85 | Sam Leffler / sam@engr.sgi.com 86 | Last updated $Date: 1999/08/09 20:21:21 $. 87 |
88 | 89 | 90 | 91 | -------------------------------------------------------------------------------- /html/v3.4beta033.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta033 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

35 | 36 |


37 | 38 | CHANGES IN THE SOFTWARE CONFIGURATION: 39 | 40 |
    41 |
  • support was added for building the library as a DSO under OSF/1 42 |
43 | 44 |


45 | 46 | CHANGES IN LIBTIFF: 47 | 48 |
    49 |
  • fixes to the Pixar codec 50 |
  • portability mods for VMS 51 |
52 | 53 |


54 | 55 | CHANGES IN THE TOOLS: 56 | 57 |
    58 |
  • fixes to gif2tiff and ppm2tiff for building under MS/DOS 59 |
  • portability mods to fax2ps and ycbcr for VMS 60 |
61 | 62 |


63 | 64 | CHANGES IN THE CONTRIBUTED SOFTWARE: 65 | 66 |
    67 |
  • a new package from Alexander Lehmann 68 | for building the library and tools under MS/DOS with DJGPP v2 69 |
  • updated VMS support from Karsten Spang 70 |
71 | 72 | TIFF home page.
73 | 74 |
75 | 76 |
77 | Sam Leffler / sam@engr.sgi.com 78 | Last updated $Date: 1999/08/09 20:21:21 $. 79 |
80 | 81 | 82 | 83 | -------------------------------------------------------------------------------- /html/v3.4beta034.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta034 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

33 | 34 |


35 | 36 | CHANGES IN THE SOFTWARE CONFIGURATION: 37 | 38 |
    39 |
  • support was added for building the library as a DSO under NetBSD 40 |
  • a bug was fixed in the DSO support for Linux 41 |
  • the handling of version strings has changed slightly to simplify parsing 42 |
  • a new parameter, TIFFLIBREF, was added to control how the 43 | library is referenced when linking programs in the tools directory 44 |
45 | 46 |


47 | 48 | CHANGES IN LIBTIFF: 49 | 50 |
    51 |
  • DSO creation under Solaris now forces the DSO name with a -h option 52 |
  • the interface to the mkversion program was changed 53 | to eliminate the need to parse files 54 |
  • a bug was fixed in the EOL-detection logic of the T.4/T.6 decoder 55 |
  • ANSI IT8 TIFF/IT tag definitions were added to tiff.h 56 |
57 | 58 | TIFF home page.
59 | 60 |
61 | 62 |
63 | Sam Leffler / sam@engr.sgi.com 64 | Last updated $Date: 1999/08/09 20:21:21 $. 65 |
66 | 67 | 68 | 69 | -------------------------------------------------------------------------------- /html/v3.4beta035.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.4beta035 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | TIFF CHANGE INFORMATION 13 | 14 | 15 | 22 | 23 |

24 | This document describes the changes made to the software between the 25 | previous and current versions (see above). 26 | If you don't find something listed here, then it was not done in this 27 | timeframe, or it was not considered important enough to be mentioned. 28 | The following information is located here: 29 |

33 | 34 |


35 | 36 | CHANGES IN THE SOFTWARE CONFIGURATION: 37 | 38 |
    39 |
  • support was added installing the HTML documentation 40 |
  • support was added for building the library as a DSO under FreeBSD 41 |
42 | 43 |


44 | 45 | CHANGES IN LIBTIFF: 46 | 47 |
    48 |
  • the interface to the mkversion program was restored to 49 | the form used prior to v3.4beta034 50 |
  • several portability problems for 16-bit systems were fixed 51 |
52 | 53 | TIFF home page.
54 | 55 |
56 | 57 |
58 | Sam Leffler / sam@engr.sgi.com 59 | Last updated $Date: 1999/08/09 20:21:21 $. 60 |
61 | 62 | 63 | 64 | -------------------------------------------------------------------------------- /html/v3.5.1.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.5.1 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | TIFF CHANGE INFORMATION 14 | 15 | 16 | 36 | 37 |


38 | 39 | CHANGES IN THE SOFTWARE CONFIGURATION: 40 | 41 |
    42 |
  • None of consequence 43 |
44 | 45 |


46 | 47 | CHANGES IN LIBTIFF: 48 | 49 | 50 |
    51 |
  • Support was added for IPTC Newsphoto metadata (TIFFTAGE_IPTCNEWSPHOTO) 52 |
  • Support was added for photoshop caption handling (TIFFTAG_PHOTOSHOP) 53 |
54 | 55 |


56 | 57 | CHANGES IN THE TOOLS: 58 | 59 |
    60 |
  • Bill Radcliffe's iptcutil was 61 | added to the "contrib" subdirectory . It can convert an IPTC binary 62 | blob to ASCII text and vice-versa. The blob itself can be extracted 63 | from or added to an image with the ImageMagick convert(1) 65 | utility. 66 |
67 | 68 | TIFF home page.
69 | 70 |
71 | 72 | Last updated $Date: 2006/01/03 01:42:30 $. 73 | 74 | 75 | 76 | -------------------------------------------------------------------------------- /html/v3.5.4.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Changes in TIFF v3.5.4 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | TIFF CHANGE INFORMATION 14 | 15 | 16 | 24 | 25 |

26 | This document describes the changes made to the software between the 27 | previous and current versions (see above). 28 | If you don't find something listed here, then it was not done in this 29 | timeframe, or it was not considered important enough to be mentioned. 30 | The following information is located here: 31 |

36 |

37 |


38 | 39 | CHANGES IN THE SOFTWARE CONFIGURATION: 40 | 41 |
    42 |
  • None 43 | 44 | 45 |
46 | 47 |


48 | 49 | CHANGES IN LIBTIFF: 50 | 51 | 52 |
    53 | 54 |
  • Added Pixar tag support. Contributed by Phil Beffery 55 | 56 |
  • Made one more change to tif_dir.c for removal of LZW compression. Also added notice 57 | when LZW compression invoked. 58 | 59 |
  • Fixed bug that caused LZW (non) compression to segfault. Added 60 | warning about LZW compression removed being removed, and why. 61 | 62 |
63 | 64 |


65 | 66 | CHANGES IN THE TOOLS: 67 | 68 |
    69 |
  • Changed default compression in tools to TIFF_PACKBITS, and changed usage descriptions 70 | in tools to reflect removal of LZW compression 71 | 72 |
  • Added nostrip to install in tools/Makefile.in so that debugging 73 | symbols are kept. 74 | 75 |
  • Made Packbits the default compression in tools/tiff2rgba.c instead 76 | of LZW. 77 | 78 | 79 |
80 | 81 | TIFF home page.
82 | 83 |
84 | 85 | Last updated $Date: 2006/01/03 01:45:41 $. 86 | 87 | 88 | 89 | -------------------------------------------------------------------------------- /libtiff/Makefile.vc: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.vc,v 1.15 2006/03/23 14:54:02 dron Exp $ 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | # 24 | # Makefile for MS Visual C and Watcom C compilers. 25 | # 26 | # To build: 27 | # C:\libtiff\libtiff> nmake /f makefile.vc all 28 | # 29 | 30 | !INCLUDE ..\nmake.opt 31 | 32 | INCL = -I. $(JPEG_INCLUDE) $(ZLIB_INCLUDE) 33 | 34 | !IFDEF USE_WIN_CRT_LIB 35 | OBJ_SYSDEP_MODULE = tif_unix.obj 36 | !ELSE 37 | OBJ_SYSDEP_MODULE = tif_win32.obj 38 | !ENDIF 39 | 40 | OBJ = \ 41 | tif_aux.obj \ 42 | tif_close.obj \ 43 | tif_codec.obj \ 44 | tif_color.obj \ 45 | tif_compress.obj \ 46 | tif_dir.obj \ 47 | tif_dirinfo.obj \ 48 | tif_dirread.obj \ 49 | tif_dirwrite.obj \ 50 | tif_dumpmode.obj \ 51 | tif_error.obj \ 52 | tif_extension.obj \ 53 | tif_fax3.obj \ 54 | tif_fax3sm.obj \ 55 | tif_getimage.obj \ 56 | tif_jpeg.obj \ 57 | tif_ojpeg.obj \ 58 | tif_flush.obj \ 59 | tif_luv.obj \ 60 | tif_lzw.obj \ 61 | tif_next.obj \ 62 | tif_open.obj \ 63 | tif_packbits.obj \ 64 | tif_pixarlog.obj \ 65 | tif_predict.obj \ 66 | tif_print.obj \ 67 | tif_read.obj \ 68 | tif_stream.obj \ 69 | tif_swab.obj \ 70 | tif_strip.obj \ 71 | tif_thunder.obj \ 72 | tif_tile.obj \ 73 | tif_version.obj \ 74 | tif_warning.obj \ 75 | tif_write.obj \ 76 | tif_zip.obj \ 77 | $(OBJ_SYSDEP_MODULE) 78 | 79 | all: libtiff.lib $(DLLNAME) 80 | 81 | tif_config.h: tif_config.h.vc 82 | copy tif_config.h.vc tif_config.h 83 | 84 | tiffconf.h: tiffconf.h.vc 85 | copy tiffconf.h.vc tiffconf.h 86 | 87 | libtiff.lib: tif_config.h tiffconf.h $(OBJ) 88 | $(AR) /out:libtiff.lib $(OBJ) $(LIBS) 89 | 90 | $(DLLNAME): tif_config.h tiffconf.h libtiff.def $(OBJ) 91 | $(LD) /debug /dll /def:libtiff.def /out:$(DLLNAME) \ 92 | /implib:libtiff_i.lib $(OBJ) $(LIBS) 93 | 94 | clean: 95 | -del *.obj 96 | -del *.lib 97 | -del *.dll 98 | -del *.exe 99 | -------------------------------------------------------------------------------- /libtiff/SConstruct: -------------------------------------------------------------------------------- 1 | # $Id: SConstruct,v 1.2 2006/03/23 14:54:02 dron Exp $ 2 | 3 | # Tag Image File Format (TIFF) Software 4 | # 5 | # Copyright (C) 2005, Andrey Kiselev 6 | # 7 | # Permission to use, copy, modify, distribute, and sell this software and 8 | # its documentation for any purpose is hereby granted without fee, provided 9 | # that (i) the above copyright notices and this permission notice appear in 10 | # all copies of the software and related documentation, and (ii) the names of 11 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | # publicity relating to the software without the specific, prior written 13 | # permission of Sam Leffler and Silicon Graphics. 14 | # 15 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | # 19 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | # OF THIS SOFTWARE. 25 | 26 | # This file contains rules to build software with the SCons tool 27 | # (see the http://www.scons.org/ for details on SCons). 28 | 29 | # Import globally defined options 30 | Import([ 'env', 'idir_lib' ]) 31 | 32 | SRCS = [ \ 33 | 'tif_aux.c', \ 34 | 'tif_close.c', \ 35 | 'tif_codec.c', \ 36 | 'tif_color.c', \ 37 | 'tif_compress.c', \ 38 | 'tif_dir.c', \ 39 | 'tif_dirinfo.c', \ 40 | 'tif_dirread.c', \ 41 | 'tif_dirwrite.c', \ 42 | 'tif_dumpmode.c', \ 43 | 'tif_error.c', \ 44 | 'tif_extension.c', \ 45 | 'tif_fax3.c', \ 46 | 'tif_fax3sm.c', \ 47 | 'tif_flush.c', \ 48 | 'tif_getimage.c', \ 49 | 'tif_jpeg.c', \ 50 | 'tif_luv.c', \ 51 | 'tif_lzw.c', \ 52 | 'tif_next.c', \ 53 | 'tif_ojpeg.c', \ 54 | 'tif_open.c', \ 55 | 'tif_packbits.c', \ 56 | 'tif_pixarlog.c', \ 57 | 'tif_predict.c', \ 58 | 'tif_print.c', \ 59 | 'tif_read.c', \ 60 | 'tif_strip.c', \ 61 | 'tif_swab.c', \ 62 | 'tif_thunder.c', \ 63 | 'tif_tile.c', \ 64 | 'tif_unix.c', \ 65 | 'tif_version.c', \ 66 | 'tif_warning.c', \ 67 | 'tif_write.c', \ 68 | 'tif_zip.c' ] 69 | 70 | StaticLibrary('tiff', SRCS) 71 | SharedLibrary('tiff', SRCS) 72 | -------------------------------------------------------------------------------- /libtiff/tif_config.h.vc: -------------------------------------------------------------------------------- 1 | /* Define to 1 if you have the header file. */ 2 | #define HAVE_ASSERT_H 1 3 | 4 | /* Define to 1 if you have the header file. */ 5 | #define HAVE_FCNTL_H 1 6 | 7 | /* Define as 0 or 1 according to the floating point format suported by the 8 | machine */ 9 | #define HAVE_IEEEFP 1 10 | 11 | /* Define to 1 if you have the header file. */ 12 | #define HAVE_STRING_H 1 13 | 14 | /* Define to 1 if you have the header file. */ 15 | #define HAVE_SYS_TYPES_H 1 16 | 17 | /* Define to 1 if you have the header file. */ 18 | #define HAVE_IO_H 1 19 | 20 | /* Define to 1 if you have the header file. */ 21 | #define HAVE_SEARCH_H 1 22 | 23 | /* The size of a `int', as computed by sizeof. */ 24 | #define SIZEOF_INT 4 25 | 26 | /* The size of a `long', as computed by sizeof. */ 27 | #define SIZEOF_LONG 4 28 | 29 | /* Set the native cpu bit order */ 30 | #define HOST_FILLORDER FILLORDER_LSB2MSB 31 | 32 | /* Define to 1 if your processor stores words with the most significant byte 33 | first (like Motorola and SPARC, unlike Intel and VAX). */ 34 | /* #undef WORDS_BIGENDIAN */ 35 | 36 | /* Define to `__inline__' or `__inline' if that's what the C compiler 37 | calls it, or to nothing if 'inline' is not supported under any name. */ 38 | #ifndef __cplusplus 39 | # ifndef inline 40 | # define inline __inline 41 | # endif 42 | #endif 43 | 44 | #define lfind _lfind 45 | -------------------------------------------------------------------------------- /libtiff/tif_error.c: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_error.c,v 1.4 2005/12/23 01:18:59 joris Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1988-1997 Sam Leffler 5 | * Copyright (c) 1991-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | /* 28 | * TIFF Library. 29 | */ 30 | #include "tiffiop.h" 31 | 32 | TIFFErrorHandlerExt _TIFFerrorHandlerExt = NULL; 33 | 34 | TIFFErrorHandler 35 | TIFFSetErrorHandler(TIFFErrorHandler handler) 36 | { 37 | TIFFErrorHandler prev = _TIFFerrorHandler; 38 | _TIFFerrorHandler = handler; 39 | return (prev); 40 | } 41 | 42 | TIFFErrorHandlerExt 43 | TIFFSetErrorHandlerExt(TIFFErrorHandlerExt handler) 44 | { 45 | TIFFErrorHandlerExt prev = _TIFFerrorHandlerExt; 46 | _TIFFerrorHandlerExt = handler; 47 | return (prev); 48 | } 49 | 50 | void 51 | TIFFError(const char* module, const char* fmt, ...) 52 | { 53 | va_list ap; 54 | va_start(ap, fmt); 55 | if (_TIFFerrorHandler) 56 | (*_TIFFerrorHandler)(module, fmt, ap); 57 | if (_TIFFerrorHandlerExt) 58 | (*_TIFFerrorHandlerExt)(0, module, fmt, ap); 59 | va_end(ap); 60 | } 61 | 62 | void 63 | TIFFErrorExt(thandle_t fd, const char* module, const char* fmt, ...) 64 | { 65 | va_list ap; 66 | va_start(ap, fmt); 67 | if (_TIFFerrorHandler) 68 | (*_TIFFerrorHandler)(module, fmt, ap); 69 | if (_TIFFerrorHandlerExt) 70 | (*_TIFFerrorHandlerExt)(fd, module, fmt, ap); 71 | va_end(ap); 72 | } 73 | 74 | -------------------------------------------------------------------------------- /libtiff/tif_flush.c: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_flush.c,v 1.3 2000/09/15 20:52:42 warmerda Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1988-1997 Sam Leffler 5 | * Copyright (c) 1991-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | /* 28 | * TIFF Library. 29 | */ 30 | #include "tiffiop.h" 31 | 32 | int 33 | TIFFFlush(TIFF* tif) 34 | { 35 | 36 | if (tif->tif_mode != O_RDONLY) { 37 | if (!TIFFFlushData(tif)) 38 | return (0); 39 | if ((tif->tif_flags & TIFF_DIRTYDIRECT) && 40 | !TIFFWriteDirectory(tif)) 41 | return (0); 42 | } 43 | return (1); 44 | } 45 | 46 | /* 47 | * Flush buffered data to the file. 48 | * 49 | * Frank Warmerdam'2000: I modified this to return 1 if TIFF_BEENWRITING 50 | * is not set, so that TIFFFlush() will proceed to write out the directory. 51 | * The documentation says returning 1 is an error indicator, but not having 52 | * been writing isn't exactly a an error. Hopefully this doesn't cause 53 | * problems for other people. 54 | */ 55 | int 56 | TIFFFlushData(TIFF* tif) 57 | { 58 | if ((tif->tif_flags & TIFF_BEENWRITING) == 0) 59 | return (0); 60 | if (tif->tif_flags & TIFF_POSTENCODE) { 61 | tif->tif_flags &= ~TIFF_POSTENCODE; 62 | if (!(*tif->tif_postencode)(tif)) 63 | return (0); 64 | } 65 | return (TIFFFlushData1(tif)); 66 | } 67 | 68 | -------------------------------------------------------------------------------- /libtiff/tif_predict.h: -------------------------------------------------------------------------------- 1 | /* $Id: tif_predict.h,v 1.3 2006/03/03 14:10:09 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1995-1997 Sam Leffler 5 | * Copyright (c) 1995-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | #ifndef _TIFFPREDICT_ 28 | #define _TIFFPREDICT_ 29 | /* 30 | * ``Library-private'' Support for the Predictor Tag 31 | */ 32 | 33 | /* 34 | * Codecs that want to support the Predictor tag must place 35 | * this structure first in their private state block so that 36 | * the predictor code can cast tif_data to find its state. 37 | */ 38 | typedef struct { 39 | int predictor; /* predictor tag value */ 40 | int stride; /* sample stride over data */ 41 | tsize_t rowsize; /* tile/strip row size */ 42 | 43 | TIFFPostMethod pfunc; /* horizontal differencer/accumulator */ 44 | TIFFCodeMethod coderow; /* parent codec encode/decode row */ 45 | TIFFCodeMethod codestrip; /* parent codec encode/decode strip */ 46 | TIFFCodeMethod codetile; /* parent codec encode/decode tile */ 47 | TIFFVGetMethod vgetparent; /* super-class method */ 48 | TIFFVSetMethod vsetparent; /* super-class method */ 49 | TIFFPrintMethod printdir; /* super-class method */ 50 | TIFFBoolMethod setupdecode; /* super-class method */ 51 | TIFFBoolMethod setupencode; /* super-class method */ 52 | } TIFFPredictorState; 53 | 54 | #if defined(__cplusplus) 55 | extern "C" { 56 | #endif 57 | extern int TIFFPredictorInit(TIFF*); 58 | extern int TIFFPredictorCleanup(TIFF*); 59 | #if defined(__cplusplus) 60 | } 61 | #endif 62 | #endif /* _TIFFPREDICT_ */ 63 | 64 | /* vim: set ts=8 sts=8 sw=8 noet: */ 65 | -------------------------------------------------------------------------------- /libtiff/tif_version.c: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_version.c,v 1.2 2000/11/13 14:42:38 warmerda Exp $ */ 2 | /* 3 | * Copyright (c) 1992-1997 Sam Leffler 4 | * Copyright (c) 1992-1997 Silicon Graphics, Inc. 5 | * 6 | * Permission to use, copy, modify, distribute, and sell this software and 7 | * its documentation for any purpose is hereby granted without fee, provided 8 | * that (i) the above copyright notices and this permission notice appear in 9 | * all copies of the software and related documentation, and (ii) the names of 10 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | * publicity relating to the software without the specific, prior written 12 | * permission of Sam Leffler and Silicon Graphics. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | * 18 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | * OF THIS SOFTWARE. 24 | */ 25 | #include "tiffiop.h" 26 | 27 | static const char TIFFVersion[] = TIFFLIB_VERSION_STR; 28 | 29 | const char* 30 | TIFFGetVersion(void) 31 | { 32 | return (TIFFVersion); 33 | } 34 | -------------------------------------------------------------------------------- /libtiff/tif_warning.c: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/libtiff/tif_warning.c,v 1.2 2005/12/23 01:18:59 joris Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1988-1997 Sam Leffler 5 | * Copyright (c) 1991-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | /* 28 | * TIFF Library. 29 | */ 30 | #include "tiffiop.h" 31 | 32 | TIFFErrorHandlerExt _TIFFwarningHandlerExt = NULL; 33 | 34 | TIFFErrorHandler 35 | TIFFSetWarningHandler(TIFFErrorHandler handler) 36 | { 37 | TIFFErrorHandler prev = _TIFFwarningHandler; 38 | _TIFFwarningHandler = handler; 39 | return (prev); 40 | } 41 | 42 | TIFFErrorHandlerExt 43 | TIFFSetWarningHandlerExt(TIFFErrorHandlerExt handler) 44 | { 45 | TIFFErrorHandlerExt prev = _TIFFwarningHandlerExt; 46 | _TIFFwarningHandlerExt = handler; 47 | return (prev); 48 | } 49 | 50 | void 51 | TIFFWarning(const char* module, const char* fmt, ...) 52 | { 53 | va_list ap; 54 | va_start(ap, fmt); 55 | if (_TIFFwarningHandler) 56 | (*_TIFFwarningHandler)(module, fmt, ap); 57 | if (_TIFFwarningHandlerExt) 58 | (*_TIFFwarningHandlerExt)(0, module, fmt, ap); 59 | va_end(ap); 60 | } 61 | 62 | void 63 | TIFFWarningExt(thandle_t fd, const char* module, const char* fmt, ...) 64 | { 65 | va_list ap; 66 | va_start(ap, fmt); 67 | if (_TIFFwarningHandler) 68 | (*_TIFFwarningHandler)(module, fmt, ap); 69 | if (_TIFFwarningHandlerExt) 70 | (*_TIFFwarningHandlerExt)(fd, module, fmt, ap); 71 | va_end(ap); 72 | } 73 | 74 | 75 | -------------------------------------------------------------------------------- /libtiff/tiffconf.h.vc: -------------------------------------------------------------------------------- 1 | /* 2 | Configuration defines for installed libtiff. 3 | This file maintained for backward compatibility. Do not use definitions 4 | from this file in your programs. 5 | */ 6 | 7 | #ifndef _TIFFCONF_ 8 | #define _TIFFCONF_ 9 | 10 | /* Define to 1 if the system has the type `int16'. */ 11 | /* #undef HAVE_INT16 */ 12 | 13 | /* Define to 1 if the system has the type `int32'. */ 14 | /* #undef HAVE_INT32 */ 15 | 16 | /* Define to 1 if the system has the type `int8'. */ 17 | /* #undef HAVE_INT8 */ 18 | 19 | /* The size of a `int', as computed by sizeof. */ 20 | #define SIZEOF_INT 4 21 | 22 | /* The size of a `long', as computed by sizeof. */ 23 | #define SIZEOF_LONG 4 24 | 25 | /* Compatibility stuff. */ 26 | 27 | /* Define as 0 or 1 according to the floating point format suported by the 28 | machine */ 29 | #define HAVE_IEEEFP 1 30 | 31 | /* Set the native cpu bit order (FILLORDER_LSB2MSB or FILLORDER_MSB2LSB) */ 32 | #define HOST_FILLORDER FILLORDER_LSB2MSB 33 | 34 | /* Native cpu byte order: 1 if big-endian (Motorola) or 0 if little-endian 35 | (Intel) */ 36 | #define HOST_BIGENDIAN 0 37 | 38 | /* Support CCITT Group 3 & 4 algorithms */ 39 | #define CCITT_SUPPORT 1 40 | 41 | /* Support JPEG compression (requires IJG JPEG library) */ 42 | /* #undef JPEG_SUPPORT */ 43 | 44 | /* Support LogLuv high dynamic range encoding */ 45 | #define LOGLUV_SUPPORT 1 46 | 47 | /* Support LZW algorithm */ 48 | #define LZW_SUPPORT 1 49 | 50 | /* Support NeXT 2-bit RLE algorithm */ 51 | #define NEXT_SUPPORT 1 52 | 53 | /* Support Old JPEG compresson (read contrib/ojpeg/README first! Compilation 54 | fails with unpatched IJG JPEG library) */ 55 | /* #undef OJPEG_SUPPORT */ 56 | 57 | /* Support Macintosh PackBits algorithm */ 58 | #define PACKBITS_SUPPORT 1 59 | 60 | /* Support Pixar log-format algorithm (requires Zlib) */ 61 | /* #undef PIXARLOG_SUPPORT */ 62 | 63 | /* Support ThunderScan 4-bit RLE algorithm */ 64 | #define THUNDER_SUPPORT 1 65 | 66 | /* Support Deflate compression */ 67 | /* #undef ZIP_SUPPORT */ 68 | 69 | /* Support strip chopping (whether or not to convert single-strip uncompressed 70 | images to mutiple strips of ~8Kb to reduce memory usage) */ 71 | #define STRIPCHOP_DEFAULT TIFF_STRIPCHOP 72 | 73 | /* Enable SubIFD tag (330) support */ 74 | #define SUBIFD_SUPPORT 1 75 | 76 | /* Treat extra sample as alpha (default enabled). The RGBA interface will 77 | treat a fourth sample with no EXTRASAMPLE_ value as being ASSOCALPHA. Many 78 | packages produce RGBA files but don't mark the alpha properly. */ 79 | #define DEFAULT_EXTRASAMPLE_AS_ALPHA 1 80 | 81 | /* Pick up YCbCr subsampling info from the JPEG data stream to support files 82 | lacking the tag (default enabled). */ 83 | #define CHECK_JPEG_YCBCR_SUBSAMPLING 1 84 | 85 | /* 86 | * Feature support definitions. 87 | * XXX: These macros are obsoleted. Don't use them in your apps! 88 | * Macros stays here for backward compatibility and should be always defined. 89 | */ 90 | #define COLORIMETRY_SUPPORT 91 | #define YCBCR_SUPPORT 92 | #define CMYK_SUPPORT 93 | #define ICC_SUPPORT 94 | #define PHOTOSHOP_SUPPORT 95 | #define IPTC_SUPPORT 96 | 97 | #endif /* _TIFFCONF_ */ 98 | -------------------------------------------------------------------------------- /libtiff/tiffio.hxx: -------------------------------------------------------------------------------- 1 | /* $Id: tiffio.hxx,v 1.1 2004/11/21 16:12:08 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1988-1997 Sam Leffler 5 | * Copyright (c) 1991-1997 Silicon Graphics, Inc. 6 | * 7 | * Permission to use, copy, modify, distribute, and sell this software and 8 | * its documentation for any purpose is hereby granted without fee, provided 9 | * that (i) the above copyright notices and this permission notice appear in 10 | * all copies of the software and related documentation, and (ii) the names of 11 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 12 | * publicity relating to the software without the specific, prior written 13 | * permission of Sam Leffler and Silicon Graphics. 14 | * 15 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 16 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 17 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 18 | * 19 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 20 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 21 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 22 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 23 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 24 | * OF THIS SOFTWARE. 25 | */ 26 | 27 | #ifndef _TIFFIO_HXX_ 28 | #define _TIFFIO_HXX_ 29 | 30 | /* 31 | * TIFF I/O library definitions which provide C++ streams API. 32 | */ 33 | 34 | #include 35 | #include "tiff.h" 36 | 37 | extern TIFF* TIFFStreamOpen(const char*, std::ostream *); 38 | extern TIFF* TIFFStreamOpen(const char*, std::istream *); 39 | 40 | #endif /* _TIFFIO_HXX_ */ 41 | 42 | /* vim: set ts=8 sts=8 sw=8 noet: */ 43 | -------------------------------------------------------------------------------- /libtiff/tiffvers.h: -------------------------------------------------------------------------------- 1 | #define TIFFLIB_VERSION_STR "LIBTIFF, Version 3.8.2\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc." 2 | /* 3 | * This define can be used in code that requires 4 | * compilation-related definitions specific to a 5 | * version or versions of the library. Runtime 6 | * version checking should be done based on the 7 | * string returned by TIFFGetVersion. 8 | */ 9 | #define TIFFLIB_VERSION 20060323 10 | -------------------------------------------------------------------------------- /m4/ltversion.m4: -------------------------------------------------------------------------------- 1 | # ltversion.m4 -- version numbers -*- Autoconf -*- 2 | # 3 | # Copyright (C) 2004 Free Software Foundation, Inc. 4 | # Written by Scott James Remnant. 5 | # 6 | ## This file is free software; the Free Software Foundation gives 7 | # unlimited permission to copy and/or distribute it, with or without 8 | # modifications, as long as this notice is preserved. 9 | 10 | # Generated from ltversion.in; do not edit by hand 11 | 12 | # serial 2248 ltversion.m4 13 | # This file is part of GNU Libtool 14 | 15 | m4_define([LT_PACKAGE_VERSION], [2.1a]) 16 | m4_define([LT_PACKAGE_REVISION], [1.2248]) 17 | 18 | AC_DEFUN([LTVERSION_VERSION], 19 | [macro_version='2.1a' 20 | macro_revision='1.2248' 21 | _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 22 | _LT_DECL(, macro_revision, 0) 23 | ]) 24 | -------------------------------------------------------------------------------- /man/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | dist_man1_MANS = \ 27 | bmp2tiff.1 \ 28 | fax2ps.1 \ 29 | fax2tiff.1 \ 30 | gif2tiff.1 \ 31 | pal2rgb.1 \ 32 | ppm2tiff.1 \ 33 | ras2tiff.1 \ 34 | raw2tiff.1 \ 35 | rgb2ycbcr.1 \ 36 | sgi2tiff.1 \ 37 | thumbnail.1 \ 38 | tiff2bw.1 \ 39 | tiff2pdf.1 \ 40 | tiff2ps.1 \ 41 | tiff2rgba.1 \ 42 | tiffcmp.1 \ 43 | tiffcp.1 \ 44 | tiffdither.1 \ 45 | tiffdump.1 \ 46 | tiffgt.1 \ 47 | tiffinfo.1 \ 48 | tiffmedian.1 \ 49 | tiffset.1 \ 50 | tiffsplit.1 \ 51 | tiffsv.1 52 | 53 | dist_man3_MANS = \ 54 | libtiff.3tiff \ 55 | TIFFbuffer.3tiff \ 56 | TIFFClose.3tiff \ 57 | TIFFcodec.3tiff \ 58 | TIFFcolor.3tiff \ 59 | TIFFDataWidth.3tiff \ 60 | TIFFError.3tiff \ 61 | TIFFFlush.3tiff \ 62 | TIFFGetField.3tiff \ 63 | TIFFmemory.3tiff \ 64 | TIFFOpen.3tiff \ 65 | TIFFPrintDirectory.3tiff \ 66 | TIFFquery.3tiff \ 67 | TIFFReadDirectory.3tiff \ 68 | TIFFReadEncodedStrip.3tiff \ 69 | TIFFReadEncodedTile.3tiff \ 70 | TIFFReadRawStrip.3tiff \ 71 | TIFFReadRawTile.3tiff \ 72 | TIFFReadRGBAImage.3tiff \ 73 | TIFFReadRGBAStrip.3tiff \ 74 | TIFFReadRGBATile.3tiff \ 75 | TIFFReadScanline.3tiff \ 76 | TIFFReadTile.3tiff \ 77 | TIFFRGBAImage.3tiff \ 78 | TIFFSetDirectory.3tiff \ 79 | TIFFSetField.3tiff \ 80 | TIFFsize.3tiff \ 81 | TIFFstrip.3tiff \ 82 | TIFFswab.3tiff \ 83 | TIFFtile.3tiff \ 84 | TIFFWarning.3tiff \ 85 | TIFFWriteDirectory.3tiff \ 86 | TIFFWriteEncodedStrip.3tiff \ 87 | TIFFWriteEncodedTile.3tiff \ 88 | TIFFWriteRawStrip.3tiff \ 89 | TIFFWriteRawTile.3tiff \ 90 | TIFFWriteScanline.3tiff \ 91 | TIFFWriteTile.3tiff 92 | -------------------------------------------------------------------------------- /man/TIFFClose.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFClose.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFClose 3TIFF "November 2, 2005" "libtiff" 27 | .SH NAME 28 | TIFFClose \- close a previously opened 29 | .SM TIFF 30 | file 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "void TIFFClose(TIFF *" tif ")" 35 | .SH DESCRIPTION 36 | .IR TIFFClose 37 | closes a file that was previously opened with 38 | .BR TIFFOpen (3TIFF). 39 | Any buffered data are flushed to the file, including the contents of the 40 | current directory (if modified); and all resources are reclaimed. 41 | .SH DIAGNOSTICS 42 | All error messages are directed to the 43 | .bR TIFFError (3TIFF) 44 | routine. 45 | Likewise, warning messages are directed to the 46 | .BR TIFFWarning (3TIFF) 47 | routine. 48 | .SH "SEE ALSO" 49 | .BR libtiff (3TIFF), 50 | .BR TIFFOpen (3TIFF) 51 | .PP 52 | Libtiff library home page: 53 | .BR http://www.remotesensing.org/libtiff/ 54 | -------------------------------------------------------------------------------- /man/TIFFDataWidth.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFDataWidth.3tiff,v 1.3 2006/03/23 14:54:02 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 2002, Andrey Kiselev 4 | .\" 5 | .\" Permission to use, copy, modify, distribute, and sell this software and 6 | .\" its documentation for any purpose is hereby granted without fee, provided 7 | .\" that (i) the above copyright notices and this permission notice appear in 8 | .\" all copies of the software and related documentation, and (ii) the names of 9 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | .\" publicity relating to the software without the specific, prior written 11 | .\" permission of Sam Leffler and Silicon Graphics. 12 | .\" 13 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | .\" 17 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | .\" OF THIS SOFTWARE. 23 | .\" 24 | .if n .po 0 25 | .TH TIFFDataWidth 3TIFF "September 12, 2002" "libtiff" 26 | .SH NAME 27 | TIFFDataWidth \- Get the size of TIFF data types 28 | .SH SYNOPSIS 29 | .B "#include " 30 | .sp 31 | .BI "int TIFFDataWidth(TIFFDataType " type ")" 32 | .SH DESCRIPTION 33 | .I TIFFDataWidth 34 | returns a size of 35 | .I type 36 | in bytes. 37 | Currently following data types are supported: 38 | .br 39 | .I TIFF_BYTE 40 | .br 41 | .I TIFF_ASCII 42 | .br 43 | .I TIFF_SBYTE 44 | .br 45 | .I TIFF_UNDEFINED 46 | .br 47 | .I TIFF_SHORT 48 | .br 49 | .I TIFF_SSHORT 50 | .br 51 | .I TIFF_LONG 52 | .br 53 | .I TIFF_SLONG 54 | .br 55 | .I TIFF_FLOAT 56 | .br 57 | .I TIFF_IFD 58 | .br 59 | .I TIFF_RATIONAL 60 | .br 61 | .I TIFF_SRATIONAL 62 | .br 63 | .I TIFF_DOUBLE 64 | .br 65 | .SH "RETURN VALUES" 66 | .br 67 | .IR TIFFDataWidth 68 | returns a number of bytes occupied by the item of given type. 0 returned when 69 | uknown data type supplied. 70 | .SH "SEE ALSO" 71 | .BR libtiff (3TIFF), 72 | .PP 73 | Libtiff library home page: 74 | .BR http://www.remotesensing.org/libtiff/ 75 | -------------------------------------------------------------------------------- /man/TIFFError.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFError.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFError 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFError, TIFFSetErrorHandler \- library error handling interface 29 | .SH SYNOPSIS 30 | .B "#include " 31 | .sp 32 | .BI "void TIFFError(const char *" module ", const char *" fmt ", " ... ")" 33 | .sp 34 | .B "#include " 35 | .sp 36 | .BI "typedef void (*TIFFErrorHandler)(const char *" module ", const char *" fmt ", va_list " ap ");" 37 | .br 38 | .B "TIFFErrorHandler TIFFSetErrorHandler(TIFFErrorHandler handler);" 39 | .SH DESCRIPTION 40 | .I TIFFError 41 | invokes the library-wide error handling function to (normally) write an error 42 | message to the 43 | .BR stderr . 44 | The 45 | .I fmt 46 | parameter is a 47 | .IR printf (3S) 48 | format string, and any number arguments can be supplied. The 49 | .I module 50 | parameter, if non-zero, is printed before the message; it typically is used to 51 | identify the software module in which an error is detected. 52 | .PP 53 | Applications that desire to capture control in the event of an error should 54 | use 55 | .IR TIFFSetErrorHandler 56 | to override the default error handler. 57 | A 58 | .SM NULL 59 | (0) error handling function may be installed to suppress error messages. 60 | .SH "RETURN VALUES" 61 | .IR TIFFSetErrorHandler 62 | returns a reference to the previous error handling function. 63 | .SH "SEE ALSO" 64 | .BR TIFFWarning (3TIFF), 65 | .BR libtiff (3TIFF), 66 | .BR printf (3) 67 | .PP 68 | Libtiff library home page: 69 | .BR http://www.remotesensing.org/libtiff/ 70 | -------------------------------------------------------------------------------- /man/TIFFFlush.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFFlush.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFFlush 3TIFF "December 16, 1991" "libtiff" 27 | .SH NAME 28 | TIFFFlush, TIFFFlushData \- flush pending writes to an open 29 | .SM TIFF 30 | file 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "int TIFFFlush(TIFF *" tif ")" 35 | .br 36 | .BI "int TIFFFlushData(TIFF *" tif ")" 37 | .SH DESCRIPTION 38 | .IR TIFFFlush 39 | causes any pending writes for the specified file (including writes for the 40 | current directory) to be done. In normal operation this call is never needed \- 41 | the library automatically does any flushing required. 42 | .PP 43 | .IR TIFFFlushData 44 | flushes any pending image data for the specified file to be written out; 45 | directory-related data are not flushed. In normal operation this call is never 46 | needed \- the library automatically does any flushing required. 47 | .SH "RETURN VALUES" 48 | 0 is returned if an error is encountered, otherwise 1 is returned. 49 | .SH DIAGNOSTICS 50 | All error messages are directed to the 51 | .BR TIFFError (3TIFF) 52 | routine. 53 | .SH "SEE ALSO" 54 | .BR TIFFOpen (3TIFF), 55 | .BR TIFFWriteEncodedStrip (3TIFF), 56 | .BR TIFFWriteEncodedTile (3TIFF), 57 | .BR TIFFWriteRawStrip (3TIFF), 58 | .BR TIFFWriteRawTile (3TIFF), 59 | .BR TIFFWriteScanline (3TIFF), 60 | .BR TIFFWriteTile (3TIFF) 61 | .BR libtiff (3TIFF), 62 | .PP 63 | Libtiff library home page: 64 | .BR http://www.remotesensing.org/libtiff/ 65 | -------------------------------------------------------------------------------- /man/TIFFPrintDirectory.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFPrintDirectory.3tiff,v 1.1 2004/11/11 14:39:16 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1991-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFPrintDirectory 3TIFF "December 12, 1991" "libtiff" 27 | .SH NAME 28 | TIFFPrintDirectory \- print a description of a 29 | .SM TIFF 30 | directory 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "void TIFFPrintDirectory(TIFF *" tif ", FILE *" fd ", long " flags ")" 35 | .SH DESCRIPTION 36 | .I TIFFPrintDirectory 37 | prints a description of the current directory in the specified 38 | .SM TIFF 39 | file to the standard I/O output stream 40 | .IR fd . 41 | The 42 | .I flags 43 | parameter is used to control the 44 | .I "level of detail" 45 | of the printed information; it is a bit-or of the flags defined in 46 | .BR tiffio.h : 47 | .sp .5 48 | .nf 49 | .ta \w'#define 'u +\w'TIFFPRINT_JPEGDCTABLES 'u +\w'0x200 'u 50 | #define TIFFPRINT_NONE 0x0 /* no extra info */ 51 | #define TIFFPRINT_STRIPS 0x1 /* strips/tiles info */ 52 | #define TIFFPRINT_CURVES 0x2 /* color/gray response curves */ 53 | #define TIFFPRINT_COLORMAP 0x4 /* colormap */ 54 | #define TIFFPRINT_JPEGQTABLES 0x100 /* JPEG Q matrices */ 55 | #define TIFFPRINT_JPEGACTABLES 0x200 /* JPEG AC tables */ 56 | #define TIFFPRINT_JPEGDCTABLES 0x200 /* JPEG DC tables */ 57 | .fi 58 | .SH NOTES 59 | In C++ the 60 | .I flags 61 | parameter defaults to 0. 62 | .SH "RETURN VALUES" 63 | None. 64 | .SH DIAGNOSTICS 65 | None. 66 | .SH "SEE ALSO" 67 | .IR libtiff (3TIFF), 68 | .IR TIFFOpen (3TIFF), 69 | .IR TIFFReadDirectory (3TIFF), 70 | .IR TIFFSetDirectory (3TIFF) 71 | -------------------------------------------------------------------------------- /man/TIFFReadRawStrip.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFReadRawStrip.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFReadRawStrip 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFReadRawStrip \- return the undecoded contents of a strip of data from an 29 | open 30 | .SM TIFF 31 | file 32 | .SH SYNOPSIS 33 | .B "#include " 34 | .sp 35 | .BI "tsize_t TIFFReadRawStrip(TIFF *" tif ", tstrip_t " strip ", tdata_t " buf ", tsize_t " size ")" 36 | .SH DESCRIPTION 37 | Read the contents of the specified strip into the (user supplied) data buffer. 38 | Note that the value of 39 | .I strip 40 | is a ``raw strip number.'' That is, the caller must take into account whether 41 | or not the data is organized in separate planes (\c 42 | .IR PlanarConfiguration =2). 43 | To read a full strip of data the data buffer should typically be at least as 44 | large as the number returned by 45 | .IR TIFFStripSize . 46 | .SH "RETURN VALUES" 47 | The actual number of bytes of data that were placed in 48 | .I buf 49 | is returned; 50 | .IR TIFFReadEncodedStrip 51 | returns \-1 if an error was encountered. 52 | .SH DIAGNOSTICS 53 | All error messages are directed to the 54 | .BR TIFFError (3TIFF) 55 | routine. 56 | .SH "SEE ALSO" 57 | .BR TIFFOpen (3TIFF), 58 | .BR TIFFReadEncodedStrip (3TIFF), 59 | .BR TIFFReadScanline (3TIFF), 60 | .BR TIFFStripSize (3TIFF), 61 | .BR libtiff (3TIFF) 62 | .PP 63 | Libtiff library home page: 64 | .BR http://www.remotesensing.org/libtiff/ 65 | -------------------------------------------------------------------------------- /man/TIFFReadRawTile.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFReadRawTile.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFReadRawTile 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFReadRawTile \- return an undecoded tile of data from an open 29 | .SM TIFF 30 | file 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "tsize_t TIFFReadRawTile(TIFF *" tif ", ttile_t " tile ", tdata_t " buf ", tsize_t " size ")" 35 | .SH DESCRIPTION 36 | Read the contents of the specified tile into the (user supplied) data buffer. 37 | Note that the value of 38 | .I tile 39 | is a ``raw tile number.'' That is, the caller must take into account whether 40 | or not the data is organized in separate planes (\c 41 | .IR PlanarConfiguration =2). 42 | .I TIFFComputeTile 43 | automatically does this when converting an (x,y,z,sample) coordinate quadruple 44 | to a tile number. To read a full tile of data the data buffer should typically 45 | be at least as large as the value returned by 46 | .IR TIFFTileSize . 47 | .SH "RETURN VALUES" 48 | The actual number of bytes of data that were placed in 49 | .I buf 50 | is returned; 51 | .IR TIFFReadEncodedTile 52 | returns \-1 if an error was encountered. 53 | .SH DIAGNOSTICS 54 | All error messages are directed to the 55 | .BR TIFFError (3TIFF) 56 | routine. 57 | .SH "SEE ALSO" 58 | .BR TIFFOpen (3TIFF), 59 | .BR TIFFReadEncodedTile (3TIFF), 60 | .BR TIFFReadTile (3TIFF), 61 | .BR TIFFTileSize (3TIFF), 62 | .BR libtiff (3TIFF) 63 | .PP 64 | Libtiff library home page: 65 | .BR http://www.remotesensing.org/libtiff/ 66 | -------------------------------------------------------------------------------- /man/TIFFSetDirectory.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFSetDirectory.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFSetDirectory 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFSetDirectory, TIFFSetSubDirectory \- set the current directory for an open 29 | .SM TIFF 30 | file 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "int TIFFSetDirectory(TIFF *" tif ", tdir_t " dirnum ")" 35 | .br 36 | .BI "int TIFFSetSubDirectory(TIFF *" tif ", uint32 " diroff ")" 37 | .SH DESCRIPTION 38 | .I TIFFSetDirectory 39 | changes the current directory and reads its contents with 40 | .IR TIFFReadDirectory . 41 | The parameter 42 | .I dirnum 43 | specifies the subfile/directory as an integer number, with the first directory 44 | numbered zero. 45 | .PP 46 | .I TIFFSetSubDirectory 47 | acts like 48 | .IR TIFFSetDirectory , 49 | except the directory is specified as a file offset instead of an index; this 50 | is required for accessing subdirectories linked through a 51 | .I SubIFD 52 | tag. 53 | .SH "RETURN VALUES" 54 | On successful return 1 is returned. Otherwise, 0 is returned if 55 | .I dirnum 56 | or 57 | .I diroff 58 | specifies a non-existent directory, or if an error was encountered while 59 | reading the directory's contents. 60 | .SH DIAGNOSTICS 61 | All error messages are directed to the 62 | .IR TIFFError (3TIFF) 63 | routine. 64 | .PP 65 | .BR "%s: Error fetching directory count" . 66 | An error was encountered while reading the ``directory count'' field. 67 | .PP 68 | .BR "%s: Error fetching directory link" . 69 | An error was encountered while reading the ``link value'' that points to the 70 | next directory in a file. 71 | .SH "SEE ALSO" 72 | .IR TIFFCurrentDirectory (3TIFF), 73 | .IR TIFFOpen (3TIFF), 74 | .IR TIFFReadDirectory (3TIFF), 75 | .IR TIFFWriteDirectory (3TIFF), 76 | .IR libtiff (3TIFF) 77 | .PP 78 | Libtiff library home page: 79 | .BR http://www.remotesensing.org/libtiff/ 80 | -------------------------------------------------------------------------------- /man/TIFFWarning.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFWarning.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFWarning 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFWarning, TIFFSetWarningHandler \- library warning interface 29 | .SH SYNOPSIS 30 | .B "#include " 31 | .sp 32 | .BI "void TIFFWarning(const char *" module ", const char *" fmt ", " ... ")" 33 | .sp 34 | .B "#include " 35 | .sp 36 | .BI "typedef void (*TIFFWarningHandler)(const char *" module ", const char *" fmt ", va_list " ap ");" 37 | .sp 38 | .BI "TIFFWarningHandler TIFFSetWarningHandler(TIFFWarningHandler " handler ");" 39 | .SH DESCRIPTION 40 | .I TIFFWarning 41 | invokes the library-wide warning handler function to (normally) write a 42 | warning message to the 43 | .BR stderr . 44 | The 45 | .I fmt 46 | parameter is a 47 | .IR printf (3S) 48 | format string, and any number arguments can be supplied. The 49 | .I module 50 | parameter is interpreted as a string that, if non-zero, should be printed 51 | before the message; it typically is used to identify the software module in 52 | which a warning is detected. 53 | .PP 54 | Applications that desire to capture control in the event of a warning should 55 | use 56 | .IR TIFFSetWarningHandler 57 | to override the default warning handler. 58 | A 59 | .SM NULL 60 | (0) warning handler function may be installed to suppress error messages. 61 | .SH "RETURN VALUES" 62 | .IR TIFFSetWarningHandler 63 | returns a reference to the previous error handling function. 64 | .SH "SEE ALSO" 65 | .BR TIFFError (3TIFF), 66 | .BR libtiff (3TIFF), 67 | .BR printf (3) 68 | .PP 69 | Libtiff library home page: 70 | .BR http://www.remotesensing.org/libtiff/ 71 | -------------------------------------------------------------------------------- /man/TIFFWriteTile.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFWriteTile.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFWriteTile 3TIFF "November 29, 1999" "libtiff" 27 | .SH NAME 28 | TIFFWriteTile \- encode and write a tile of data to an open 29 | .SM TIFF 30 | file 31 | .SH SYNOPSIS 32 | .B "#include " 33 | .sp 34 | .BI "tsize_t TIFFWriteTile(TIFF *" tif ", tdata_t " buf ", uint32 " x ", uint32 " y ", uint32 " z ", tsample_t " sample ")" 35 | .SH DESCRIPTION 36 | Write the data for the tile 37 | .I containing 38 | the specified coordinates. The data in 39 | .I buf 40 | are is (potentially) compressed, and written to the indicated file, normally 41 | being appended to the end of the file. The buffer must be contain an entire 42 | tile of data. Applications should call the routine 43 | .IR TIFFTileSize 44 | to find out the size (in bytes) of a tile buffer. The 45 | .I x 46 | and 47 | .I y 48 | parameters are always used by 49 | .IR TIFFWriteTile . 50 | The 51 | .I z 52 | parameter is used if the image is deeper than 1 slice (\c 53 | .IR ImageDepth >1). 54 | The 55 | .I sample 56 | parameter is used only if data are organized in separate planes (\c 57 | .IR PlanarConfiguration =2). 58 | .SH "RETURN VALUES" 59 | .IR TIFFWriteTile 60 | returns \-1 if it detects an error; otherwise the number of bytes in the tile 61 | is returned. 62 | .SH DIAGNOSTICS 63 | All error messages are directed to the 64 | .BR TIFFError (3TIFF) 65 | routine. 66 | .SH "SEE ALSO" 67 | .BR TIFFCheckTile (3TIFF), 68 | .BR TIFFComputeTile (3TIFF), 69 | .BR TIFFOpen (3TIFF), 70 | .BR TIFFReadTile (3TIFF), 71 | .BR TIFFWriteScanline (3TIFF), 72 | .BR TIFFWriteEncodedTile (3TIFF), 73 | .BR TIFFWriteRawTile (3TIFF), 74 | .BR libtiff (3TIFF) 75 | .PP 76 | Libtiff library home page: 77 | .BR http://www.remotesensing.org/libtiff/ 78 | -------------------------------------------------------------------------------- /man/TIFFsize.3tiff: -------------------------------------------------------------------------------- 1 | .\" $Id: TIFFsize.3tiff,v 1.2 2005/11/02 11:07:18 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFSIZE 3TIFF "October 15, 1995" "libtiff" 27 | .SH NAME 28 | TIFFScanlineSize, TIFFRasterScanlineSize, 29 | \- return the size of various items associated with an open 30 | .SM TIFF 31 | file 32 | .SH SYNOPSIS 33 | .B "#include " 34 | .sp 35 | .BI "tsize_t TIFFRasterScanlineSize(TIFF *" tif ")" 36 | .br 37 | .BI "tsize_t TIFFScanlineSize(TIFF *" tif ")" 38 | .SH DESCRIPTION 39 | .I TIFFScanlineSize 40 | returns the size in bytes of a row of data as it would be returned in a call 41 | to 42 | .IR TIFFReadScanline , 43 | or as it would be expected in a call to 44 | .IR TIFFWriteScanline . 45 | .PP 46 | .I TIFFRasterScanlineSize 47 | returns the size in bytes of a complete decoded and packed raster scanline. 48 | Note that this value may be different from the value returned by 49 | .I TIFFScanlineSize 50 | if data is stored as separate planes. 51 | .SH DIAGNOSTICS 52 | None. 53 | .SH "SEE ALSO" 54 | .BR TIFFOpen (3TIFF), 55 | .BR TIFFReadScanline (3TIFF), 56 | .BR libtiff (3TIFF) 57 | .PP 58 | Libtiff library home page: 59 | .BR http://www.remotesensing.org/libtiff/ 60 | -------------------------------------------------------------------------------- /man/bmp2tiff.1: -------------------------------------------------------------------------------- 1 | .\" $Id: bmp2tiff.1,v 1.6 2006/03/23 14:54:02 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 2004, Andrey Kiselev 4 | .\" 5 | .\" Permission to use, copy, modify, distribute, and sell this software and 6 | .\" its documentation for any purpose is hereby granted without fee, provided 7 | .\" that (i) the above copyright notices and this permission notice appear in 8 | .\" all copies of the software and related documentation, and (ii) the names of 9 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | .\" publicity relating to the software without the specific, prior written 11 | .\" permission of Sam Leffler and Silicon Graphics. 12 | .\" 13 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | .\" 17 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | .\" OF THIS SOFTWARE. 23 | .\" 24 | .if n .po 0 25 | .TH BMP2TIFF 1 "15 October, 2004" "libtiff" 26 | .SH NAME 27 | bmp2tiff \- create a 28 | .SM TIFF 29 | file from a Microsoft Windows Device Independent Bitmap image file 30 | .SH SYNOPSIS 31 | .B bmp2tiff 32 | [ 33 | .I options 34 | ] 35 | .I input.bmp [input2.bmp ...] 36 | .I output.tiff 37 | .SH DESCRIPTION 38 | .I bmp2tiff 39 | converts a Microsoft Windows Device Independent Bitmap image file to 40 | .SM TIFF. 41 | If several input BMP files are being specified the multipage 42 | .SM TIFF 43 | output file will be created. By default, the 44 | .SM TIFF 45 | image is created with data samples packed (\c 46 | .IR PlanarConfiguration =1), 47 | compressed with the PackBits algorithm (\c 48 | .IR Compression = 32773), 49 | and with each strip no more than 8 kilobytes. 50 | These characteristics can overridden, or explicitly specified 51 | with the options described below. 52 | .SH OPTIONS 53 | .TP 54 | .B \-c 55 | Specify a compression scheme to use when writing image data: 56 | .B "\-c none" 57 | for no compression, 58 | .B "-c packbits" 59 | for the PackBits compression algorithm (the default), 60 | .B "-c jpeg" 61 | for the baseline JPEG compression algorithm, 62 | .B "-c zip 63 | for the Deflate compression algorithm, 64 | and 65 | .B "\-c lzw" 66 | for Lempel-Ziv & Welch. 67 | .TP 68 | .B \-r 69 | Write data with a specified number of rows per strip; 70 | by default the number of rows/strip is selected so that each strip 71 | is approximately 8 kilobytes. 72 | .SH "SEE ALSO" 73 | .BR gif2tiff (1), 74 | .BR pal2rgb (1), 75 | .BR ppm2tiff (1), 76 | .BR raw2tiff (1), 77 | .BR ras2tiff (1), 78 | .BR sgi2tiff (1), 79 | .BR libtiff (3TIFF) 80 | .PP 81 | Libtiff library home page: 82 | .BR http://www.remotesensing.org/libtiff/ 83 | -------------------------------------------------------------------------------- /man/gif2tiff.1: -------------------------------------------------------------------------------- 1 | .\" $Id: gif2tiff.1,v 1.3 2005/11/02 11:07:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1991-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH GIF2TIFF 1 "November 2, 2005" "libtiff" 27 | .SH NAME 28 | gif2tiff \- create a 29 | .SM TIFF 30 | file from a GIF87 format image file 31 | .SH SYNOPSIS 32 | .B gif2tiff 33 | [ 34 | .I options 35 | ] 36 | .I input.gif 37 | .I output.tif 38 | .SH DESCRIPTION 39 | .I Gif2tiff 40 | converts a file in the GIF87 format to 41 | .SM TIFF. 42 | The 43 | .SM TIFF 44 | image is created as a palette image, with samples 45 | compressed with the Lempel-Ziv & Welch algorithm (\c 46 | .IR Compression =5). 47 | These characteristics can overridden, or explicitly specified 48 | with the options described below. 49 | .SH OPTIONS 50 | .TP 51 | .B \-c 52 | Specify a compression scheme to use when writing image data: 53 | .B "\-c none" 54 | for no compression, 55 | .B "-c packbits" 56 | for the PackBits compression algorithm, 57 | .B "-c zip" 58 | for the Deflate compression algorithm, 59 | and 60 | .B "\-c lzw" 61 | for Lempel-Ziv & Welch (the default). 62 | .TP 63 | .B \-r 64 | Write data with a specified number of rows per strip; 65 | by default the number of rows/strip is selected so that each strip 66 | is approximately 8 kilobytes. 67 | .SH NOTES 68 | The program is based on Paul Haeberli's 69 | .I fromgif 70 | program which, in turn, is based on Marcel J.E. Mol's GIF reader. 71 | .SH BUGS 72 | Should have more options to control output format. 73 | .SH "SEE ALSO" 74 | .BR pal2rgb (1), 75 | .BR tiffinfo (1), 76 | .BR tiffcp (1), 77 | .BR tiffmedian (1), 78 | .BR libtiff (3) 79 | .PP 80 | Libtiff library home page: 81 | .BR http://www.remotesensing.org/libtiff/ 82 | -------------------------------------------------------------------------------- /man/tiff2bw.1: -------------------------------------------------------------------------------- 1 | .\" $Id: tiff2bw.1,v 1.2 2005/11/02 11:07:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFF2BW 1 "November 2, 2005" "libtiff" 27 | .SH NAME 28 | tiff2bw \- convert a color 29 | .SM TIFF 30 | image to greyscale 31 | .SH SYNOPSIS 32 | .B tiff2bw 33 | [ 34 | options 35 | ] 36 | .I input.tif 37 | .I output.tif 38 | .SH DESCRIPTION 39 | .I Tiff2bw 40 | converts an 41 | .SM RGB 42 | or Palette color 43 | .SM TIFF 44 | image to a greyscale image by 45 | combining percentages of the red, green, and blue channels. 46 | By default, output samples are created by taking 47 | 28% of the red channel, 59% of the green channel, and 11% of 48 | the blue channel. 49 | To alter these percentages, the 50 | .BR \-R , 51 | .BR \-G , 52 | and 53 | .BR \-B 54 | options may be used. 55 | .SH OPTIONS 56 | .TP 57 | .B \-c 58 | Specify a compression scheme to use when writing image data: 59 | .B "\-c none" 60 | for no compression, 61 | .B "-c packbits" 62 | for the PackBits compression algorithm, 63 | .B "-c zip 64 | for the Deflate compression algorithm, 65 | .B "-c g3 66 | for the CCITT Group 3 compression algorithm, 67 | .B "-c g4 68 | for the CCITT Group 4 compression algorithm, 69 | and 70 | .B "\-c lzw" 71 | for Lempel-Ziv & Welch (the default). 72 | .TP 73 | .B \-r 74 | Write data with a specified number of rows per strip; 75 | by default the number of rows/strip is selected so that each strip 76 | is approximately 8 kilobytes. 77 | .TP 78 | .B \-R 79 | Specify the percentage of the red channel to use (default 28). 80 | .TP 81 | .B \-G 82 | Specify the percentage of the green channel to use (default 59). 83 | .TP 84 | .B \-B 85 | Specify the percentage of the blue channel to use (default 11). 86 | .SH "SEE ALSO" 87 | .BR pal2rgb (1), 88 | .BR tiffinfo (1), 89 | .BR tiffcp (1), 90 | .BR tiffmedian (1), 91 | .BR libtiff (3) 92 | .PP 93 | Libtiff library home page: 94 | .BR http://www.remotesensing.org/libtiff/ 95 | -------------------------------------------------------------------------------- /man/tiffcmp.1: -------------------------------------------------------------------------------- 1 | .\" $Id: tiffcmp.1,v 1.4 2005/11/02 11:07:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFCMP 1 "November 2, 2005" "libtiff" 27 | .SH NAME 28 | tiffcmp \- compare two 29 | .SM TIFF 30 | files 31 | .SH SYNOPSIS 32 | .B tiffcmp 33 | [ 34 | .I options 35 | ] 36 | .I "file1.tif file2.tif" 37 | .SH DESCRIPTION 38 | .I Tiffcmp 39 | compares the tags and data in two files created according 40 | to the Tagged Image File Format, Revision 6.0. 41 | The schemes used for compressing data in each file 42 | are immaterial when data are compared\-data are compared on 43 | a scanline-by-scanline basis after decompression. 44 | Most directory tags are checked; notable exceptions are: 45 | .IR GrayResponseCurve , 46 | .IR ColorResponseCurve , 47 | and 48 | .IR ColorMap 49 | tags. 50 | Data will not be compared if any of the 51 | .IR BitsPerSample , 52 | .IR SamplesPerPixel , 53 | or 54 | .I ImageWidth 55 | values are not equal. 56 | By default, 57 | .I tiffcmp 58 | will terminate if it encounters any difference. 59 | .SH OPTIONS 60 | .TP 61 | .B \-l 62 | List each byte of image data that differs between the files. 63 | .TP 64 | .B \-z number 65 | List specified number of image data bytes that differs between the files. 66 | .TP 67 | .B \-t 68 | Ignore any differences in directory tags. 69 | .SH BUGS 70 | Tags that are not recognized by the library are not 71 | compared; they may also generate spurious diagnostics. 72 | .PP 73 | The image data of tiled files is not compared, since the TIFFReadScanline() 74 | function is used. A error will be reported for tiled files. 75 | .PP 76 | The pixel and/or sample number reported in differences may be off 77 | in some exotic cases. 78 | .SH "SEE ALSO" 79 | .BR pal2rgb (1), 80 | .bR tiffinfo (1), 81 | .BR tiffcp (1), 82 | .BR tiffmedian (1), 83 | .BR libtiff (3TIFF) 84 | .PP 85 | Libtiff library home page: 86 | .BR http://www.remotesensing.org/libtiff/ 87 | -------------------------------------------------------------------------------- /man/tiffdump.1: -------------------------------------------------------------------------------- 1 | .\" $Id: tiffdump.1,v 1.4 2005/11/02 11:07:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFDUMP 1 "October 23, 2005" "libtiff" 27 | .SH NAME 28 | tiffdump \- print verbatim information about 29 | .SM TIFF 30 | files 31 | .SH SYNOPSIS 32 | .B tiffdump 33 | [ 34 | .I options 35 | ] 36 | .I "name \&..." 37 | .SH DESCRIPTION 38 | .I tiffdump 39 | displays directory information from files created according 40 | to the Tag Image File Format, Revision 6.0. 41 | The header of each 42 | .SM TIFF 43 | file (magic number, version, and first directory offset) 44 | is displayed, followed by the tag contents of each directory in the file. 45 | For each tag, the name, data type, count, and value(s) is displayed. 46 | When the symbolic name for a tag or data type is known, the symbolic 47 | name is displayed followed by it's numeric (decimal) value. 48 | Tag values are displayed enclosed in ``<>'' characters immediately 49 | preceded by the value of the count field. 50 | For example, an 51 | .I ImageWidth 52 | tag might be displayed as ``ImageWidth (256) SHORT (3) 1<800>''. 53 | .PP 54 | .I tiffdump 55 | is particularly useful for investigating the contents of 56 | .SM TIFF 57 | files that 58 | .I libtiff 59 | does not understand. 60 | .SH OPTIONS 61 | .TP 62 | .B \-h 63 | Force numeric data to be printed in hexadecimal rather than the 64 | default decimal. 65 | .TP 66 | .B \-m " items" 67 | Change the number of indirect data items that are printed. By default, this 68 | will be 24. 69 | .TP 70 | .B \-o " offset" 71 | Dump the contents of the 72 | .SM IFD 73 | at the a particular file offset. 74 | The file offset may be specified using the usual C-style syntax; 75 | i.e. a leading ``0x'' for hexadecimal and a leading ``0'' for octal. 76 | .SH "SEE ALSO" 77 | .BR tiffinfo (1), 78 | .BR libtiff (3TIFF) 79 | .PP 80 | Libtiff library home page: 81 | .BR http://www.remotesensing.org/libtiff/ 82 | -------------------------------------------------------------------------------- /man/tiffinfo.1: -------------------------------------------------------------------------------- 1 | .\" $Id: tiffinfo.1,v 1.2 2005/11/02 11:07:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFINFO 1 "November 2, 2005" "libtiff" 27 | .SH NAME 28 | tiffinfo \- print information about 29 | .SM TIFF 30 | files 31 | .SH SYNOPSIS 32 | .B tiffinfo 33 | [ 34 | .I options 35 | ] 36 | .I "input.tif \&..." 37 | .SH DESCRIPTION 38 | .I Tiffinfo 39 | displays information about files created according 40 | to the Tag Image File Format, Revision 6.0. 41 | By default, the contents of each 42 | .SM TIFF 43 | directory in each file 44 | is displayed, with the value of each tag shown symbolically 45 | (where sensible). 46 | .SH OPTIONS 47 | .TP 48 | .B \-c 49 | Display the colormap and color/gray response curves, if present. 50 | .TP 51 | .B \-D 52 | In addition to displaying the directory tags, 53 | read and decompress all the data in each image (but not display it). 54 | .TP 55 | .B \-d 56 | In addition to displaying the directory tags, 57 | print each byte of decompressed data in hexadecimal. 58 | .TP 59 | .B \-j 60 | Display any \s-2JPEG\s0-related tags that are present. 61 | .TP 62 | .B \-o 63 | Set the initial 64 | .SM TIFF 65 | directory according to the specified file offset. 66 | The file offset may be specified using the usual C-style syntax; 67 | i.e. a leading ``0x'' for hexadecimal and a leading ``0'' for octal. 68 | .TP 69 | .B \-s 70 | Display the offsets and byte counts for each data strip in a directory. 71 | .TP 72 | .B \-z 73 | Enable strip chopping when reading image data. 74 | .TP 75 | .B \-# 76 | Set the initial 77 | .SM TIFF 78 | directory to 79 | .IR # . 80 | .SH "SEE ALSO" 81 | .BR pal2rgb (1), 82 | .BR tiffcp (1), 83 | .BR tiffcmp (1), 84 | .BR tiffmedian (1), 85 | .BR libtiff (3TIFF) 86 | .PP 87 | Libtiff library home page: 88 | .BR http://www.remotesensing.org/libtiff/ 89 | -------------------------------------------------------------------------------- /man/tiffset.1: -------------------------------------------------------------------------------- 1 | .\" $Id: tiffset.1,v 1.2 2005/11/02 11:07:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1988-1997 Sam Leffler 4 | .\" Copyright (c) 1991-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFSET 1 "November 21, 2004" "libtiff" 27 | .SH NAME 28 | tiffset \- set a field in a 29 | .SM TIFF 30 | header 31 | .SH SYNOPSIS 32 | .B tiffset 33 | [ 34 | options 35 | ] 36 | .I filename.tif 37 | .SH DESCRIPTION 38 | .I Tiffset 39 | sets the value of a 40 | .SM TIFF 41 | header to a specified value. 42 | .SH OPTIONS 43 | .TP 44 | .B \-s tagnumber [count] value ... 45 | Set the value of the named tag to the value or values specified. 46 | .TP 47 | .B \-sf tagnumber filename 48 | Set the value of the tag to the contents of filename. This option is 49 | supported for ASCII tags only. 50 | .SH EXAMPLES 51 | The following example sets the image description tag (270) of a.tif to 52 | the contents of the file descrip: 53 | .RS 54 | .nf 55 | tiffset -sf 270 descrip a.tif 56 | .fi 57 | .RE 58 | .PP 59 | The following example sets the artist tag (315) of a.tif to the string 60 | "Anonymous": 61 | .RS 62 | .nf 63 | tiffset -s 305 Anonymous a.tif 64 | .fi 65 | .RE 66 | .PP 67 | This example sets the resolution of the file a.tif to 300 dpi: 68 | .RS 69 | .nf 70 | tiffset -s 296 2 a.tif 71 | tiffset -s 282 300.0 a.tif 72 | tiffset -s 283 300.0 a.tif 73 | .fi 74 | .RE 75 | .SH "SEE ALSO" 76 | .BR tiffdump (1), 77 | .BR tiffinfo (1), 78 | .BR tiffcp (1), 79 | .BR libtiff (3TIFF) 80 | .PP 81 | Libtiff library home page: 82 | .BR http://www.remotesensing.org/libtiff/ 83 | -------------------------------------------------------------------------------- /man/tiffsplit.1: -------------------------------------------------------------------------------- 1 | .\" $Id: tiffsplit.1,v 1.5 2005/11/02 11:07:19 dron Exp $ 2 | .\" 3 | .\" Copyright (c) 1992-1997 Sam Leffler 4 | .\" Copyright (c) 1992-1997 Silicon Graphics, Inc. 5 | .\" 6 | .\" Permission to use, copy, modify, distribute, and sell this software and 7 | .\" its documentation for any purpose is hereby granted without fee, provided 8 | .\" that (i) the above copyright notices and this permission notice appear in 9 | .\" all copies of the software and related documentation, and (ii) the names of 10 | .\" Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | .\" publicity relating to the software without the specific, prior written 12 | .\" permission of Sam Leffler and Silicon Graphics. 13 | .\" 14 | .\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | .\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | .\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | .\" 18 | .\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | .\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | .\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | .\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | .\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | .\" OF THIS SOFTWARE. 24 | .\" 25 | .if n .po 0 26 | .TH TIFFSPLIT 1 "September 20, 2005" "libtiff" 27 | .SH NAME 28 | tiffsplit \- split a multi-image 29 | .SM TIFF 30 | into single-image 31 | .SM TIFF 32 | files 33 | .SH SYNOPSIS 34 | .B tiffsplit 35 | .I src.tif 36 | [ 37 | .I prefix 38 | ] 39 | .SH DESCRIPTION 40 | .I tiffsplit 41 | takes a multi-directory (page) 42 | .SM TIFF 43 | file and creates one or more single-directory (page) 44 | .SM TIFF 45 | files from it. 46 | The output files are given names created by concatenating 47 | a prefix, a lexically ordered 48 | suffix in the range [\fIaaa\fP-\fIzzz\fP], the suffix 49 | .I .tif 50 | (e.g. 51 | .IR xaaa.tif , 52 | .IR xaab.tif , 53 | \... 54 | .IR xzzz.tif ). 55 | If a prefix is not specified on the command line, 56 | the default prefix of 57 | .I x 58 | is used. 59 | .SH OPTIONS 60 | None. 61 | .SH BUGS 62 | Only a select set of ``known tags'' is copied when splitting. 63 | .SH "SEE ALSO" 64 | .BR tiffcp (1), 65 | .BR tiffinfo (1), 66 | .BR libtiff (3TIFF) 67 | .PP 68 | Libtiff library home page: 69 | .BR http://www.remotesensing.org/libtiff/ 70 | -------------------------------------------------------------------------------- /port/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | EXTRA_DIST = Makefile.vc 27 | 28 | noinst_LTLIBRARIES = libport.la 29 | libport_la_SOURCES = dummy.c 30 | libport_la_LIBADD = @LTLIBOBJS@ 31 | 32 | -------------------------------------------------------------------------------- /port/Makefile.vc: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.vc,v 1.4 2006/03/23 14:54:02 dron Exp $ 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | # 24 | # Makefile for MS Visual C and Watcom C compilers. 25 | # 26 | # To build: 27 | # C:\libtiff\port> nmake /f makefile.vc 28 | 29 | !INCLUDE ..\nmake.opt 30 | 31 | OBJ = \ 32 | strcasecmp.obj \ 33 | getopt.obj 34 | 35 | all: libport.lib 36 | 37 | libport.lib: $(OBJ) 38 | $(AR) /out:libport.lib $(OBJ) 39 | 40 | clean: 41 | -del *.obj 42 | -del *.lib 43 | 44 | -------------------------------------------------------------------------------- /port/dummy.c: -------------------------------------------------------------------------------- 1 | /* $Id: dummy.c,v 1.2 2005/07/07 15:21:52 dron Exp $ */ 2 | 3 | /* 4 | * Dummy function, just to be ensure that the library always will be created. 5 | */ 6 | 7 | static void 8 | libport_dummy_function() 9 | { 10 | return; 11 | } 12 | 13 | -------------------------------------------------------------------------------- /port/lfind.c: -------------------------------------------------------------------------------- 1 | /* $Id: lfind.c,v 1.3 2005/12/27 15:08:22 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1989, 1993 5 | * The Regents of the University of California. All rights reserved. 6 | * 7 | * This code is derived from software contributed to Berkeley by 8 | * Roger L. Snyder. 9 | * 10 | * Redistribution and use in source and binary forms, with or without 11 | * modification, are permitted provided that the following conditions 12 | * are met: 13 | * 1. Redistributions of source code must retain the above copyright 14 | * notice, this list of conditions and the following disclaimer. 15 | * 2. Redistributions in binary form must reproduce the above copyright 16 | * notice, this list of conditions and the following disclaimer in the 17 | * documentation and/or other materials provided with the distribution. 18 | * 3. Neither the name of the University nor the names of its contributors 19 | * may be used to endorse or promote products derived from this software 20 | * without specific prior written permission. 21 | * 22 | * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 23 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 24 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 25 | * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 26 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 27 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 28 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32 | * SUCH DAMAGE. 33 | */ 34 | 35 | #if 0 36 | static char sccsid[] = "@(#)lsearch.c 8.1 (Berkeley) 6/4/93"; 37 | __RCSID("$NetBSD: lsearch.c,v 1.2 2005/07/06 15:47:15 drochner Exp $"); 38 | #endif 39 | 40 | #include 41 | 42 | #ifndef NULL 43 | # define NULL 0 44 | #endif 45 | 46 | void * 47 | lfind(const void *key, const void *base, size_t *nmemb, size_t size, 48 | int(*compar)(const void *, const void *)) 49 | { 50 | char *element, *end; 51 | 52 | end = (char *)base + *nmemb * size; 53 | for (element = (char *)base; element < end; element += size) 54 | if (!compar(element, key)) /* key found */ 55 | return element; 56 | 57 | return NULL; 58 | } 59 | -------------------------------------------------------------------------------- /port/strcasecmp.c: -------------------------------------------------------------------------------- 1 | /* $Id: strcasecmp.c,v 1.2 2005/07/07 16:34:06 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 1987, 1993 5 | * The Regents of the University of California. All rights reserved. 6 | * 7 | * Redistribution and use in source and binary forms, with or without 8 | * modification, are permitted provided that the following conditions 9 | * are met: 10 | * 1. Redistributions of source code must retain the above copyright 11 | * notice, this list of conditions and the following disclaimer. 12 | * 2. Redistributions in binary form must reproduce the above copyright 13 | * notice, this list of conditions and the following disclaimer in the 14 | * documentation and/or other materials provided with the distribution. 15 | * 3. Neither the name of the University nor the names of its contributors 16 | * may be used to endorse or promote products derived from this software 17 | * without specific prior written permission. 18 | * 19 | * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 20 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 21 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 23 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 24 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 25 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 26 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 27 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 28 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 29 | * SUCH DAMAGE. 30 | */ 31 | 32 | #if 0 33 | static char sccsid[] = "@(#)strcasecmp.c 8.1 (Berkeley) 6/4/93"; 34 | __RCSID("$NetBSD: strcasecmp.c,v 1.16 2003/08/07 16:43:49 agc Exp $"); 35 | #endif 36 | 37 | #include 38 | #include 39 | 40 | int 41 | strcasecmp(const char *s1, const char *s2) 42 | { 43 | const unsigned char *us1 = (const unsigned char *)s1, 44 | *us2 = (const unsigned char *)s2; 45 | 46 | while (tolower(*us1) == tolower(*us2++)) 47 | if (*us1++ == '\0') 48 | return (0); 49 | return (tolower(*us1) - tolower(*--us2)); 50 | } 51 | -------------------------------------------------------------------------------- /test/Makefile.am: -------------------------------------------------------------------------------- 1 | # Tag Image File Format (TIFF) Software 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | 24 | # Process this file with automake to produce Makefile.in. 25 | 26 | LIBTIFF = $(top_builddir)/libtiff/libtiff.la 27 | 28 | #EXTRA_DIST = Makefile.vc 29 | 30 | TESTS = $(check_PROGRAMS) 31 | 32 | check_PROGRAMS = ascii_tag long_tag short_tag strip_rw 33 | 34 | ascii_tag_SOURCES = ascii_tag.c 35 | ascii_tag_LDADD = $(LIBTIFF) 36 | long_tag_SOURCES = long_tag.c check_tag.c 37 | long_tag_LDADD = $(LIBTIFF) 38 | short_tag_SOURCES = short_tag.c check_tag.c 39 | short_tag_LDADD = $(LIBTIFF) 40 | strip_rw_SOURCES = strip_rw.c strip.c test_arrays.c test_arrays.h 41 | strip_rw_LDADD = $(LIBTIFF) 42 | 43 | INCLUDES = -I$(top_srcdir)/libtiff 44 | 45 | -------------------------------------------------------------------------------- /test/check_tag.c: -------------------------------------------------------------------------------- 1 | /* $Id: check_tag.c,v 1.2 2006/03/23 14:54:02 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 2004, Andrey Kiselev 5 | * 6 | * Permission to use, copy, modify, distribute, and sell this software and 7 | * its documentation for any purpose is hereby granted without fee, provided 8 | * that (i) the above copyright notices and this permission notice appear in 9 | * all copies of the software and related documentation, and (ii) the names of 10 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | * publicity relating to the software without the specific, prior written 12 | * permission of Sam Leffler and Silicon Graphics. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | * 18 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | * OF THIS SOFTWARE. 24 | */ 25 | 26 | /* 27 | * TIFF Library 28 | * 29 | * Module to test LONG tags read/write functions. 30 | */ 31 | 32 | #include "tiffio.h" 33 | 34 | int 35 | CheckShortField(TIFF *tif, ttag_t field, uint16 value) 36 | { 37 | uint16 tmp = 0; 38 | 39 | if (!TIFFGetField(tif, field, &tmp)) { 40 | fprintf (stderr, "Problem fetching tag %lu.\n", 41 | (unsigned long) field); 42 | return -1; 43 | } 44 | if (tmp != value) { 45 | fprintf (stderr, "Wrong SHORT value fetched for tag %lu.\n", 46 | (unsigned long) field); 47 | return -1; 48 | } 49 | 50 | return 0; 51 | } 52 | 53 | int 54 | CheckLongField(TIFF *tif, ttag_t field, uint32 value) 55 | { 56 | uint32 tmp = 0; 57 | 58 | if (!TIFFGetField(tif, field, &tmp)) { 59 | fprintf (stderr, "Problem fetching tag %lu.\n", 60 | (unsigned long) field); 61 | return -1; 62 | } 63 | if (tmp != value) { 64 | fprintf (stderr, "Wrong LONG value fetched for tag %lu.\n", 65 | (unsigned long) field); 66 | return -1; 67 | } 68 | 69 | return 0; 70 | } 71 | 72 | 73 | -------------------------------------------------------------------------------- /test/test_arrays.h: -------------------------------------------------------------------------------- 1 | /* $Id: test_arrays.h,v 1.3 2006/03/23 14:54:02 dron Exp $ */ 2 | 3 | /* 4 | * Copyright (c) 2004, Andrey Kiselev 5 | * 6 | * Permission to use, copy, modify, distribute, and sell this software and 7 | * its documentation for any purpose is hereby granted without fee, provided 8 | * that (i) the above copyright notices and this permission notice appear in 9 | * all copies of the software and related documentation, and (ii) the names of 10 | * Sam Leffler and Silicon Graphics may not be used in any advertising or 11 | * publicity relating to the software without the specific, prior written 12 | * permission of Sam Leffler and Silicon Graphics. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 15 | * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 16 | * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 17 | * 18 | * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 19 | * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 20 | * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 | * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 22 | * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 23 | * OF THIS SOFTWARE. 24 | */ 25 | 26 | /* 27 | * TIFF Library 28 | * 29 | * Few declarations for the test numerical arrays. 30 | */ 31 | 32 | #ifndef _TEST_ARRAYS_ 33 | #define _TEST_ARRAYS_ 34 | 35 | #include 36 | 37 | #define XSIZE 37 38 | #define YSIZE 23 39 | 40 | extern const unsigned char byte_array1[]; 41 | extern const size_t byte_array1_size; 42 | 43 | extern const unsigned char byte_array2[]; 44 | extern const size_t byte_array2_size; 45 | 46 | extern const unsigned char byte_array3[]; 47 | extern const size_t byte_array3_size; 48 | 49 | extern const float array_float1[]; 50 | extern const size_t array_float1_size; 51 | 52 | extern const float array_float2[]; 53 | extern const size_t array_float2_size; 54 | 55 | extern const double array_double1[]; 56 | extern const size_t array_double1_size; 57 | 58 | extern const double array_double2[]; 59 | extern const size_t array_double2_size; 60 | 61 | #endif /* _TEST_ARRAYS_ */ 62 | 63 | /* vim: set ts=8 sts=8 sw=8 noet: */ 64 | -------------------------------------------------------------------------------- /tools/Makefile.vc: -------------------------------------------------------------------------------- 1 | # $Id: Makefile.vc,v 1.11 2006/03/23 14:54:02 dron Exp $ 2 | # 3 | # Copyright (C) 2004, Andrey Kiselev 4 | # 5 | # Permission to use, copy, modify, distribute, and sell this software and 6 | # its documentation for any purpose is hereby granted without fee, provided 7 | # that (i) the above copyright notices and this permission notice appear in 8 | # all copies of the software and related documentation, and (ii) the names of 9 | # Sam Leffler and Silicon Graphics may not be used in any advertising or 10 | # publicity relating to the software without the specific, prior written 11 | # permission of Sam Leffler and Silicon Graphics. 12 | # 13 | # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 14 | # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 15 | # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 16 | # 17 | # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR 18 | # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, 19 | # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 20 | # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 21 | # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 22 | # OF THIS SOFTWARE. 23 | # 24 | # Makefile for MS Visual C and Watcom C compilers. 25 | # 26 | # To build: 27 | # C:\libtiff\tools> nmake /f makefile.vc 28 | 29 | !INCLUDE ..\nmake.opt 30 | 31 | TARGETS = bmp2tiff.exe tiffcp.exe tiffinfo.exe tiffdump.exe \ 32 | fax2tiff.exe fax2ps.exe gif2tiff.exe pal2rgb.exe ppm2tiff.exe \ 33 | rgb2ycbcr.exe thumbnail.exe ras2tiff.exe raw2tiff.exe \ 34 | tiff2bw.exe tiff2rgba.exe tiff2pdf.exe tiff2ps.exe \ 35 | tiffcmp.exe tiffdither.exe tiffmedian.exe tiffsplit.exe 36 | 37 | INCL = -I..\libtiff 38 | LIBS = $(LIBS) ..\port\libport.lib ..\libtiff\libtiff.lib 39 | 40 | default: $(TARGETS) 41 | 42 | .c.exe: 43 | $(CC) $(CFLAGS) $*.c $(EXTRA_OBJ) $(LIBS) 44 | 45 | tiffgt.exe: 46 | $(CC) $(CFLAGS) tiffgt.c $(EXTRA_OBJ) $(LIBS) 47 | 48 | clean: 49 | -del *.exe 50 | -del *.obj 51 | -------------------------------------------------------------------------------- /tools/rasterfile.h: -------------------------------------------------------------------------------- 1 | /* $Header: /cvs/maptools/cvsroot/libtiff/tools/rasterfile.h,v 1.3 2003/11/12 19:14:33 dron Exp $ */ 2 | 3 | /* 4 | * Description of header for files containing raster images 5 | */ 6 | struct rasterfile { 7 | char ras_magic[4]; /* magic number */ 8 | long ras_width; /* width (pixels) of image */ 9 | long ras_height; /* height (pixels) of image */ 10 | long ras_depth; /* depth (1, 8, or 24 bits) of pixel */ 11 | long ras_length; /* length (bytes) of image */ 12 | long ras_type; /* type of file; see RT_* below */ 13 | long ras_maptype; /* type of colormap; see RMT_* below */ 14 | long ras_maplength; /* length (bytes) of following map */ 15 | /* color map follows for ras_maplength bytes, followed by image */ 16 | }; 17 | #define RAS_MAGIC "\x59\xa6\x6a\x95" 18 | #define RAS_MAGIC_INV "\x95\x6a\xa6\x59" 19 | 20 | /* Sun supported ras_type's */ 21 | #define RT_OLD 0 /* Raw pixrect image in 68000 byte order */ 22 | #define RT_STANDARD 1 /* Raw pixrect image in 68000 byte order */ 23 | #define RT_BYTE_ENCODED 2 /* Run-length compression of bytes */ 24 | #define RT_EXPERIMENTAL 0xffff /* Reserved for testing */ 25 | 26 | /* Sun registered ras_maptype's */ 27 | #define RMT_RAW 2 28 | /* Sun supported ras_maptype's */ 29 | #define RMT_NONE 0 /* ras_maplength is expected to be 0 */ 30 | #define RMT_EQUAL_RGB 1 /* red[ras_maplength/3],green[],blue[] */ 31 | 32 | /* 33 | * NOTES: 34 | * Each line of the image is rounded out to a multiple of 16 bits. 35 | * This corresponds to the rounding convention used by the memory pixrect 36 | * package (/usr/include/pixrect/memvar.h) of the SunWindows system. 37 | * The ras_encoding field (always set to 0 by Sun's supported software) 38 | * was renamed to ras_length in release 2.0. As a result, rasterfiles 39 | * of type 0 generated by the old software claim to have 0 length; for 40 | * compatibility, code reading rasterfiles must be prepared to compute the 41 | * true length from the width, height, and depth fields. 42 | */ 43 | --------------------------------------------------------------------------------