commit f81ae811ca2e1820f29ac632f1b53ceafacf3eec
Author: Jens Ahrensfeld
+ Time of Conversion:
+
+
+
+
+
+
+
+
+ Filename
+ Status
+ Errors
+ Warnings
+
+
+
+
+
+ ![]()
+
+
+
+
+
+
+
+
+
+
+
+
+ Conversion Issues -
+
+
+
+
+
+
+
+
+
+ Converted:
+
+ Not converted:
+
+
+ Conversion Report -
+
+
+
+
+
+
+ Conversion Settings
+
+
+Bugs and the TIFF Mailing List
++This software is free. Please let us know when you find a problem or +fix a bug. + +
+A mailing list for users of this software is located at olympiakos.com +If you want to join this mailing list or have a list-related request +such as getting your name removed from it, send a request to +
+subscribe ++in the body of your message. The line help will return a list of +the commands understood by the mailing list management software. + +
+Submissions (including bug reports) should be directed to: +
+ +
+Building the Software Distribution
++hyla% cd tiff-v3.4beta099 +hyla% ./configure + ...lots of messages... +hyla% make + ...lots of messages... +hyla# make install ++ +In general, the software is designed such that the following should +be ``make-able'' in each directory: + +
+make [all] build stuff +make install build&install stuff +make clean remove .o files and cruft, but not executables +make clobber remove everything that can be recreated +make distclean remove absolutely everything that can be recreated ++ +Note that after running "make clobber" or +"make distclean" the configure script must +be run again to create the Makefiles and other make-related files. + +
+hyla% cd tiff-v3.4beta099 +hyla% ls +COPYRIGHT VERSION config.sub dist man +Makefile.in config.guess configure html port +README config.site contrib libtiff tools +hyla% ./configure ++ +
+Otherwise, you can configure a build tree that +is parallel to the source tree hierarchy but which contains only +configured files and files created during the build procedure. + +
+hyla% cd tiff-v3.4beta099 +hyla% mkdir obj obj/mycpu +hyla% cd obj/mycpu +hyla% ../../configure ++ +This second scheme is useful for: + +
+A second function of the configure script is to set the default +configuration parameters for the software. +Of particular note are the directories where the software is to be +installed. +By default the software is installed in the /usr/local hierarchy. +To change this behaviour the appropriate parameters can be +specified either: +
+Site-wide configuration files are named +config.site and are automatically searched for first +in any directory specified on the command line to configure +(using the -site option), or if that fails, in +the directory in in which the configure script is located. + +
+Target-specific configuration files are named config.local +and are looked for first in the top-level configuration directory, +or, if that fails, in the directory in which the configure script +is located. + +
+Configuration files are just shell scripts that define +shell variables that control the configuration process. +For example, the following file might be used on a BSDI system to +configure the software for installation in the /usr/contrib area. + +
+# +# Parameters suitable for BSDI 1.1 +# +DIR_BIN="/usr/contrib/bin" # directory for client apps +DIR_LIB="/usr/contrib/lib" # directory for libraries +DIR_MAN="/usr/contrib/man" # directory for manual pages ++ +
+For a complete list of the possible configuration parameters look
+at the sample config.site file provided in the distribution; the
+section below describes some of the more important parameters.
+
+Configuring Optional Packages/Support
+
+The TIFF software comes with several packages that are installed only
+as needed, or only if specifically configured at the time
+the configure script is run. Packages can be configured in a
+config.site or config.local file, or by using a
+-with-<PACKAGE> option when invoking configure;
+e.g. configure -with-AFM.
+
+
+
+
+wullbrandt% mkdir tiff +wullbrandt% cd tiff +wullbrandt% ln -s /hosts/oxford/usr/people/sam/tiff src ++ +A build tree separate from the source tree is used here. +In fact, in this case the distribution is accessed from +a read-only NFS-mounted filesystem. + +
+wullbrandt% src/configure +Configuring TIFF Software v3.4beta015. + +Reading site-wide parameters from ../tiff-v3.4beta015/config.site. +Reading local parameters from config.local. +Gosh, aren't you lucky to have a i386-unknown-bsdi1.1 system! ++ +Note that configure announces the distribution version and the +deduced target configuration (i386-unknown-bsdi1.1 here). + +
+Using /usr/local/bin/gcc for a C compiler (set CC to override). +Looks like /usr/local/bin/gcc supports the -g option. +Using " -g" for C compiler options. ++ +configure checked the normal shell search path for potential +ANSI C compilers. The compiler is selected according to it properly +compiling a small ANSI C test program. A specific compiler may be requested +by setting the CC environment variable to the appropriate +pathname, by supplying the parameter on the command line, e.g. +-with-CC=gcc, or by setting CC in a configuration +file. + +
+
+Note that an ANSI C compiler is required to build the software.
+If a C compiler requires options to enable ANSI C compilation, they
+can be specified with the ENVOPTS parameter.
+
+
+Once a compiler is selected configure checks to see +if the compiler accepts a -g option to enable the generation + of debugging symbols, and +if the compiler includes an ANSI C preprocessor. + +
+Using /usr/ucb/make to configure the software. ++ +Next various system-specific libraries that may or may not be needed +are checked for (none are needed in this case). +If your system requires a library that is not +automatically included it can be specified by setting the +MACHDEPLIBS parameter. + +
Creating port.h. +The port.h file is included by all the C code +in the library (but not the tools). +It includes definitions for functions and type +definitions that are missing from system include files, #defines +to enable or disable system-specific functionality, and other +odds and ends. + +
+Creating libtiff/port.h with necessary definitions. +... using LSB2MSB bit order for your i386 cpu +... using big-endian byte order for your i386 cpu +... configure use of mmap for memory-mapped files +... O_RDONLY is in <fcntl.h> +... using double for promoted floating point parameters +... enabling use of inline functions +Done creating libtiff/port.h. ++ +This file can take a long time to create so configure +generates the file only when it is needed, either because the +file does not exist or because a different target or compiler +is to be used. +Note that running "make distclean" in the top-level directory +of the build tree will remove the port.h file (along +with all the other files generated by configure). + +
Selecting emulated library functions. +Certain library functions used by the tools are not present on all systems +and can be emulated using other system functionality. +configure checks for the presence of such functions and if they are +missing, will configure emulation code from the port directory +to use instead. Building the TIFF +software on unsupported systems may require +adding to the code to the port directory. + +
+Checking system libraries for functionality to emulate. +Done checking system libraries. ++ +If a routine must be emulated and configure does not automatically +check for it, the routine name can be specified using the PORTFUNCS +parameter. To add emulation support for a new function foo, +create a file port/foo.c that contains the emulation code +and then set PORTFUNCS=foo in a configuration file or modify +the configure script to automatically check for the missing function. + +
+Checking for Dynamic Shared Object (DSO) support. +Done checking for DSO support. ++ +If the DSO package is enabled (DSO=auto or +DSO=yes), then +configure will verify the system and compiler are capable of +constructing SVR4-style DSO's in the expected way. Note that +while a system may support DSO's the compiler may not be +capable of generating the required position-independent +code and/or the compiler may not pass the needed options +through to the loader. + +
Selecting utility programs. +configure locates various system utility programs that are +used during installation of the software. + +
+Selecting programs used during installation. +Looks like mv supports the -f option to force a move. +Looks like /bin/ln supports the -s option to create a symbolic link. +Done selecting programs. ++ +
Selecting default configuration parameters. +The remainder of the work done by configure involves setting up +configuration parameters that control the placement and +setup of files during the installation procedure. + +
+Selecting default TIFF configuration parameters. + +Looks like manual pages go in /usr/contrib/man. +Looks like manual pages should be installed with bsd-nroff-gzip-0.gz. + +TIFF configuration parameters are: + +[ 1] Directory for tools: /usr/contrib/bin +[ 2] Directory for libraries: /usr/contrib/lib +[ 3] Directory for include files: /usr/contrib/include +[ 4] Directory for manual pages: /usr/contrib/man +[ 5] Manual page installation scheme: bsd-nroff-gzip-0.gz + +Are these ok [yes]? ++ + + +At this point you can interactively modify any of the +displayed parameters. Hitting a carriage return or typing +yes will accept the current parameters. Typing one +of the number displayed along the left hand side causes +configure to prompt for a new value of the specified parameter. +Typing anything else causes configure to prompt for a new +value for each parameter. +In general hitting carriage return will accept the current +value and typing anything that is unacceptable will cause a +help message to be displayed. +A description of each of the configuration parameters is given below. + +
+Once acceptable parameters are setup configure will generate +all the files that depend on these parameters. Note that certain +files may or may not be created based on the configuration of +optional packages and/or the functions supported by target system. + +
+Creating Makefile from ../tiff-v3.4beta015/Makefile.in +Creating libtiff/Makefile from ../tiff-v3.4beta015/libtiff/Makefile.in +Creating man/Makefile from ../tiff-v3.4beta015/man/Makefile.in +Creating tools/Makefile from ../tiff-v3.4beta015/tools/Makefile.in +Creating port/install.sh from ../tiff-v3.4beta015/port/install.sh.in +Done. ++ +
+To add new support for building a shared library both these files
+must be updated.
+In the configure script search for the section where the autoconfiguration
+setting of the DSO parameter is handled and
+add a new case for the target system that sets the
+DSOSUF,
+DSOLD,
+DSOOPTS,
+and
+LIBCOPTS
+options as appropriate for the system.
+DSOSUF specifies the filename suffix used for the shared
+library (e.g. ``.so'' for Dynamic Shared Objects on most SVR4-based
+systems).
+DSOLD specifies the program to use to build the shared library
+from a compiled object file; typically ``${LD}'' though on some systems
+it is better to use the C compiler directly so system-dependent options and
+libraries are automatically supplied.
+DSOOPTS are options that must be specified to DSOLD
+when building the shared library.
+LIBCOPTS are options to pass to the C compiler when constructing
+a relocatable object file to include in a shared library; e.g. ``-K PIC''
+on a Sun system.
+The DSO parameter must also be set to a unique label that identifies
+the target system and compilation tools.
+This label is used to select
+a target in libtiff/Makefile.in to do the actual work in building
+the shared library.
+Finally, to complete support for the shared library added the appropriate
+rules to libtiff/Makefile.in under the target specified in the
+configure script.
+
+
+
+
+Configuration Parameters
+
+This section gives a brief description of the less obvious
+configuration parameters. Consult the distributed config.site
+for a complete list of parameters.
+The list here is sorted alphabetically.
+
+
+
| AROPTS | +The options passed to ar when creating an archive. +Note that configure will automatically check to see if ar +supports an s to create a symbol table instead of +using ranlib. | +
| DIR_BIN | +The directory where client applications should be installed; by +default this is /usr/local/bin. | +
| DIR_GZLIB | +The pathname of the directory containing the zlib library +(when ZIP or PixarLog compression support is enabled); +e.g. ``../src/zlib''. | +
| DIR_JPEGLIB | +The pathname of the directory containing the JPEG library +(when JPEG support is enabled); e.g. ``/usr/local/lib''. | +
| DIR_LIB | +The directory to install libraries and DSO's; by default +this is /usr/local/lib. | +
| DIR_MAN | +The top-most directory of the manual area where manual +pages should be installed. | +
| DIRS_LIBINC | +A space-separated list of directories in which to search for +include files when building the library and tools. +If JPEG or ZIP support is configured this parameter should include +the directories where the associated include files are located. | +
| DIST_ALPHA | +The alpha version number for the distribution; e.g. if this +is version 3.4beta031 then the the major number is 31. | +
| DIST_MAJOR | +The major version number for the distribution; e.g. if this +is version 3.4beta031 then the the major number is 3. | +
| DIST_MINOR | +The minor version number for the distribution; e.g. if this +is version 3.4beta031 then the the major number is 4. | +
| DSOSUF | +When DSO's are built, the filename suffix for a DSO. +If this is set to "a" then statically linked archives are used. | +
| DSOSUF_VERSION | +When DSO's are built, a version-specific filename suffix for a DSO. +If this is set to something other than the value of DSO then +the file libtiff.DSOSUF_VERSION will be installed and +a link to it named libtiff.DSOSUF will automatically +be created. (Note that this means that rule for building the target +DSO must generate a file named libtiff.DSOSUF_VERSION.) | +
| ENVOPTS | +Options to pass to CC to force ANSI C compilation. | +
| FILLORDER | +The order of bits in a byte on the server machine; +either LSB2MSB or MSB2LSB. +This is normally selected according to the target system. | +
| GCOPTS | +Special options to pass the C compiler. If this parameter +is set, then configure may append other options to this list. | +
| INSTALL | +The pathname of the install program to use. Note that this program +must emulate the command line interface used by the IRIX install program. | +
| LIBPORT | +The pathname of the library that holds code to emulate missing +system functionality. +Normally this parameter is set by configure based on whether or +not emulation code is required for the target. + |
| LLDOPTS + | Extra command line options passed to CC +when linking an executable. +This option is usually set only when DSO support is enabled +(to force the executable to search for the TIFF DSO +in non-standard locations in the filesystem.) | +
| MACHDEPLIBS | +Target-dependent libraries that should be used when linking +tools. +Note that if this parameter is specified configure will append to +the list of libraries. | +
| MANSCHEME | +The scheme to use when preparing and installing manual pages.
+Schemes are constructed according to:
+
|
+
| PORTFUNCS | +A list of non-standard functions that should be emulated. +Normally this list is constructed by configure based on checks it does. +If this parameter is set, configure will append to the specified list. | +
| SETMAKE | +If make does not automatically set $MAKE to +the name of the make program to invoke for subdirectories, then +configure will create an explicit definition. +If this parameter is set, then it will be used instead. +by default bin is used. | +
+ +
+C:\LIBTIFF\LIBTIFF> nmake /f makefile.vc +C:\LIBTIFF\LIBTIFF> cd ..\tools +C:\LIBTIFF\TOOLS> nmake /f makefile.vc ++ +This will build the library file LIBTIFF\LIBTIFF\LIBTIFF.LIB. This +can be used in Win32 programs. If used in a project using the /MD compiler +switch (using the runtime C library), it may be necessary to modify the +CFLAGS macro in makefile.vc to correspond.
+ +The makefile also builds a DLL (libtiff.dll) with an associated import +library (libtiff_i.lib). Any builds using libtiff will need to include +the LIBTIFF\LIBTIFF directory in the include path.
+ +The libtiff\tools\makefile.vc should build .exe's for all the +standard TIFF tool programs.
+ +NOTE: The contents of the contrib/win32 directory should no longer be +needed, and are kept in the distribution temporarily.
+
+Building the Software under MS/DOS with the DJGPP v2 compiler
+
+[From the file contrib/dosdjgpp/README.]
+
+
+The directory contrib/dosdjgpp +contains the files necessary to build the library and tools +with the DJGPP v2 compiler under MSDOS. + +
+All you have to do is copy the files in the directory +into the respective directories and run +make. If you want, you can use the conf.bat script +to do that for you, make sure that +the file is stored with MSDOS text EOL-convention (CR/LF), otherwise the +command.com will not do anything. + +
+Note that you probably will not be able to build the library with the v1.x
+versions of djgpp, due to two problems. First, the top makefile calls a
+sub-make for each directory and you are likely to run out of memory, since
+each recursive invocation of a djgpp v1.x program requires about 130k, to
+avoid that, you can enter the directories manually and call make (well, there
+are only two dirs). The 2nd problem is that djgpp 1.x doesn't call the
+coff2exe (stubify) program when creating an executable. This means that all
+programs compiled are not converted to exe and consequently are not available
+for calling directly. For the tools directory, you can just call coff2exe for
+each program after make finishes, but in the libtiff directory, a few programs
+are created during the make process that have to be called for make to
+continue (e.g. mkg3states). Make will probably report an error at each
+such stage. To fix that, either add a coff2exe call before each program is
+called or call coff2exe manually and rerun make (there 2-3 such programs).
+
+
+Building the Software on a Macintosh with MPW
+
+The directory contrib/mac-mpw contains support for
+compiling the library and tools under the MPW Shell on a
+Macintosh system.
+This support was contributed by Niles Ritter
+(ndr@tazboy.jpl.nasa.gov).
+
+
+[From the file contrib/mac-mpw/README.] + +
+This directory contains all of the utilities and makefile source +to build the LIBTIFF library and tools from the MPW Shell. The +file BUILD.mpw in this directory is an executable script +which uses all of these files to create the MPW makefiles and +run them. + +
+The
+This translation trick is necessary to protect the files when
+they are put into unix tarfiles, which tend to mangle the
+special characters.
+
+
+
+
+[From the file contrib/mac-cw/README.]
+
+In this directory you will find a Makefile.script Applescript
+file, which should be run in order to build the libtiff code
+using MetroWerks CodeWarrior.
+
+Refer to the "metrowerks.note" instructions on building the
+library for 68k and PowerPC native code, as well as building
+some of the libtiff tools, which are rather unix-like, but
+at least give an example of how to link everything together.
+
+
+
+
+This release has been tested on OpenVMS/VAX 5.5-2, using VAX C 3.2.
+A previous release was tested under OpenVMS/AXP ?.? using DEC C ?.?, it is
+believed that this release as well works on AXP.
+The code contains some GNU C specific things. This does *not* imply,
+however, that the VAX/GCC configuration has been tested, *it has not*.
+
+
+The command procedures (MAKEVMS.COM) for building the
+library and tools,
+is believed to choose the correct options for the VAX and AXP cases
+automatically.
+
+
+On the AXP, IEEE floating point is used by default. If you want VAX
+floating point, remove the /FLOAT=IEEE_FLOAT qualifier, and change
+HAVE_IEEEFP=1 to HAVE_IEEEFP=0 in the MAKEVMS.COM
+files in both the libtiff and tools directories.
+
+
+
+Method 2 gives somewhat longer link time and larger .EXE
+files, but does
+not require TIFFSHR to be defined. This method is recommended if you
+want to run your program on another machine, and for some reason don't
+want to have the library on that machine. If you plan to have more than
+one program (including the tools) on the machine, it is recommended that
+you copy the library to the other machine and use method 1.
+
+
+
+
+This support was contributed by Peter Greenham. (peter@enlarion.demon.co.uk).
+
+
+
+LIBTIFF uses several files which have names longer than the normal RISC OS
+maximum of ten characters. This complicates matters. Maybe one day Acorn will
+address the problem and implement long filenames properly. Until then this
+gets messy, especially as I'm trying to do this with obeyfiles and not have
+to include binaries in this distribution.
+
+
+First of all, ensure you have Truncate configured on (type *Configure
+Truncate On)
+
+
+Although it is, of course, preferable to have long filenames, LIBTIFF can be
+installed with short filenames, and it will compile and link without
+problems. However, getting it there is more problematic.
+contrib.acorn.install is an installation obeyfile which will create a normal
+Acorn-style library from the source (ie: with c, h and o folders etc.), but
+needs the distribution library to have been unpacked into a location which is
+capable of supporting long filenames, even if only temporarily.
+
+
+My recommendation, until Acorn address this problem properly, is to use Jason
+Tribbeck's LongFilenames, or any other
+working system that gives you long filenames, like a nearby NFS server for
+instance.
+
+
+If you are using Longfilenames, even if only temporarily to install LIBTIFF,
+unpack the TAR into a RAMDisc which has been longfilenamed (ie: *addlongfs
+ram) and then install from there to the hard disk. Unfortunately
+Longfilenames seems a bit unhappy about copying a bunch of long-named files
+across the same filing system, but is happy going between systems. You'll
+need to create a ramdisk of about 2Mb.
+
+
+Now you can run the installation script I've supplied (in contrib.acorn),
+which will automate the process of installing LIBTIFF as an Acorn-style
+library. The syntax is as follows:
+
+
+install <source_dir> <dest_dir>
+
+
+Install will then create <dest_dir> and put the library in there. For
+example, having used LongFilenames on the RAMDisk and unpacked the library
+into there, you can then type:
+
+
+Obey RAM::RamDisc0.$.contrib.acorn.install RAM::RamDisc0.$ ADFS::4.$.LIBTIFF
+
+
+It doesn't matter if the destination location can cope with long filenames or
+not. The filenames will be truncated if necessary (*Configure Truncate On if
+you get errors) and all will be well.
+
+
+
+Once the LibTIFF folder has been created and the files put inside, making the
+library should be just a matter of running 'SetVars' to set the
+appropriate system variables, then running 'Makefile'.
+
+
+OSLib
+
+
+OSLib
+is a comprehensive API for RISC OS machines, written by Jonathan Coxhead of
+Acorn Computers (although OSLib is not an official Acorn product). Using the
+OSLib SWI veneers produces code which is more compact and more efficient than
+code written using _kernel_swi or _swi. The Acorn port of LibTIFF can take
+advantage of this if present. Edit the Makefile and go to the Static
+dependencies section. The first entry is:
+
+
+Change the cc line to:
+
+Remember, however, that OSLib is only recommended for efficiency's
+sake. It is not required.
+
+
+
+
+The library requires two files that are generated on-the-fly.
+The file tif_fax3sm.c has the state tables for the
+Group 3 and Group 4 decoders.
+This file is generated by the mkg3states program
+on a UNIX system; for example,
+
+
+The second file required to build the library, version.h,
+contains the version
+information returned by the TIFFGetVersion routine.
+This file is built on most systems using the
+mkversion program and the contents of the
+VERSION and tiff.alpha files; for example,
+
+
+Otherwise, when building the library on a non-UNIX system be sure to
+consult the files tiffcomp.h and tiffconf.h.
+The former contains system compatibility definitions while the latter
+is provided so that the software configuration can be controlled
+on systems that do not support the make facility for building
+the software.
+
+
+Systems without a 32-bit compiler may not be able to handle some
+of the codecs in the library; especially the Group 3 and 4 decoder.
+If you encounter problems try disabling support for a particular
+codec; consult the documentation.
+
+
+Programs in the tools directory are written to assume an ANSI C
+compilation environment.
+There may be a few POSIX'isms as well.
+The code in the port directory is provided to emulate routines
+that may be missing on some systems.
+On UNIX systems the configure script automatically figures
+out which routines are not present on a system and enables the use
+of the equivalent emulation routines from the port directory.
+It may be necessary to manually do this work on a non-UNIX system.
+
+
+
+Assuming you have working versions of tiffgt and tiffsv,
+you can just
+use them to view any of the sample images available for testing
+(see the section on obtaining the test images).
+Otherwise, you can do a cursory check of the library with
+the tiffcp and tiffcmp programs. For example,
+
+
+(tiffcmp should be silent if the files compare correctly).
+
+
+
+
+
+The contrib directory has contributed software that
+uses the TIFF library or which is associated with the library
+(typically glue and guidance for ports to non-UNIX platforms, or tools that
+aren't directly TIFF related).
+
+
+
+Questions regarding these packages are usually best directed toward
+their authors.
+
+
+
+A copy of the 6.0 specification is available by public ftp at
+
+
+Adobe provides the 6.0 spec online in
+Acrobat format (PDF); this can be found at
+
+
+
+Test images are available for most formats supported by the library.
+Most of the images included in the test kit are also part of this
+documentation (albeit in TIFF rather than GIF or JFIF).
+The images are kept in a separate archive that should be located in
+the same directory as this software.
+
+
+The latest archive of test images is located at
+ftp://ftp.onshore.com/pub/libtiff/v3.4pics.tar.Z
+
+
+There are two other good sources for TIFF test images:
+the contributed software contrib/dbs includes several
+programs that generate test images suitable for debugging, and
+the tiffcp program can be used to generate a variety
+of images with different storage characteristics.
+
+
+
+This software provides support for the Tag Image File Format (TIFF),
+a widely used format for storing image data. The latest version of
+the TIFF specification is available on-line
+in several different formats,
+as are a number of Technical Notes (TTN's).
+
+
+Included in this software distribution is a library, libtiff, for
+reading and writing TIFF, a small collection of tools for doing simple
+manipulations of TIFF images on UNIX systems,
+and documentation on the library and
+tools. A small assortment of TIFF-related software for UNIX
+that has been contributed by others is also included.
+
+
+The library, along with associated tool programs, should handle most of
+your needs for reading and writing TIFF images on 32- and 64-bit
+machines. This software can also be used on older 16-bit systems
+though it may require some effort and you may need to leave out some of
+the compression support.
+
+ The software was orginally authored and maintained by Sam Leffler.
+While he keeps a fatherly eye on the mailing list, he is no longer
+responsible for day to day maintenance.
+
+ Questions should be sent to
+the TIFF mailing list: tiff@olympiakos.com.
+
+ The persons responsible for putting up this site and putting together versions >= 3.5.1 are
+Frank Warmerdam and Mike Welles.
+
+
+
+The following sections are included in this documentation:
+
+
+
+This chapter provides information about the internal structure of
+the library, how to control the configuration when building it, and
+how to add new support to the library.
+The following sections are found in this chapter:
+
+
+Configuration defines are split into three areas:
+
+If the define COMPRESSION_SUPPORT is not defined
+then a default set of compression schemes is automatically
+configured:
+
+Support for JPEG compression is controlled by JPEG_SUPPORT.
+The JPEG codec that comes with libtiff is designed for
+use with release 5 or later of the Independent JPEG Group's freely
+available software distribution.
+This software can be retrieved from the directory
+ftp.uu.net:/graphics/jpeg/.
+
+
+
+
+Experimental support for the deflate algorithm is controlled by
+DEFLATE_SUPPORT.
+The deflate codec that comes with libtiff is designed
+for use with version 0.99 or later of the freely available
+libz library written by Jean-loup Gailly and Mark Adler.
+The data format used by this library is described
+in the files
+zlib-3.1.doc,
+and
+deflate-1.1.doc,
+available in the directory
+ftp.uu.net:/pub/archiving/zip/doc.
+The library can be retried from the directory
+ftp.uu.net:/pub/archiving/zip/zlib/
+(or try quest.jpl.nasa.gov:/beta/zlib/).
+
+
+
+By default tiffconf.h defines
+COLORIMETRY_SUPPORT,
+YCBCR_SUPPORT,
+and
+CMYK_SUPPORT.
+
+
+
+In general, the code is guaranteed to work only on SGI machines.
+In practice it is highly portable to any 32-bit or 64-bit system and much
+work has been done to insure portability to 16-bit systems.
+If you encounter portability problems please return fixes so
+that future distributions can be improved.
+
+
+The software is written to assume an ANSI C compilation environment.
+If your compiler does not support ANSI function prototypes, const,
+and <stdarg.h> then you will have to make modifications to the
+software. In the past I have tried to support compilers without const
+and systems without <stdarg.h>, but I am
+no longer interested in these
+antiquated environments. With the general availability of
+the freely available GCC compiler, I
+see no reason to incorporate modifications to the software for these
+purposes.
+
+
+An effort has been made to isolate as many of the
+operating system-dependencies
+as possible in two files: tiffcomp.h and
+libtiff/tif_<os>.c. The latter file contains
+operating system-specific routines to do I/O and I/O-related operations.
+The UNIX (tif_unix.c),
+Macintosh (tif_apple.c),
+and VMS (tif_vms.c)
+code has had the most use;
+the MS/DOS support (tif_msdos.c) assumes
+some level of UNIX system call emulation (i.e.
+open,
+read,
+write,
+fstat,
+malloc,
+free).
+
+
+Native CPU byte order is determined on the fly by
+the library and does not need to be specified.
+The HOST_FILLORDER and HOST_BIGENDIAN
+definitions are not currently used, but may be employed by
+codecs for optimization purposes.
+
+
+The following defines control general portability:
+
+
+
+On UNIX systems HAVE_MMAP is defined through the running of
+the configure script; otherwise support for memory-mapped
+files is disabled.
+Note that tiffcomp.h defines HAVE_IEEEFP to be
+1 (BSDTYPES is not defined).
+
+
+
+
+(to clarify dblparam_t, it is the type that float parameters are
+promoted to when passed by value in a function call.)
+
+
+The following typedefs are used throughout the library and interfaces
+to refer to certain objects whose size is dependent on the TIFF image
+structure:
+
+
+
+
+Note that tstrip_t, ttile_t, and tsize_t
+are constrained to be
+no more than 32-bit quantities by 32-bit fields they are stored
+in in the TIFF image. Likewise tsample_t is limited by the 16-bit
+field used to store the SamplesPerPixel tag. tdir_t
+constrains
+the maximum number of IFDs that may appear in an image and may
+be an arbitrary size (without penalty). ttag_t must be either
+int, unsigned int, pointer, or double
+because the library uses a varargs
+interface and ANSI C restricts the type of the parameter before an
+ellipsis to be a promoted type. toff_t is defined as
+int32 because
+TIFF file offsets are (unsigned) 32-bit quantities. A signed
+value is used because some interfaces return -1 on error (sigh).
+Finally, note that tidata_t is used internally to the library to
+manipulate internal data. User-specified data references are
+passed as opaque handles and only cast at the lowest layers where
+their type is presumed.
+
+
+
+If you want to maintain portability, beware of making assumptions
+about data types. Use the typedefs (uint16, etc. when dealing with
+data on disk and t*_t when stuff is in memory) and be careful about
+passing items through printf or similar vararg interfaces.
+
+
+A codec, say foo, can have many different entry points:
+
+
+Note that the encoding and decoding variants are only needed when
+a compression algorithm is dependent on the structure of the data.
+For example, Group 3 2D encoding and decoding maintains a reference
+scanline. The sample parameter identifies which sample is to be
+encoded or decoded if the image is organized with PlanarConfig=2
+(separate planes). This is important for algorithms such as JPEG.
+If PlanarConfig=1 (interleaved), then sample will always be 0.
+
+
+
+The variables tif_rawcc, tif_rawdata, and
+tif_rawcp in a TIFF structure
+are associated with the raw data buffer. tif_rawcc must be non-zero
+for the library to automatically flush data. The variable
+tif_scanlinesize is the size a user's scanline buffer should be. The
+variable tif_tilesize is the size of a tile for tiled images. This
+should not normally be used by compression routines, except where it
+relates to the compression algorithm. That is, the cc parameter to the
+tif_decode* and tif_encode*
+routines should be used in terminating
+decompression/compression. This ensures these routines can be used,
+for example, to decode/encode entire strips of data.
+
+
+In general, if you have a new compression algorithm to add, work from
+the code for an existing routine. In particular,
+tif_dumpmode.c
+has the trivial code for the "nil" compression scheme,
+tif_packbits.c is a
+simple byte-oriented scheme that has to watch out for buffer
+boundaries, and tif_lzw.c has the LZW scheme that has the most
+complexity -- it tracks the buffer boundary at a bit level.
+Of course, using a private compression scheme (or private tags) limits
+the portability of your TIFF files.
+
+
+
+The following definitions are used throughout this documentation.
+They are consistent with the terminology used in the TIFF 6.0 specification.
+
+
+In order to better understand how TIFF works (and consequently this
+software) it is important to recognize the distinction between the
+physical organization of image data as it is stored in a TIFF and how
+the data is interpreted and manipulated as pixels in an image. TIFF
+supports a wide variety of storage and data compression schemes that
+can be used to optimize retrieval time and/or minimize storage space.
+These on-disk formats are independent of the image characteristics; it
+is the responsibility of the TIFF reader to process the on-disk storage
+into an in-memory format suitable for an application. Furthermore, it
+is the responsibility of the application to properly interpret the
+visual characteristics of the image data. TIFF defines a framework for
+specifying the on-disk storage format and image characteristics with
+few restrictions. This permits significant complexity that can be
+daunting. Good applications that handle TIFF work by handling as wide
+a range of storage formats as possible, while constraining the
+acceptable image characteristics to those that make sense for the
+application.
+
+
+
+
+libtiff is a set of C functions (a library) that support
+the manipulation of TIFF image files.
+The library requires an ANSI C compilation environment for building
+and presumes an ANSI C environment for use.
+
+
+libtiff
+provides interfaces to image data at several layers of abstraction (and cost).
+At the highest level image data can be read into an 8-bit/sample,
+ABGR pixel raster format without regard for the underlying data organization,
+colorspace, or compression scheme. Below this high-level interface
+the library provides scanline-, strip-, and tile-oriented interfaces that
+return data decompressed but otherwise untransformed. These interfaces
+require that the application first identify the organization of stored
+data and select either a strip-based or tile-based API for manipulating
+data. At the lowest level the library
+provides access to the raw uncompressed strips or tiles,
+returning the data exactly as it appears in the file.
+
+
+The material presented in this chapter is a basic introduction
+to the capabilities of the library; it is not an attempt to describe
+everything a developer needs to know about the library or about TIFF.
+Detailed information on the interfaces to the library are given in
+the
+UNIX manual pages that accompany this software.
+
+
+The following sections are found in this chapter:
+
+
+Within an application that uses libtiff the TIFFGetVersion
+routine will return a pointer to a string that contains software version
+information.
+The library include file <tiffio.h> contains a C pre-processor
+define TIFFLIB_VERSION that can be used to check library
+version compatiblity at compile time.
+
+
+To deal with segmented pointer issues libtiff also provides
+_TIFFmemcpy, _TIFFmemset, and _TIFFmemmove
+routines that mimic the equivalent ANSI C routines, but that are
+intended for use with memory allocated through _TIFFmalloc
+and _TIFFrealloc.
+
+
+To create or overwrite a TIFF image the file is also opened, but with
+a "w" argument:
+
+
+
+libtiff buffers much information associated with writing a
+valid TIFF image. Consequently, when writing a TIFF image it is necessary
+to always call TIFFClose or TIFFFlush to flush any
+buffered information to a file. Note that if you call TIFFClose
+you do not need to call TIFFFlush.
+
+
+libtiff provides several routines for reading and writing
+directories. In normal use there is no need to explicitly
+read or write a directory: the library automatically reads the first
+directory in a file when opened for reading, and directory information
+to be written is automatically accumulated and written when writing
+(assuming TIFFClose or TIFFFlush are called).
+
+
+For a file open for reading the TIFFSetDirectory routine can
+be used to select an arbitrary directory; directories are referenced by
+number with the numbering starting at 0. Otherwise the
+TIFFReadDirectory and TIFFWriteDirectory routines can
+be used for sequential access to directories.
+For example, to count the number of directories in a file the following
+code might be used:
+
+
+Finally, note that there are several routines for querying the
+directory status of an open file:
+TIFFCurrentDirectory returns the index of the current
+directory and
+TIFFLastDirectory returns an indication of whether the
+current directory is the last directory in a file.
+There is also a routine, TIFFPrintDirectory, that can
+be called to print a formatted description of the contents of
+the current directory; consult the manual page for complete details.
+
+
+libtiff reads the contents of a directory all at once
+and converts the on-disk information to an appropriate in-memory
+form. While the TIFF specification permits an arbitrary set of
+tags to be defined and used in a file, the library only understands
+a limited set of tags.
+Any unknown tags that are encountered in a file are ignored.
+There is a mechanism to extend the set of tags the library handles
+without modifying the library itself;
+this is described elsewhere.
+
+
+libtiff provides two interfaces for getting and setting tag
+values: TIFFGetField and TIFFSetField.
+These routines use a variable argument list-style interface to pass
+parameters of different type through a single function interface.
+The get interface takes one or more pointers to memory locations
+where the tag values are to be returned and also returns one or
+zero according to whether the requested tag is defined in the directory.
+The set interface takes the tag values either by-reference or
+by-value.
+The TIFF specification defines
+default values for some tags.
+To get the value of a tag, or its default value if it is undefined,
+the TIFFGetFieldDefaulted interface may be used.
+
+
+The manual pages for the tag get and set routines specifiy the exact data types
+and calling conventions required for each tag supported by the library.
+
+
+Compression schemes are implemented by software modules termed codecs
+that implement decoder and encoder routines that hook into the
+core library i/o support.
+Codecs other than those bundled with the library can be registered
+for use with the TIFFRegisterCODEC routine.
+This interface can also be used to override the core-library
+implementation for a compression scheme.
+
+
+There are two ways to read image data using this interface. If
+all the data is to be stored in memory and manipulated at once,
+then the routine TIFFReadRGBAImage can be used:
+
+
+Alternatively, TIFFReadRGBAImage can be replaced with a
+more low-level interface that permits an application to have more
+control over this reading procedure. The equivalent to the above
+is:
+
+
+The second item is the main reason for this interface. By interposing
+a ``put method'' (the routine that is called to pack pixel data in
+the raster) it is possible share the core logic that understands how
+to deal with TIFF while packing the resultant pixels in a format that
+is optimized for the application. This alternate format might be very
+different than the 8-bit per sample ABGR format the library writes by
+default. For example, if the application is going to display the image
+on an 8-bit colormap display the put routine might take the data and
+convert it on-the-fly to the best colormap indices for display.
+
+
+The last item permits an application to extend the library
+without modifying the core code.
+By overriding the code provided an application might add support
+for some esoteric flavor of TIFF that it needs, or it might
+substitute a packing routine that is able to do optimizations
+using application/environment-specific information.
+
+
+The TIFF image viewer found in tools/sgigt.c is an example
+of an application that makes use of the TIFFRGBAImage
+support.
+
+
+Two routines are provided for scanline-based i/o:
+TIFFReadScanline
+and
+TIFFWriteScanline.
+For example, to read the contents of a file that
+is assumed to be organized in strips, the following might be used:
+
+
+A simple example of reading an image by strips is:
+
+
+The above code reads strips in the order in which the
+data is physically stored in the file. If multiple samples
+are present and data is stored with PLANARCONFIG_SEPARATE
+then all the strips of data holding the first sample will be
+read, followed by strips for the second sample, etc.
+
+
+Finally, note that the last strip of data in an image may have fewer
+rows in it than specified by the RowsPerStrip tag. A
+reader should not assume that each decoded strip contains a full
+set of rows in it.
+
+
+The following is an example of how to read raw strips of data from
+a file:
+
+
+Tiles and strips may also be extended in a z dimension to form
+volumes. Data volumes are organized as "slices". That is, all the
+data for a slice is colocated. Volumes whose data is organized in
+tiles can also have a tile depth so that data can be organized in
+cubes.
+
+
+There are actually two interfaces for tiles.
+One interface is similar to scanlines, to read a tiled image,
+code of the following sort might be used:
+
+
+Alternatively a direct interface to the low-level data is provided
+a la strips. Tiles can be read with
+TIFFReadEncodedTile or
+TIFFReadRawTile,
+and written with
+TIFFWriteEncodedTile or
+TIFFWriteRawTile.
+For example, to read all the tiles in an image:
+
+
+Some other stuff will almost certainly go here...
+
+
+
+#include <stdarg.h>
+
+
+
+Applications that desire to capture control in the event of an error
+should use
+TIFFSetErrorHandler
+
+to override the default error handler.
+A
+NULL
+(0) error handling function may be installed to
+suppress error messages.
+
+
+
+TIFFFlushData
+
+flushes any pending image data for the specified file to be written out;
+directory-related data are not flushed.
+In normal operation this call is never needed- the library
+automatically does any flushing required.
+
+
+#include <stdarg.h>
+
+
+int TIFFGetFieldDefaulted(TIFF* tif, ttag_t tag, ...)
+
+
+
+TIFFVGetField
+
+is functionally equivalent to
+TIFFGetField
+
+except that it takes a pointer to a variable
+argument list.
+TIFFVGetField
+
+is useful for layering interfaces on top of
+the functionality provided by
+TIFFGetField.
+
+
+
+TIFFGetFieldDefaulted
+
+and
+TIFFVGetFieldDefaulted
+
+are identical to
+TIFFGetField
+
+and
+TIFFVGetField,
+
+except that if a tag is not defined in the current directory
+and it has a default value, then the default value is returned.
+
+
+The tags understood by
+libtiff,
+
+the number of parameter values, and the
+types for the returned values are shown below.
+The data types are specified as in C and correspond
+to the types used to specify tag values to
+TIFFSetField(3T).
+
+Remember that
+TIFFGetField
+
+returns parameter values, so all the listed
+data types are pointers to storage where values
+should be returned.
+Consult the
+TIFF
+specification for information on the meaning of
+each tag and their possible values.
+
+
+
+
+Unknown field, tag 0x%x.
+
+An unknown tag was supplied.
+
+
+
+If a file is opened for reading, the first
+TIFF
+directory in the file is automatically read
+(also see
+TIFFSetDirectory(3T)
+
+for reading directories other than the first).
+If a file is opened for writing or appending, a default directory
+is automatically created for writing subsequent data.
+This directory has all the default values specified in
+TIFF
+Revision 6.0:
+BitsPerSample=1,
+
+ThreshHolding=bilevel art scan,
+
+FillOrder=1
+
+(most significant bit of each data byte is filled first),
+Orientation=1
+
+(the 0th row represents the visual top of the image, and the 0th
+column represents the visual left hand side),
+SamplesPerPixel=1,
+
+RowsPerStrip=infinity,
+
+ResolutionUnit=2
+
+(inches), and
+Compression=1
+
+(no compression).
+To alter these values, or to define values for additional fields,
+TIFFSetField(3T)
+
+must be used.
+
+
+TIFFFdOpen
+
+is like
+TIFFOpen
+
+except that it opens a
+TIFF
+file given an open file descriptor
+fd.
+
+The file's name and mode must reflect that of the open descriptor.
+The object associated with the file descriptor
+must support random access.
+
+
+
+TIFFClientOpen
+
+is like
+TIFFOpen
+
+except that the caller supplies a collection of functions that the
+library will use to do UNIX-like I/O operations.
+The
+readproc
+
+and
+writeproc
+
+are called to read and write data at the current file position.
+seekproc
+
+is called to change the current file position a la
+lseek(2).
+
+closeproc
+
+is invoked to release any resources associated with an open file.
+sizeproc
+
+is invoked to obtain the size in bytes of a file.
+mapproc
+
+and
+unmapproc
+
+are called to map and unmap a file's contents in memory; c.f.
+mmap(2)
+
+and
+munmap(2).
+
+The
+clientdata
+
+parameter is an opaque ``handle'' passed to the client-specified
+routines passed as parameters to
+TIFFClientOpen.
+
+
+
+
+"%s": Bad mode.
+The specified
+mode
+
+parameter was not one of ``r'' (read), ``w'' (write), or ``a'' (append).
+
+
+%s: Cannot open.
+
+TIFFOpen()
+
+was unable to open the specified filename for read/writing.
+
+
+Cannot read TIFF header.
+
+An error occurred while attempting to read the header information.
+
+
+Error writing TIFF header.
+
+An error occurred while writing the default header information
+for a new file.
+
+
+Not a TIFF file, bad magic number %d (0x%x).
+
+The magic number in the header was not (hex)
+0x4d4d or (hex) 0x4949.
+
+
+Not a TIFF file, bad version number %d (0x%x).
+
+The version field in the header was not 42 (decimal).
+
+
+Cannot append to file that has opposite byte ordering.
+
+A file with a byte ordering opposite to the native byte
+ordering of the current machine was opened for appending (``a'').
+This is a limitation of the library.
+
+
+
+
+The default usage for these routines is: check if an image can
+be processed using
+TIFFRGBAImageOK,
+
+construct a decoder state block using
+TIFFRGBAImageBegin,
+
+read and decode an image into a target raster using
+TIFFRGBAImageGet,
+
+and then
+release resources using
+TIFFRGBAImageEnd.
+
+TIFFRGBAImageGet
+
+can be called multiple times to decode an image using different
+state parameters.
+If multiple images are to be displayed and there is not enough
+space for each of the decoded rasters, multiple state blocks can
+be managed and then calls can be made to
+TIFFRGBAImageGet
+
+as needed to display an image.
+
+
+The generated raster is assumed to be an array of
+width
+
+times
+height
+
+32-bit entries, where
+width
+
+must be less than or equal to the width of the image (height
+
+may be any non-zero size).
+If the raster dimensions are smaller than the image, the image data
+is cropped to the raster bounds.
+If the raster height is greater than that of the image, then the
+image data are placed in the lower part of the raster.
+(Note that the raster is assume to be organized such that the pixel
+at location (x,y) is raster[y*width+x];
+with the raster origin in the lower-left hand corner.)
+
+
+Raster pixels are 8-bit packed red, green, blue, alpha samples.
+The macros
+TIFFGetR,
+
+TIFFGetG,
+
+TIFFGetB,
+
+and
+TIFFGetA
+
+should be used to access individual samples.
+Images without Associated Alpha matting information have a constant
+Alpha of 1.0 (255).
+
+
+TIFFRGBAImageGet
+
+converts non-8-bit images by scaling sample values.
+Palette, grayscale, bilevel,
+CMYK, and YCbCr images are converted to
+RGB
+transparently.
+Raster pixels are returned uncorrected by any colorimetry information
+present in the directory.
+
+
+The paramater
+stopOnError
+
+specifies how to act if an error is encountered while reading
+the image.
+If
+stopOnError
+
+is non-zero, then an error will terminate the operation; otherwise
+TIFFRGBAImageGet
+
+will continue processing data until all the possible data in the
+image have been requested.
+
+
+
+(the original routine provided by the library is saved in the
+variable
+putContig.)
+
+
+
+
+Palettte image colormaps that appear to be incorrectly written
+as 8-bit values are automatically scaled to 16-bits.
+
+
+
+Sorry, can not handle %d-bit pictures.
+
+The image had
+BitsPerSample
+
+other than 1, 2, 4, 8, or 16.
+
+
+Sorry, can not handle %d-channel images.
+
+The image had
+SamplesPerPixel
+
+other than 1, 3, or 4.
+
+
+Missing needed "PhotometricInterpretation" tag.
+The image did not have a tag that describes how to display
+the data.
+
+
+No "PhotometricInterpretation" tag, assuming RGB.
+The image was missing a tag that describes how to display it,
+but because it has 3 or 4 samples/pixel, it is assumed to be
+RGB.
+
+
+No "PhotometricInterpretation" tag, assuming min-is-black.
+The image was missing a tag that describes how to display it,
+but because it has 1 sample/pixel, it is assumed to be a grayscale
+or bilevel image.
+
+
+No space for photometric conversion table.
+
+There was insufficient memory for a table used to convert
+image samples to 8-bit
+RGB.
+
+
+Missing required "Colormap" tag.
+A Palette image did not have a required
+Colormap
+
+tag.
+
+
+No space for tile buffer.
+
+There was insufficient memory to allocate an i/o buffer.
+
+
+No space for strip buffer.
+
+There was insufficient memory to allocate an i/o buffer.
+
+
+Can not handle format.
+
+The image has a format (combination of
+BitsPerSample,
+
+SamplesPerPixel,
+
+and
+PhotometricInterpretation)
+
+that can not be handled.
+
+
+No space for B&W mapping table.
+
+There was insufficient memory to allocate a table used to map
+grayscale data to
+RGB.
+
+
+No space for Palette mapping table.
+
+There was insufficient memory to allocate a table used to map
+data to 8-bit
+RGB.
+
+
+
+Seek error accessing TIFF directory.
+An error occurred while positioning to the location of the
+directory.
+
+
+Wrong data type %d for field "%s".
+The tag entry in the directory had an incorrect data type.
+For example, an
+ImageDescription
+
+tag with a
+SHORT
+data type.
+
+
+TIFF directory is missing required "%s" field.
+The specified tag is required to be present by the
+TIFF
+5.0 specification, but is missing.
+The directory is (usually) unusable.
+
+
+%s: Rational with zero denominator.
+A directory tag has a
+RATIONAL
+value whose denominator is zero.
+
+
+Incorrect count %d for field "%s" (%lu, expecting %lu); tag ignored.
+The specified tag's count field is bad.
+For example, a count other than 1 for a
+SubFileType
+
+tag.
+
+
+Cannot handle different per-sample values for field "%s".
+The tag has
+SamplesPerPixel
+
+values and they are not all the same; e.g.
+BitsPerSample.
+
+The library is unable to handle images of this sort.
+
+
+Count mismatch for field "%s"; expecting %d, got %d.
+The count field in a
+tag does not agree with the number expected by the library.
+This should never happen, so if it does, the library refuses to
+read the directory.
+
+
+Invalid TIFF directory; tags are not sorted in ascending order.
+The directory tags are not properly sorted as specified
+in the
+TIFF
+5.0 specification.
+This error is not fatal.
+
+
+Ignoring unknown field with tag %d (0x%x).
+An unknown tag was encountered in the directory;
+the library ignores all such tags.
+
+
+TIFF directory is missing requred "ImageLength" field.
+The image violates the specification by not having a necessary field.
+There is no way for the library to recover from this error.
+
+
+TIFF directory is missing requred "PlanarConfig" field.
+The image violates the specification by not having a necessary field.
+There is no way for the library to recover from this error.
+
+
+TIFF directory is missing requred "StripOffsets" field.
+The image has multiple strips, but is missing the tag that
+specifies the file offset to each strip of data.
+There is no way for the library to recover from this error.
+
+
+TIFF directory is missing requred "TileOffsets" field.
+The image has multiple tiles, but is missing the tag that
+specifies the file offset to each tile of data.
+There is no way for the library to recover from this error.
+
+
+TIFF directory is missing required "StripByteCounts" field.
+The image has multiple strips, but is missing the tag that
+specifies the size of each strip of data.
+There is no way for the library to recover from this error.
+
+
+TIFF directory is missing required "StripByteCounts" field, calculating from imagelength.
+The image violates the specification by not having a necessary field.
+However, when the image is comprised of only one strip or tile, the
+library will estimate the missing value based on the file size.
+
+
+Bogus "StripByteCounts" field, ignoring and calculating from imagelength.
+Certain vendors violate the specification by writing zero for
+the StripByteCounts tag when they want to leave the value
+unspecified.
+If the image has a single strip, the library will estimate
+the missing value based on the file size.
+
+
+
+The library attempts to hide bit- and byte-ordering differences
+between the image and the native machine by converting data
+to the native machine order.
+Bit reversal is done if the
+FillOrder
+
+tag is opposite to the native machine bit order.
+16- and 32-bit samples are automatically byte-swapped if the
+file was written with a byte order opposite to the native
+machine byte order,
+
+
+
+The library attempts to hide bit- and byte-ordering differences
+between the image and the native machine by converting data
+to the native machine order.
+Bit reversal is done if the
+FillOrder
+
+tag is opposite to the native machine bit order.
+16- and 32-bit samples are automatically byte-swapped if the
+file was written with a byte order opposite to the native
+machine byte order,
+
+
+
+Raster pixels are 8-bit packed red, green, blue, alpha samples.
+The macros
+TIFFGetR,
+
+TIFFGetG,
+
+TIFFGetB,
+
+and
+TIFFGetA
+
+should be used to access individual samples.
+Images without Associated Alpha matting information have a constant
+Alpha of 1.0 (255).
+
+
+TIFFReadRGBAImage
+
+converts non-8-bit images by scaling sample values.
+Palette, grayscale, bilevel,
+CMYK, and YCbCr images are converted to
+RGB
+transparently.
+Raster pixels are returned uncorrected by any colorimetry information
+present in the directory.
+
+
+The paramater
+stopOnError
+
+specifies how to act if an error is encountered while reading
+the image.
+If
+stopOnError
+
+is non-zero, then an error will terminate the operation; otherwise
+TIFFReadRGBAImage
+
+will continue processing data until all the possible data in the
+image have been requested.
+
+
+
+Samples must be either 1, 2, 4, 8, or 16 bits.
+Colorimetric samples/pixel must be either 1, 3, or 4 (i.e.
+SamplesPerPixel
+
+minus
+ExtraSamples).
+
+
+
+Palettte image colormaps that appear to be incorrectly written
+as 8-bit values are automatically scaled to 16-bits.
+
+
+TIFFReadRGBAImage
+
+is just a wrapper around the more general
+TIFFRGBAImage(3T)
+
+facilities.
+
+
+
+Sorry, can not handle %d-bit pictures.
+
+The image had
+BitsPerSample
+
+other than 1, 2, 4, 8, or 16.
+
+
+Sorry, can not handle %d-channel images.
+
+The image had
+SamplesPerPixel
+
+other than 1, 3, or 4.
+
+
+Missing needed "PhotometricInterpretation" tag.
+The image did not have a tag that describes how to display
+the data.
+
+
+No "PhotometricInterpretation" tag, assuming RGB.
+The image was missing a tag that describes how to display it,
+but because it has 3 or 4 samples/pixel, it is assumed to be
+RGB.
+
+
+No "PhotometricInterpretation" tag, assuming min-is-black.
+The image was missing a tag that describes how to display it,
+but because it has 1 sample/pixel, it is assumed to be a grayscale
+or bilevel image.
+
+
+No space for photometric conversion table.
+
+There was insufficient memory for a table used to convert
+image samples to 8-bit
+RGB.
+
+
+Missing required "Colormap" tag.
+A Palette image did not have a required
+Colormap
+
+tag.
+
+
+No space for tile buffer.
+
+There was insufficient memory to allocate an i/o buffer.
+
+
+No space for strip buffer.
+
+There was insufficient memory to allocate an i/o buffer.
+
+
+Can not handle format.
+
+The image has a format (combination of
+BitsPerSample,
+
+SamplesPerPixel,
+
+and
+PhotometricInterpretation)
+
+that
+TIFFReadRGBAImage
+
+can not handle.
+
+
+No space for B&W mapping table.
+
+There was insufficient memory to allocate a table used to map
+grayscale data to
+RGB.
+
+
+No space for Palette mapping table.
+
+There was insufficient memory to allocate a table used to map
+data to 8-bit
+RGB.
+
+
+
+
+The
+strip
+
+value should be the strip number (strip zero is the first) as returned by the
+TIFFComputeStrip
+
+function, but always for sample 0.
+
+
+
+Note that the raster is assume to be organized such that the pixel
+at location (x,y) is raster[y*width+x];
+with the raster origin in the
+lower-left hand corner
+
+of the strip. That is bottom to top organization. When reading a partial
+last strip in the file the last line of the image will begin at the
+beginning of the buffer.
+
+
+
+Raster pixels are 8-bit packed red, green, blue, alpha samples.
+The macros
+TIFFGetR,
+
+TIFFGetG,
+
+TIFFGetB,
+
+and
+TIFFGetA
+
+should be used to access individual samples.
+Images without Associated Alpha matting information have a constant
+Alpha of 1.0 (255).
+
+
+See the
+TIFFRGBAImage(3T)
+
+page for more details on how various image types are converted to RGBA
+values.
+
+
+
+Palette image colormaps that appear to be incorrectly written
+as 8-bit values are automatically scaled to 16-bits.
+
+
+TIFFReadRGBAStrip
+
+is just a wrapper around the more general
+TIFFRGBAImage(3T)
+
+facilities. It's main advantage over the similar
+TIFFReadRGBAImage()
+
+function is that for large images a single
+buffer capable of holding the whole image doesn't need to be allocated,
+only enough for one strip. The
+TIFFReadRGBATile()
+
+function does a similar operation for tiled images.
+
+
+
+Sorry, can not handle %d-bit pictures.
+
+The image had
+BitsPerSample
+
+other than 1, 2, 4, 8, or 16.
+
+
+Sorry, can not handle %d-channel images.
+
+The image had
+SamplesPerPixel
+
+other than 1, 3, or 4.
+
+
+Missing needed "PhotometricInterpretation" tag.
+The image did not have a tag that describes how to display
+the data.
+
+
+No "PhotometricInterpretation" tag, assuming RGB.
+The image was missing a tag that describes how to display it,
+but because it has 3 or 4 samples/pixel, it is assumed to be
+RGB.
+
+
+No "PhotometricInterpretation" tag, assuming min-is-black.
+The image was missing a tag that describes how to display it,
+but because it has 1 sample/pixel, it is assumed to be a grayscale
+or bilevel image.
+
+
+No space for photometric conversion table.
+
+There was insufficient memory for a table used to convert
+image samples to 8-bit
+RGB.
+
+
+Missing required "Colormap" tag.
+A Palette image did not have a required
+Colormap
+
+tag.
+
+
+No space for tile buffer.
+
+There was insufficient memory to allocate an i/o buffer.
+
+
+No space for strip buffer.
+
+There was insufficient memory to allocate an i/o buffer.
+
+
+Can not handle format.
+
+The image has a format (combination of
+BitsPerSample,
+
+SamplesPerPixel,
+
+and
+PhotometricInterpretation)
+
+that
+TIFFReadRGBAImage
+
+can not handle.
+
+
+No space for B&W mapping table.
+
+There was insufficient memory to allocate a table used to map
+grayscale data to
+RGB.
+
+
+No space for Palette mapping table.
+
+There was insufficient memory to allocate a table used to map
+data to 8-bit
+RGB.
+
+
+
+
+The
+x
+
+and
+y
+
+values are the offsets from the top left corner to the top left corner
+of the tile to be read. They must be an exact multiple of the tile
+width and length.
+
+
+
+Note that the raster is assume to be organized such that the pixel
+at location (x,y) is raster[y*width+x];
+with the raster origin in the
+lower-left hand corner
+
+of the tile. That is bottom to top organization. Edge tiles which
+partly fall off the image will be filled out with appropriate zeroed
+areas.
+
+
+
+Raster pixels are 8-bit packed red, green, blue, alpha samples.
+The macros
+TIFFGetR,
+
+TIFFGetG,
+
+TIFFGetB,
+
+and
+TIFFGetA
+
+should be used to access individual samples.
+Images without Associated Alpha matting information have a constant
+Alpha of 1.0 (255).
+
+
+See the
+TIFFRGBAImage(3T)
+
+page for more details on how various image types are converted to RGBA
+values.
+
+
+
+Palette image colormaps that appear to be incorrectly written
+as 8-bit values are automatically scaled to 16-bits.
+
+
+TIFFReadRGBATile
+
+is just a wrapper around the more general
+TIFFRGBAImage(3T)
+
+facilities. It's main advantage over the similar
+TIFFReadRGBAImage()
+
+function is that for large images a single
+buffer capable of holding the whole image doesn't need to be allocated,
+only enough for one tile. The
+TIFFReadRGBAStrip()
+
+function does a similar operation for stripped images.
+
+
+
+Sorry, can not handle %d-bit pictures.
+
+The image had
+BitsPerSample
+
+other than 1, 2, 4, 8, or 16.
+
+
+Sorry, can not handle %d-channel images.
+
+The image had
+SamplesPerPixel
+
+other than 1, 3, or 4.
+
+
+Missing needed "PhotometricInterpretation" tag.
+The image did not have a tag that describes how to display
+the data.
+
+
+No "PhotometricInterpretation" tag, assuming RGB.
+The image was missing a tag that describes how to display it,
+but because it has 3 or 4 samples/pixel, it is assumed to be
+RGB.
+
+
+No "PhotometricInterpretation" tag, assuming min-is-black.
+The image was missing a tag that describes how to display it,
+but because it has 1 sample/pixel, it is assumed to be a grayscale
+or bilevel image.
+
+
+No space for photometric conversion table.
+
+There was insufficient memory for a table used to convert
+image samples to 8-bit
+RGB.
+
+
+Missing required "Colormap" tag.
+A Palette image did not have a required
+Colormap
+
+tag.
+
+
+No space for tile buffer.
+
+There was insufficient memory to allocate an i/o buffer.
+
+
+No space for strip buffer.
+
+There was insufficient memory to allocate an i/o buffer.
+
+
+Can not handle format.
+
+The image has a format (combination of
+BitsPerSample,
+
+SamplesPerPixel,
+
+and
+PhotometricInterpretation)
+
+that
+TIFFReadRGBAImage
+
+can not handle.
+
+
+No space for B&W mapping table.
+
+There was insufficient memory to allocate a table used to map
+grayscale data to
+RGB.
+
+
+No space for Palette mapping table.
+
+There was insufficient memory to allocate a table used to map
+data to 8-bit
+RGB.
+
+
+
+In C++ the
+sample
+
+parameter defaults to 0.
+
+
+
+Compression algorithm does not support random access.
+
+Data was requested in a non-sequential order from a file that
+uses a compression algorithm and that has
+RowsPerStrip
+
+greater than one.
+That is, data in the image is stored in a compressed form,
+and with multiple rows packed into a strip.
+In this case, the library does not support random access to the data.
+The data should either be accessed sequentially, or the file
+should be converted so that each strip is made up of one row
+of data.
+
+
+
+TIFFSetSubDirectory
+
+acts like
+TIFFSetDirectory,
+
+except the directory is specified as a
+file offset instead of an index; this is required for accessing
+subdirectories linked through a
+SubIFD
+
+tag.
+
+
+
+%s: Error fetching directory count.
+
+An error was encountered while reading the ``directory count'' field.
+
+
+%s: Error fetching directory link.
+
+An error was encountered while reading the ``link value'' that
+points to the next directory in a file.
+
+
+
+TIFFVSetField
+
+is functionally equivalent to
+TIFFSetField
+
+except that it takes a pointer to a variable
+argument list.
+TIFFVSetField
+
+is useful for writing routines that are layered
+on top of the functionality provided by
+TIFFSetField.
+
+
+
+The tags understood by
+libtiff,
+
+the number of parameter values, and the
+expected types for the parameter values are shown below.
+The data types are:
+char*
+
+is null-terminated string and corresponds to the
+ASCII
+data type;
+uint16
+
+is an unsigned 16-bit value;
+uint32
+
+is an unsigned 32-bit value;
+uint16*
+
+is an array of unsigned 16-bit values.
+void*
+
+is an array of data values of unspecified type.
+
+Consult the
+TIFF
+specification for information on the meaning of each tag.
+
+
+
++ Tag may not have its values changed once data is written.
+
+
+%s: Cannot modify tag "%s" while writing.
+Data has already been written to the file, so the
+specified tag's value can not be changed.
+This restriction is applied to all tags that affect
+the format of written data.
+
+
+%d: Bad value for "%s".
+An invalid value was supplied for the named tag.
+
+
+#include <stdargh.h>
+
+
+
+Applications that desire to capture control in the event of a warning
+should use
+TIFFSetWarningHandler
+
+to override the default warning handler.
+A
+NULL
+(0) warning handler function may be installed to
+suppress error messages.
+
+
+
+Error post-encoding before directory write.
+
+Before writing the contents of the current directory, any pending
+data are flushed.
+This message indicates that an error occurred while doing this.
+
+
+Error flushing data before directory write.
+
+Before writing the contents of the current directory, any pending
+data are flushed.
+This message indicates that an error occurred while doing this.
+
+
+Cannot write directory, out of space.
+
+There was not enough space to allocate a temporary area for
+the directory that was to be written.
+
+
+Error writing directory count.
+
+A write error occurred when writing the count of fields in the directory.
+
+
+Error writing directory contents.
+
+A write error occurred when writing the directory fields.
+
+
+Error writing directory link.
+
+A write error occurred when writing the link to the next directory.
+
+
+Error writing data for field "%s".
+A write error occurred when writing indirect data for the specified field.
+
+
+Error writing TIFF header.
+
+A write error occurred when re-writing header at the front of the file.
+
+
+Error fetching directory count.
+
+A read error occurred when fetching the directory count field for
+a previous directory.
+This can occur when setting up a link to the directory that is being
+written.
+
+
+Error fetching directory link.
+
+A read error occurred when fetching the directory link field for
+a previous directory.
+This can occur when setting up a link to the directory that is being
+written.
+
+
+
+The strip number must be valid according to the current settings
+of the
+ImageLength
+
+and
+RowsPerStrip
+
+tags.
+An image may be dynamically grown by increasing the value of
+ImageLength
+
+prior to each call to
+TIFFWriteEncodedStrip.
+
+
+
+
+%s: File not open for writing.
+The file was opened for reading, not writing.
+
+
+Can not write scanlines to a tiled image.
+The image is assumed to be organized in tiles because the
+TileWidth
+
+and
+TileLength
+
+tags have been set with
+TIFFSetField(3T).
+
+
+
+%s: Must set "ImageWidth" before writing data.
+The image's width has not be set before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: Must set "PlanarConfiguration" before writing data.
+The organization of data has not be defined before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: No space for strip arrays".
+There was not enough space for the arrays that hold strip
+offsets and byte counts.
+
+
+
+%s: File not open for writing.
+The file was opened for reading, not writing.
+
+
+Can not write tiles to a stripped image.
+The image is assumed to be organized in strips because neither of the
+TileWidth
+
+or
+TileLength
+
+tags have been set with
+TIFFSetField(3T).
+
+
+
+%s: Must set "ImageWidth" before writing data.
+The image's width has not be set before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: Must set "PlanarConfiguration" before writing data.
+The organization of data has not be defined before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: No space for tile arrays".
+There was not enough space for the arrays that hold tile
+offsets and byte counts.
+
+
+
+%s: File not open for writing.
+The file was opened for reading, not writing.
+
+
+Can not write scanlines to a tiled image.
+The image is assumed to be organized in tiles because the
+TileWidth
+
+and
+TileLength
+
+tags have been set with
+TIFFSetField(3T).
+
+
+
+%s: Must set "ImageWidth" before writing data.
+The image's width has not be set before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: Must set "PlanarConfiguration" before writing data.
+The organization of data has not be defined before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: No space for strip arrays".
+There was not enough space for the arrays that hold strip
+offsets and byte counts.
+
+
+%s: Strip %d out of range, max %d.
+The specified strip is not a valid strip according to the
+currently specified image dimensions.
+
+
+
+%s: File not open for writing.
+The file was opened for reading, not writing.
+
+
+Can not write tiles to a stripped image.
+The image is assumed to be organized in strips because neither of the
+TileWidth
+
+or
+TileLength
+
+tags have been set with
+TIFFSetField(3T).
+
+
+
+%s: Must set "ImageWidth" before writing data.
+The image's width has not be set before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: Must set "PlanarConfiguration" before writing data.
+The organization of data has not be defined before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: No space for tile arrays".
+There was not enough space for the arrays that hold tile
+offsets and byte counts.
+
+
+%s: Specified tile %d out of range, max %d.
+The specified tile is not valid according to the currently
+specified image dimensions.
+
+
+
+In C++ the
+sample
+
+parameter defaults to 0.
+
+
+Once data are written to a file for the current directory,
+the values of certain tags may not be altered; see
+TIFFSetField(3T)
+
+for more information.
+
+
+It is not possible to write scanlines to a file that
+uses a tiled organization. The routine
+TIFFIsTiled
+
+can be used to determine if the file is organized
+as tiles or strips.
+
+
+
+%s: File not open for writing .
+
+The file was opened for reading, not writing.
+
+
+Can not write scanlines to a tiled image.
+
+An attempt was made to write a scanline to a tiled image.
+The image is assumed to be organized in tiles because the
+TileWidth
+
+and
+TileLength
+
+tags have been set with
+TIFFSetField(3T).
+
+
+
+Compression algorithm does not support random access.
+
+Data was written in a non-sequential order to a file that
+uses a compression algorithm and that has
+RowsPerStrip
+
+greater than one.
+That is, data in the image is to be stored in a compressed form,
+and with multiple rows packed into a strip.
+In this case, the library does not support random access to the data.
+The data should either be written as entire strips,
+sequentially by rows, or the value of
+RowsPerStrip
+
+should be set to one.
+
+
+%s: Must set "ImageWidth" before writing data.
+The image's width has not be set before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+%s: Must set "PlanarConfiguration" before writing data.
+The organization of data has not be defined before the first write.
+See
+TIFFSetField(3T)
+
+for information on how to do this.
+
+
+Can not change "ImageLength" when using separate planes.
+Separate image planes are being used (PlanarConfiguration=2),
+
+but the number of rows has not been specified before the first write.
+The library supports the dynamic growth of an image only when data
+are organized in a contiguous manner (PlanarConfiguration=1).
+
+
+
+%d: Sample out of range, max %d.
+
+The
+sample
+
+parameter was greater than the value of the SamplesPerPixel tag.
+
+
+%s: No space for strip arrays .
+
+There was not enough space for the arrays that hold strip
+offsets and byte counts.
+
+
+
+TIFFReadBufferSetup
+
+sets up the data buffer used to read raw (encoded) data from a file.
+If the specified pointer is
+NULL
+(zero), then a buffer of the appropriate size is allocated.
+Otherwise the caller must guarantee that the buffer is large
+enough to hold any individual strip of raw data.
+TIFFReadBufferSetup
+
+returns a non-zero value if the setup was successful and zero otherwise.
+
+
+TIFFWriteBufferSetup
+
+sets up the data buffer used to write raw (encoded) data to a file.
+If the specified
+size
+
+is -1 then the buffer size is selected to hold a complete
+tile or strip, or at least 8 kilobytes, whichever is greater.
+If the specified
+buffer
+
+is
+NULL
+(zero), then a buffer of the appropriate size is dynamically allocated.
+TIFFWriteBufferSetup
+
+returns a non-zero value if the setup was successful and zero otherwise.
+
+
+
+%s: No space for output buffer.
+
+TIFFWriteBufferSetup
+
+was unable to dynamically allocate space for a data buffer.
+
+
+
+The
+TIFFRegisterCODEC
+
+routine can be used to
+augment or override the set of codecs available to an application.
+If the specified
+scheme
+
+already has a registered codec then it is
+overridden
+
+and any images with data encoded with this
+compression scheme will be decoded using the supplied coded.
+
+
+
+Cannot remove compression scheme %s; not registered.
+
+TIFFUnRegisterCODEC
+
+did not locate the specified codec in the table of registered
+compression schemes.
+
+
+
+_TIFFmalloc
+
+and
+_TIFFrealloc
+
+are used to dynamically allocate and reallocate memory used by
+libtiff;
+
+such as memory passed into the I/O routines.
+Memory allocated through these interfaces is released back to the
+system using the
+_TIFFfree
+
+routine.
+
+
+Memory allocated through one of the above interfaces can be set to
+a known value using
+_TIFFmemset,
+
+copied to another memory location using
+_TIFFmemcpy,
+
+or compared for equality using
+_TIFFmemcmp.
+
+These routines conform to the equivalent
+ANSI
+C routines:
+memset,
+
+memcpy,
+
+and
+memcmp,
+
+repsectively.
+
+
+
+TIFFCurrentDirectory
+
+returns the index of the current directory (directories
+are numbered starting at 0).
+This number is suitable for use with the
+TIFFSetDirectory
+
+routine.
+
+
+TIFFLastDirectory
+
+returns a non-zero value if the current directory is the
+last directory in the file;
+otherwise zero is returned.
+
+
+TIFFCurrentRow,
+
+TIFFCurrentStrip,
+
+and
+TIFFCurrentTile,
+
+return the current row, strip, and tile, respectively,
+that is being read or written.
+These values are updated each time a read or write is done.
+
+
+TIFFFileno
+
+returns the underlying file descriptor used to access the
+TIFF
+image in the filesystem.
+
+
+TIFFFileName
+
+returns the pathname argument passed to
+TIFFOpen
+
+or
+TIFFFdOpen.
+
+
+
+TIFFGetMode
+
+returns the mode with which the underlying file was opened.
+On
+UNIX
+systems, this is the value passed to the
+open(2)
+
+system call.
+
+
+TIFFIsTiled
+
+returns a non-zero value if the image data has
+a tiled organization.
+Zero is returned if the image data is organized in strips.
+
+
+TIFFIsByteSwapped
+
+returns a non-zero value if the image data was in a different
+byte-order than the host machine.
+Zero is returned if the image data and local host byte-orders
+are the same.
+Data samples that are more than 8 bits wide must be byte-swapped
+by the application.
+
+
+TIFFIsUpSampled
+
+returns a non-zero value if image data returned through the
+read interface routines is being up-sampled.
+This can be useful to applications that want to calculate
+I/O buffer sizes to reflect this usage (though the usual
+strip and tile size routines already do this).
+
+
+TIFFIsMSB2LSB
+
+returns a non-zero value if the image data is being returned with
+bit 0 as the most significant bit.
+
+
+TIFFGetVersion
+
+returns an
+ASCII
+string that has a version stamp for the
+TIFF
+library software.
+
+
+
+TIFFRasterScanlineSize
+
+returns the size in bytes of a complete decoded and packed
+raster scanline.
+Note that this value may be different from the value returned by
+TIFFScanlineSize
+
+if data is stored as separate planes.
+
+
+
+TIFFStripSize
+
+returns the equivalent size for a strip of data as it would
+be returned in a call to
+TIFFReadEncodedStrip
+
+or as it would be expected in a call to
+TIFFWriteEncodedStrip.
+
+
+
+TIFFVStripSize
+
+returns the number of bytes in a strip with
+nrows
+
+rows of data.
+
+
+TIFFComputeStrip
+
+returns the strip that contains the specified coordinates.
+A valid strip is always returned;
+out-of-range coordinate values are clamped to the bounds of the image.
+The
+row
+
+parameter is always used in calculating a strip.
+The
+sample
+
+parameter is used only if data are organized in separate planes (PlanarConfiguration=2).
+
+
+
+TIFFNumberOfStrips
+
+returns the number of strips in the image.
+
+
+
+TIFFSwabShort
+
+and
+TIFFSwabLong
+
+swap the bytes in a single 16-bit and 32-bit item, respectively.
+TIFFSwabArrayOfShort
+
+and
+TIFFSwabArrayOfLong
+
+swap the bytes in an array of 16-bit and 32-bit items, respectively.
+
+
+TIFFReverseBits
+
+replaces each byte in
+data
+
+with the equivalent bit-reversed value.
+This operation is done with a lookup table,
+TIFFBitRevTable
+
+which is declared public.
+A second table,
+TIFFNoBitRevTable
+
+is also declared public; it is a lookup table that
+can be used as an
+identity function;
+
+i.e.
+TIFFNoBitRevTable[n] == n.
+
+
+Building the Software on a Macintosh with CodeWarrior
+
+The directory contrib/mac-cw contains support for
+compiling the library and tools with MetroWerks CodeWarrior 6.1
+on a Macintosh system.
+This support was contributed by Niles Ritter
+(ndr@tazboy.jpl.nasa.gov).
+
+Building the Software on a VMS System
+
+The VMS port was done by Karsten Spang
+(krs@kampsax.dk), who also
+"sort of" maintains it.
+The VMS specific files are not in the main directories. Instead they
+are placed under [.CONTRIB.VMS...] in the distribution tree.
+
+Installation:
+
+It is assumed that you have unpacked the tar file into a VMS directory
+tree, in this text called DISK:[TIFF].
+
+
+
+
+You will want to add these lines to your LOGIN.COM
+file, after changing
+the name of the directory that you have used on your machine.
+
+
+$ SET DEFAULT DISK:[TIFF.CONTRIB.VMS]
+$ RENAME [.LIBTIFF]*.* [-.-.LIBTIFF]
+$ RENAME [.TOOLS]*.* [-.-.TOOLS]
+
+
+$ SET DEFAULT DISK:[TIFF.LIBTIFF]
+$ @MAKEVMS
+
+
+$ SET DEFAULT DISK:[TIFF.TOOLS]
+$ @MAKEVMS
+
+
+$ DEFINE TIFFSHR DISK:[TIFF.LIBTIFF]TIFFSHR
+$ FAX2PS :==$DISK:[TIFF.TOOLS]FAX2PS
+$ FAX2TIFF :==$DISK:[TIFF.TOOLS]FAX2TIFF
+$ GIF2TIFF :==$DISK:[TIFF.TOOLS]GIF2TIFF
+$ PAL2RGB :==$DISK:[TIFF.TOOLS]PAL2RGB
+$ PPM2TIFF :==$DISK:[TIFF.TOOLS]PPM2TIFF
+$ RAS2TIFF :==$DISK:[TIFF.TOOLS]RAS2TIFF
+$ RGB2YCBCR :==$DISK:[TIFF.TOOLS]RGB2YCBCR
+$ THUMBNAIL :==$DISK:[TIFF.TOOLS]THUMBNAIL
+$ TIFF2BW :==$DISK:[TIFF.TOOLS]TIFF2BW
+$ TIFF2PS :==$DISK:[TIFF.TOOLS]TIFF2PS
+$ TIFFCMP :==$DISK:[TIFF.TOOLS]TIFFCMP
+$ TIFFCP :==$DISK:[TIFF.TOOLS]TIFFCP
+$ TIFFDITHER:==$DISK:[TIFF.TOOLS]TIFFDITHER
+$ TIFFDUMP :==$DISK:[TIFF.TOOLS]TIFFDUMP
+$ TIFFINFO :==$DISK:[TIFF.TOOLS]TIFFINFO
+$ TIFFMEDIAN:==$DISK:[TIFF.TOOLS]TIFFMEDIAN
+$ TIFFSPLIT :==$DISK:[TIFF.TOOLS]TIFFSPLIT
+$ YCBCR :==$DISK:[TIFF.TOOLS]YCBCR
+
+Compiling your own program on a VMS system:
+
+When compiling a source file in which you
+"#include
+ $ CC/INCLUDE=DISK:[TIFF.LIBTIFF]
+
+This ensures that the header file is found.
+On the AXP, also add /FLOAT=IEEE_FLOAT
+(if used when building the library).
+
+
+Linking your own program to the TIFF library on a VMS system:
+
+You can link to the library in two ways: Either using the shareable
+library, or using the object library.
+On the VAX these possibilities are:
+
+
+
+
+On AXP (and possibly also using DEC C on VAX) the corresponding commands are
+
+$ LINK MY_PROGRAM,DISK:[TIFF.LIBTIFF]TIFF/OPTIONS,SYS$INPUT:/OPTIONS
+ SYS$SHARE:VAXCRTL/SHAREABLE
+
+
+$ LINK MY_PROGRAM, -
+ DISK:[TIFF.LIBTIFF]TIFF/LIBRARY/INCLUDE=(TIF_FAX3SM,TIF_CODEC), -
+ SYS$INPUT:/OPTIONS
+ SYS$SHARE:VAXCRTL/SHAREABLE
+
+
+
+
+Method 1 uses the shortest link time and smallest .EXE
+files, but it
+requires that TIFFSHR is defined as above at link time and
+at run time.
+Using the compilation procedure above, the tools are linked in this way.
+
+
+$ LINK MY_PROGRAM,DISK:[TIFF.LIBTIFF]TIFF/OPTIONS
+
+
+$ LINK MY_PROGRAM,DISK:[TIFF.LIBTIFF]TIFF/LIBRARY
+
+Building the Software on an Acorn RISC OS system
+
+The directory contrib/acorn contains support for compiling the library
+under Acorn C/C++ under Acorn's RISC OS 3.10 or above. Subsequent pathnames
+will use the Acorn format: The full-stop or period character is a pathname
+delimeter, and the slash character is not interpreted; the reverse position
+from Unix. Thus "libtiff/tif_acorn.c" becomes "libtiff.tif_acorn/c".
+
+Installing LibTIFF:
+
+Compiling LibTIFF:
+
+
+# Static dependencies:
+@.o.tif_acorn: @.c.tif_acorn
+ cc $(ccflags) -o @.o.tif_acorn @.c.tif_acorn
+
+
+ cc $(ccflags) -DINCLUDE_OSLIB -o @.o.tif_acorn @.c.tif_acorn
+
+Building the Software on Other Systems
+
+This section contains information that might be useful
+if you are working on a non-UNIX system that is not directly supported.
+All library-related files described below are located in the libtiff
+directory.
+
+
+cd libtiff
+cc -o mkg3states mkg3states.c
+rm -f tif_fax3sm.c
+./mkg3states -c const tif_fax3sm.c
+
+
+The -c option can be used to control whether or not the
+resutling tables are generated with a const declaration.
+The -s option can be used to specify a C storage class
+for the table declarations.
+The -b option can be used to force data values to be
+explicitly bracketed with ``{}'' (apparently needed for some
+MS-Windows compilers); otherwise the structures are emitted in
+as compact a format as possible.
+Consult the source code for this program if you have questions.
+
+
+cd libtiff
+cc -o mkversion mkversion.c
+rm -f version.h
+./mkversion -v ../VERSION -a ../dist/tiff.alpha version.h
+
+
+Checking out the Software
+
+
+tiffcp -lzw cramps.tif x.tif
+tiffcmp cramps.tif x.tif
+
+
+Table of Contents
+
+The following files makup the core library:
+
+
+libtiff/tiff.h TIFF spec definitions
+libtiff/tiffcomp.h non-UNIX OS-compatibility definitions
+libtiff/tiffconf.h non-UNIX configuration definitions
+libtiff/tiffio.h public TIFF library definitions
+libtiff/tiffiop.h private TIFF library definitions
+libtiff/t4.h CCITT Group 3/4 code tables+definitions
+libtiff/tif_dir.h private defs for TIFF directory handling
+libtiff/tif_fax3.h CCITT Group 3/4-related definitions
+libtiff/tif_predict.h private defs for Predictor tag support
+libtiff/uvcode.h LogL/LogLuv codec-specific definitions
+libtiff/version.h version string (generated by Makefile)
+
+libtiff/tif_acorn.c Acorn-related OS support
+libtiff/tif_apple.c Apple-related OS support
+libtiff/tif_atari.c Atari-related OS support
+libtiff/tif_aux.c auxilary directory-related functions
+libtiff/tif_close.c close an open TIFF file
+libtiff/tif_codec.c configuration table of builtin codecs
+libtiff/tif_compress.c compression scheme support
+libtiff/tif_dir.c directory tag interface code
+libtiff/tif_dirinfo.c directory known tag support code
+libtiff/tif_dirread.c directory reading code
+libtiff/tif_dirwrite.c directory writing code
+libtiff/tif_dumpmode.c "no" compression codec
+libtiff/tif_error.c library error handler
+libtiff/tif_fax3.c CCITT Group 3 and 4 codec
+libtiff/tif_fax3sm.c G3/G4 state tables (generated by mkg3states)
+libtiff/tif_flush.c i/o and directory state flushing
+libtiff/tif_getimage.c TIFFRGBAImage support
+libtiff/tif_jpeg.c JPEG codec (interface to the IJG distribution)
+libtiff/tif_luv.c SGI LogL/LogLuv codec
+libtiff/tif_lzw.c LZW codec
+libtiff/tif_msdos.c MSDOS-related OS support
+libtiff/tif_next.c NeXT 2-bit scheme codec (decoding only)
+libtiff/tif_open.c open and simply query code
+libtiff/tif_packbits.c Packbits codec
+libtiff/tif_pixarlog.c Pixar codec
+libtiff/tif_predict.c Predictor tag support
+libtiff/tif_print.c directory printing support
+libtiff/tif_read.c image data reading support
+libtiff/tif_strip.c some strip-related code
+libtiff/tif_swab.c byte and bit swapping support
+libtiff/tif_thunder.c Thunderscan codec (decoding only)
+libtiff/tif_tile.c some tile-related code
+libtiff/tif_unix.c UNIX-related OS support
+libtiff/tif_version.c library version support
+libtiff/tif_vms.c VMS-related OS support
+libtiff/tif_warning.c library warning handler
+libtiff/tif_win3.c Windows-3.1-related OS support
+libtiff/tif_win32.c Win32 (95/98/NT) related OS support
+libtiff/tif_write.c image data writing support
+libtiff/tif_zip.c Deflate codec
+
+libtiff/mkg3states.c program to generate G3/G4 decoder state tables
+libtiff/mkspans.c program to generate black-white span tables
+libtiff/mkversion.c program to generate libtiff/version.h.
+
+
+
+
+Last updated: $Date: 2000/06/24 19:10:16 $
+
+
+
diff --git a/html/contrib.html b/html/contrib.html
new file mode 100755
index 0000000..070cb8b
--- /dev/null
+++ b/html/contrib.html
@@ -0,0 +1,158 @@
+
+
+
+
+
+
+
+Contributed TIFF Software
+
+
+
+
+
+
+
+
+
+
+contrib/vms
+
+
+scripts and files from Karsten Spang for building
+ the library and tools under VMS
+
+
+
+
+
+contrib/dbs
+
+
+various tools from Dan & Chris Sears, including a simple X-based viewer
+
+
+
+
+
+contrib/ras
+
+
+two programs by Patrick Naughton for converting
+ between Sun rasterfile format and TIFF (these
+ require libpixrect.a, as opposed to the one in
+ tools that doesn't)
+
+
+
+
+
+contrib/mac-mpw
+
+
+scripts and files from Niles Ritter for building
+ the library and tools under Macintosh/MPW C.
+
+
+
+
+
+contrib/acorn
+
+
+scripts and files from Peter Greenham for building
+ the library and tools on an Acorn RISC OS system.
+
+
+
+
+
+contrib/win32
+
+
+scripts and files from Scott Wagner for building
+ the library under Windows NT and Windows 95.
+
+
+
+
+
+contrib/dosdjgpp
+
+
+scripts and files from Alexander Lehmann for building
+ the library under MSDOS with the DJGPP v2 compiler.
+
+
+
+
+
+contrib/tags
+
+
+scripts and files from Niles Ritter for adding private
+ tag support at runtime, without changing libtiff.
+
+
+
+
+
+contrib/mfs
+
+
+code from Mike Johnson to read+write images in memory
+without modifying the library
+
+
+
+
+
+contrib/pds
+
+
+various routines from Conrad Poelman; a TIFF image iterator and
+ code to support ``private sub-directories''
+
+
+
+
+
+contrib/iptcutil
+
+
+
+
+A utility by Bill Radcliffe to
+convert an extracted IPTC Newsphoto caption from a binary blob to
+ASCII text, and vice versa. IPTC binary blobs can be extracted from
+images via the ImageMagick convert(1)
+utility.
+
+
+
+
+
+Last updated: $Date: 2000/06/24 19:10:16 $
+
+
+
diff --git a/html/document.html b/html/document.html
new file mode 100755
index 0000000..a232a47
--- /dev/null
+++ b/html/document.html
@@ -0,0 +1,50 @@
+
+
+
+
+
+
+TIFF Documentation
+
+
+
+
+
+Last updated: $Date: 2000/06/24 19:10:16 $
+
+
+
+
diff --git a/html/images.html b/html/images.html
new file mode 100755
index 0000000..93998a4
--- /dev/null
+++ b/html/images.html
@@ -0,0 +1,40 @@
+
+
+
+
+
+
+TIFF Test Images
+
+
+
+
+Last updated: $Date: 2000/06/24 19:10:16 $
+
+
+
diff --git a/html/images/back.gif b/html/images/back.gif
new file mode 100755
index 0000000..11d0c35
Binary files /dev/null and b/html/images/back.gif differ
diff --git a/html/images/bali.jpg b/html/images/bali.jpg
new file mode 100755
index 0000000..1f5c146
Binary files /dev/null and b/html/images/bali.jpg differ
diff --git a/html/images/cat.gif b/html/images/cat.gif
new file mode 100755
index 0000000..5bd3fac
Binary files /dev/null and b/html/images/cat.gif differ
diff --git a/html/images/cover.jpg b/html/images/cover.jpg
new file mode 100755
index 0000000..8698cfb
Binary files /dev/null and b/html/images/cover.jpg differ
diff --git a/html/images/cramps.gif b/html/images/cramps.gif
new file mode 100755
index 0000000..9153f9a
Binary files /dev/null and b/html/images/cramps.gif differ
diff --git a/html/images/dave.gif b/html/images/dave.gif
new file mode 100755
index 0000000..c36d447
Binary files /dev/null and b/html/images/dave.gif differ
diff --git a/html/images/info.gif b/html/images/info.gif
new file mode 100755
index 0000000..783d631
Binary files /dev/null and b/html/images/info.gif differ
diff --git a/html/images/jello.jpg b/html/images/jello.jpg
new file mode 100755
index 0000000..df99e66
Binary files /dev/null and b/html/images/jello.jpg differ
diff --git a/html/images/jim.gif b/html/images/jim.gif
new file mode 100755
index 0000000..9a18a03
Binary files /dev/null and b/html/images/jim.gif differ
diff --git a/html/images/note.gif b/html/images/note.gif
new file mode 100755
index 0000000..7177d68
Binary files /dev/null and b/html/images/note.gif differ
diff --git a/html/images/oxford.gif b/html/images/oxford.gif
new file mode 100755
index 0000000..dd4b86e
Binary files /dev/null and b/html/images/oxford.gif differ
diff --git a/html/images/quad.jpg b/html/images/quad.jpg
new file mode 100755
index 0000000..4b7df17
Binary files /dev/null and b/html/images/quad.jpg differ
diff --git a/html/images/ring.gif b/html/images/ring.gif
new file mode 100755
index 0000000..2a614f4
Binary files /dev/null and b/html/images/ring.gif differ
diff --git a/html/images/smallliz.jpg b/html/images/smallliz.jpg
new file mode 100755
index 0000000..8eb827f
Binary files /dev/null and b/html/images/smallliz.jpg differ
diff --git a/html/images/strike.gif b/html/images/strike.gif
new file mode 100755
index 0000000..0709d19
Binary files /dev/null and b/html/images/strike.gif differ
diff --git a/html/images/warning.gif b/html/images/warning.gif
new file mode 100755
index 0000000..f51eb4b
Binary files /dev/null and b/html/images/warning.gif differ
diff --git a/html/index.html b/html/index.html
new file mode 100755
index 0000000..23fe3bd
--- /dev/null
+++ b/html/index.html
@@ -0,0 +1,97 @@
+
+
+
+
+TIFF Software
+
+Home Page:
+ http://www.libtiff.org
+
+FAQ Page: forthcoming
+Latest Release: v3.5.5
+Latest Software: v3.5.5
+Master FTP Site: ftp.onshore.com , directory pub/libtiff (Active mode FTP only!)
+HTTP Download: http://www.libtiff.org/tiff-v3.5.5.tar.gz, http://www.libtiff.org/tiff-v3.5.5.zip
+LZW Compression Kit: libtiff-lzw-compression-kit
+Mailing List: tiff@olympiakos.com
+Mailing List Subscription: tiff-request@olympiakos.com ("subscribe tiff" in body of message).
+Mailing List Archive: http://www.remotesensing.org/lists/libtiff_archive/maillist.html
+Anonymous CVS:
+ export CVSROOT=:pserver:anonymous@remotesensing.org:/cvsroot
+ cvs login # use password "anonymous"
+ cvs checkout libtiff
+ cvs checkout libtiff-lzw-compression-kit
+
+
+
+
+
+
+
+
+$Id: index.html,v 1.1.1.1 2000/06/24 19:10:16 tshead Exp $
+
+
+
+
+
+
+
+
+
+
diff --git a/html/internals.html b/html/internals.html
new file mode 100755
index 0000000..39af89a
--- /dev/null
+++ b/html/internals.html
@@ -0,0 +1,654 @@
+
+
+
+
+
+
+
+Modifying The TIFF Library
+
+
+
+
+Library Configuration
+
+Information on compiling the library is given
+elsewhere in this documentation.
+This section describes the low-level mechanisms used to control
+the optional parts of the library that are configured at build
+time. Control is based on
+a collection of C defines that are specified either on the compiler
+command line or in a configuration file such as port.h
+(as generated by the configure script for UNIX systems)
+or tiffconf.h.
+
+
+
+
+
+
+
+To override this behaviour define COMPRESSION_SUPPORT
+and then one or more additional defines to enable configuration of
+the appropriate codecs (see the table below); e.g.
+
+
+#define COMPRESSION_SUPPORT
+#define CCITT_SUPPORT
+#define PACKBITS_SUPPORT
+
+
+Several other compression schemes are configured separately from
+the default set because they depend on ancillary software
+packages that are not distributed with libtiff.
+
+
+Enabling JPEG support automatically enables support for
+the TIFF 6.0 colorimetry and YCbCr-related tags.
+
+
+The deflate algorithm is experimental. Do not expect
+to exchange files using this compression scheme;
+it is included only because the similar, and more common,
+LZW algorithm is claimed to be governed by licensing restrictions.
+
+
+
+
+
+
+
+
+
+Define Description
+
+
+CCITT_SUPPORT
+CCITT Group 3 and 4 algorithms (compression codes 2, 3, 4,
+ and 32771)
+
+
+
+PACKBITS_SUPPORT
+Macintosh PackBits algorithm (compression 32773)
+
+
+
+LZW_SUPPORT
+Lempel-Ziv & Welch (LZW) algorithm (compression 5)
+
+
+
+THUNDER_SUPPORT
+4-bit
+run-length encoding scheme from ThunderScan (compression 32809)
+
+
+
+NEXT_SUPPORT
+2-bit encoding scheme used by NeXT (compression 32766)
+
+
+
+OJPEG_SUPPORT
+obsolete JPEG scheme defined in the 6.0 spec (compression 6)
+
+
+
+JPEG_SUPPORT
+current JPEG scheme defined in TTN2 (compression 7)
+
+
+
+ZIP_SUPPORT
+experimental Deflate scheme (compression 32946)
+
+
+
+PIXARLOG_SUPPORT
+Pixar's compression scheme for high-resolution color images (compression 32909)
+
+
+
+SGILOG_SUPPORT
+SGI's compression scheme for high-resolution color images (compression 34676 and 34677)
+
+
+
+COLORIMETRY_SUPPORT
+support for the TIFF 6.0 colorimetry tags
+
+
+
+YCBCR_SUPPORT
+support for the TIFF 6.0 YCbCr-related tags
+
+
+
+CMYK_SUPPORT
+support for the TIFF 6.0 CMYK-related tags
+
+
+
+ICC_SUPPORT
+support for the ICC Profile tag; see
+The ICC Profile Format Specification,
+Annex B.3 "Embedding ICC Profiles in TIFF Files";
+available at
+http://www.color.org
+
+General Portability Comments
+
+This software is developed on Silicon Graphics UNIX
+systems (big-endian, MIPS CPU, 32-bit ints,
+IEEE floating point).
+The configure shell script generates the appropriate
+include files and make files for UNIX systems.
+Makefiles exist for non-UNIX platforms that the
+code runs on -- this work has mostly been done by other people.
+
+
+
+
+
+
+
+
+BSDTYPES
+Define this if your system does NOT define the
+ usual BSD typedefs: u_char,
+ u_short, u_int, u_long.
+
+
+
+HAVE_IEEEFP
+Define this as 0 or 1 according to the floating point
+ format suported by the machine. If your machine does
+ not support IEEE floating point then you will need to
+ add support to tif_machdep.c to convert between the
+ native format and IEEE format.
+
+
+
+HAVE_MMAP
+Define this if there is mmap-style support for
+mapping files into memory (used only to read data).
+
+
+
+HOST_FILLORDER
+Define the native CPU bit order: one of FILLORDER_MSB2LSB
+ or FILLORDER_LSB2MSB
+
+
+HOST_BIGENDIAN
+Define the native CPU byte order: 1 if big-endian (Motorola)
+ or 0 if little-endian (Intel); this may be used
+ in codecs to optimize code
+Types and Portability
+
+The software makes extensive use of C typedefs to promote portability.
+Two sets of typedefs are used, one for communication with clients
+of the library and one for internal data structures and parsing of the
+TIFF format. There are interactions between these two to be careful
+of, but for the most part you should be able to deal with portability
+purely by fiddling with the following machine-dependent typedefs:
+
+
+
+
+
+
+
+
+
+uint8
+8-bit unsigned integer
+tiff.h
+
+
+
+int8
+8-bit signed integer
+tiff.h
+
+
+
+uint16
+16-bit unsigned integer
+tiff.h
+
+
+
+int16
+16-bit signed integer
+tiff.h
+
+
+
+uint32
+32-bit unsigned integer
+tiff.h
+
+
+
+int32
+32-bit signed integer
+tiff.h
+
+
+
+dblparam_t
+promoted type for floats
+tiffcomp.h
+
+
+
+
+
+
+
+typedef unsigned int ttag_t; directory tag
+
+
+
+typedef uint16 tdir_t; directory index
+
+
+
+typedef uint16 tsample_t; sample number
+
+
+
+typedef uint32 tstrip_t; strip number
+
+
+
+typedef uint32 ttile_t; tile number
+
+
+
+typedef int32 tsize_t; i/o size in bytes
+
+
+
+typedef void* tdata_t; image data ref
+
+
+
+typedef void* thandle_t; client data handle
+
+
+
+typedef int32 toff_t; file offset (should be off_t)
+
+
+
+typedef unsigned char* tidata_t; internal image data
+General Comments
+
+The library is designed to hide as much of the details of TIFF from
+applications as
+possible. In particular, TIFF directories are read in their entirety
+into an internal format. Only the tags known by the library are
+available to a user and certain tag data may be maintained that a user
+does not care about (e.g. transfer function tables).
+
+Adding New Tags
+
+To add support for a new directory tag you have three options. If your
+tag is specific to a compression algorithm, see below. If you have a lot
+of tags you may want to try using Niles Ritter's runtime tag-extension
+scheme in the "contrib/tags" directory, which makes the changes
+orthogonal to the main libtiff code. Otherwise use
+the following guidelines to add support to the ``core library''.
+
+
+
+
+Adding New Builtin Codecs
+
+To add builtin support for a new compression algorithm, you can either
+use the "tag-extension" trick to override the handling of the
+TIFF Compression tag (see Adding New Tags, above),
+or do the following to add support directly to the core library:
+
+
+
+
+
+TIFFInitfoo(tif, scheme)/* initialize scheme and setup entry points in tif */
+fooSetupDecode(tif) /* called once per IFD after tags has been frozen */
+fooPreDecode(tif, sample)/* called once per strip/tile, after data is read,
+ but before the first row is decoded */
+fooDecode*(tif, bp, cc, sample)/* decode cc bytes of data into the buffer */
+ fooDecodeRow(...) /* called to decode a single scanline */
+ fooDecodeStrip(...) /* called to decode an entire strip */
+ fooDecodeTile(...) /* called to decode an entire tile */
+fooSetupEncode(tif) /* called once per IFD after tags has been frozen */
+fooPreEncode(tif, sample)/* called once per strip/tile, before the first row in
+ a strip/tile is encoded */
+fooEncode*(tif, bp, cc, sample)/* encode cc bytes of user data (bp) */
+ fooEncodeRow(...) /* called to decode a single scanline */
+ fooEncodeStrip(...) /* called to decode an entire strip */
+ fooEncodeTile(...) /* called to decode an entire tile */
+fooPostEncode(tif) /* called once per strip/tile, just before data is written */
+fooSeek(tif, row) /* seek forwards row scanlines from the beginning
+ of a strip (row will always be >0 and <rows/strip */
+fooCleanup(tif) /* called when compression scheme is replaced by user */
+
+
+Adding New Codec-private Tags
+
+To add tags that are meaningful only when a particular compression
+algorithm is used follow these steps:
+
+
+
+
+Note that space has been allocated in the FIELD_* bit space for
+codec-private tags. Define your bits as FIELD_CODEC+<offset> to
+keep them away from the core tags. If you need more tags than there
+is room for, just increase FIELD_SETLONGS at the top of
+tiffiop.h.
+
+
+
+ sp->vgetparent = tif->tif_vgetfield;
+ tif->tif_vgetfield = fooVGetField; /* hook for codec tags */
+ sp->vsetparent = tif->tif_vsetfield;
+ tif->tif_vsetfield = fooVSetField; /* hook for codec tags */
+ tif->tif_printdir = fooPrintDir; /* hook for codec tags */
+
+ (Actually you may decide not to override the
+ tif_printdir method, but rather just specify it).
+
+ _TIFFMergeFieldInfo(tif, fooFieldInfo, N(fooFieldInfo));
+
+ (where N is a macro used liberaly throughout the distributed code).
+Other Comments
+
+The library handles most I/O buffering. There are two data buffers
+when decoding data: a raw data buffer that holds all the data in a
+strip, and a user-supplied scanline buffer that compression schemes
+place decoded data into. When encoding data the data in the
+user-supplied scanline buffer is encoded into the raw data buffer (from
+where it is written). Decoding routines should never have to explicitly
+read data -- a full strip/tile's worth of raw data is read and scanlines
+never cross strip boundaries. Encoding routines must be cognizant of
+the raw data buffer size and call TIFFFlushData1() when necessary.
+Note that any pending data is automatically flushed when a new strip/tile is
+started, so there's no need do that in the tif_postencode routine (if
+one exists). Bit order is automatically handled by the library when
+a raw strip or tile is filled. If the decoded samples are interpreted
+by the decoding routine before they are passed back to the user, then
+the decoding logic must handle byte-swapping by overriding the
+tif_postdecode
+routine (set it to TIFFNoPostDecode) and doing the required work
+internally. For an example of doing this look at the horizontal
+differencing code in the routines in tif_predict.c.
+
+
+
+Last updated: $Date: 2000/06/24 19:10:16 $
+
+
+
+
diff --git a/html/intro.html b/html/intro.html
new file mode 100755
index 0000000..baa17b1
--- /dev/null
+++ b/html/intro.html
@@ -0,0 +1,68 @@
+
+
+
+
+
+
+
+Introduction to the TIFF Documentation
+
+
+
+Last updated: $Date: 2000/06/24 19:10:16 $
+
+
+
diff --git a/html/libtiff.html b/html/libtiff.html
new file mode 100755
index 0000000..b5154f0
--- /dev/null
+++ b/html/libtiff.html
@@ -0,0 +1,728 @@
+
+
+
+
+
+
+Using The TIFF Library
+
+
+
+
+How to tell which version you have
+
+The software version can be found by looking at the file named
+VERSION
+that is located at the top of the source tree; the precise alpha number
+is given in the file dist/tiff.alpha.
+If you have need to refer to this
+specific software, you should identify it as:
+
+
+ TIFF <version> <alpha>
+
+
+where <version> is whatever you get from
+"cat VERSION" and <alpha> is
+what you get from "cat dist/tiff.alpha".
+
+Library Datatypes
+
+libtiff defines a portable programming interface through the
+use of a set of C type definitions.
+These definitions, defined in in the files tiff.h and
+tiffio.h,
+isolate the libtiff API from the characteristics
+of the underlying machine.
+To insure portable code and correct operation, applications that use
+libtiff should use the typedefs and follow the function
+prototypes for the library API.
+
+Memory Management
+
+libtiff uses a machine-specific set of routines for managing
+dynamically allocated memory.
+_TIFFmalloc, _TIFFrealloc, and _TIFFfree
+mimic the normal ANSI C routines.
+Any dynamically allocated memory that is to be passed into the library
+should be allocated using these interfaces in order to insure pointer
+compatibility on machines with a segmented architecture.
+(On 32-bit UNIX systems these routines just call the normal malloc,
+realloc, and free routines in the C library.)
+
+Error Handling
+
+libtiff handles most errors by returning an invalid/erroneous
+value when returning from a function call.
+Various diagnostic messages may also be generated by the library.
+All error messages are directed to a single global error handler
+routine that can be specified with a call to TIFFSetErrorHandler.
+Likewise warning messages are directed to a single handler routine
+that can be specified with a call to TIFFSetWarningHandler
+
+Basic File Handling
+
+The library is modeled after the normal UNIX stdio library.
+For example, to read from an existing TIFF image the
+file must first be opened:
+
+
+
+The handle returned by TIFFOpen is opaque, that is
+the application is not permitted to know about its contents.
+All subsequent library calls for this file must pass the handle
+as an argument.
+
+
+
+If the file already exists it is first truncated to zero length.
+
+
+Note that unlike the stdio library TIFF image files may not be
+opened for both reading and writing;
+there is no support for altering the contents of a TIFF file.
+
+
+TIFF Directories
+
+TIFF supports the storage of multiple images in a single file.
+Each image has an associated data structure termed a directory
+that houses all the information about the format and content of the
+image data.
+Images in a file are usually related but they do not need to be; it
+is perfectly alright to store a color image together with a black and
+white image.
+Note however that while images may be related their directories are
+not.
+That is, each directory stands on its own; their is no need to read
+an unrelated directory in order to properly interpret the contents
+of an image.
+
+
+
+TIFF Tags
+
+Image-related information such as the image width and height, number
+of samples, orientation, colorimetric information, etc.
+are stored in each image
+directory in fields or tags.
+Tags are identified by a number that is usually a value registered
+with the Aldus (now Adobe) Corporation.
+Beware however that some vendors write
+TIFF images with tags that are unregistered; in this case interpreting
+their contents is usually a waste of time.
+
+TIFF Compression Schemes
+
+libtiff includes support for a wide variety of
+data compression schemes.
+In normal operation a compression scheme is automatically used when
+the TIFF Compression tag is set, either by opening a file
+for reading, or by setting the tag when writing.
+
+Byte Order
+
+The TIFF specification says, and has always said, that
+a correct TIFF
+reader must handle images in big-endian and little-endian byte order.
+libtiff conforms in this respect.
+Consequently there is no means to force a specific
+byte order for the data written to a TIFF image file (data is
+written in the native order of the host CPU unless appending to
+an existing file, in which case it is written in the byte order
+specified in the file).
+
+
+Data Placement
+
+The TIFF specification requires that all information except an
+8-byte header can be placed anywhere in a file.
+In particular, it is perfectly legitimate for directory information
+to be written after the image data itself.
+Consequently TIFF is inherently not suitable for passing through a
+stream-oriented mechanism such as UNIX pipes.
+Software that require that data be organized in a file in a particular
+order (e.g. directory information before image data) does not
+correctly support TIFF.
+libtiff provides no mechanism for controlling the placement
+of data in a file; image data is typically written before directory
+information.
+
+TIFFRGBAImage Support
+
+libtiff provides a high-level interface for reading image
+data from a TIFF file. This interface handles the details of
+data organization and format for a wide variety of TIFF files;
+at least the large majority of those files that one would normally
+encounter. Image data is, by default, returned as ABGR
+pixels packed into 32-bit words (8 bits per sample). Rectangular
+rasters can be read or data can be intercepted at an intermediate
+level and packed into memory in a format more suitable to the
+application.
+The library handles all the details of the format of data stored on
+disk and, in most cases, if any colorspace conversions are required:
+bilevel to RGB, greyscale to RGB, CMYK to RGB, YCbCr to RGB, 16-bit
+samples to 8-bit samples, associated/unassociated alpha, etc.
+
+
+
+Note above that _TIFFmalloc is used to allocate memory for
+the raster passed to TIFFReadRGBAImage; this is important
+to insure the ``appropriate type of memory'' is passed on machines
+with segmented architectures.
+
+
+
+However this usage does not take advantage of the more fine-grained
+control that's possible. That is, by using this interface it is
+possible to:
+
+
+
+
+The first item means that, for example, image viewers that want to
+handle multiple files can cache decoding information in order to
+speedup the work required to display a TIFF image.
+
+Scanline-based Image I/O
+
+The simplest interface provided by libtiff is a
+scanline-oriented interface that can be used to read TIFF
+images that have their image data organized in strips
+(trying to use this interface to read data written in tiles
+will produce errors.)
+A scanline is a one pixel high row of image data whose width
+is the width of the image.
+Data is returned packed if the image data is stored with samples
+packed together, or as arrays of separate samples if the data
+is stored with samples separated.
+The major limitation of the scanline-oriented interface, other
+than the need to first identify an existing file as having a
+suitable organization, is that random access to individual
+scanlines can only be provided when data is not stored in a
+compressed format, or when the number of rows in a strip
+of image data is set to one (RowsPerStrip is one).
+
+
+
+TIFFScanlineSize returns the number of bytes in
+a decoded scanline, as returned by TIFFReadScanline.
+Note however that if the file had been create with samples
+written in separate planes, then the above code would only
+read data that contained the first sample of each pixel;
+to handle either case one might use the following instead:
+
+
+
+Beware however that if the following code were used instead to
+read data in the case PLANARCONFIG_SEPARATE,
+
+
+
+then problems would arise if RowsPerStrip was not one
+because the order in which scanlines are requested would require
+random access to data within strips (something that is not supported
+by the library when strips are compressed).
+
+Strip-oriented Image I/O
+
+The strip-oriented interfaces provided by the library provide
+access to entire strips of data. Unlike the scanline-oriented
+calls, data can be read or written compressed or uncompressed.
+Accessing data at a strip (or tile) level is often desirable
+because there are no complications with regard to random access
+to data within strips.
+
+
+
+Notice how a strip size of -1 is used; TIFFReadEncodedStrip
+will calculate the appropriate size in this case.
+
+
+
+As above the strips are read in the order in which they are
+physically stored in the file; this may be different from the
+logical ordering expected by an application.
+
+Tile-oriented Image I/O
+
+Tiles of data may be read and written in a manner similar to strips.
+With this interface, an image is
+broken up into a set of rectangular areas that may have dimensions
+less than the image width and height. All the tiles
+in an image have the same size, and the tile width and length must each
+be a multiple of 16 pixels. Tiles are ordered left-to-right and
+top-to-bottom in an image. As for scanlines, samples can be packed
+contiguously or separately. When separated, all the tiles for a sample
+are colocated in the file. That is, all the tiles for sample 0 appear
+before the tiles for sample 1, etc.
+
+
+
+(once again, we assume samples are packed contiguously.)
+
+
+
+
+
+Other Stuff
+
+
+
+Last updated: $Date: 2000/06/24 19:10:16 $
+
+
+
diff --git a/html/man/TIFFClose.3t.html b/html/man/TIFFClose.3t.html
new file mode 100755
index 0000000..5dfbe91
--- /dev/null
+++ b/html/man/TIFFClose.3t.html
@@ -0,0 +1,69 @@
+
+TIFFClose
+Section: Misc. Reference Manual Pages (3T)
Updated: May 2, 1990
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFClose - close a previously opened
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+void TIFFClose(TIFF* tif)
+
+
+DESCRIPTION
+
+TIFFClose
+
+closes a file that was previously opened with
+TIFFOpen(3T).
+
+Any buffered data are flushed to the file, including the contents of
+the current directory (if modified); and all resources
+are reclaimed.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+Likewise, warning messages are directed to the
+TIFFWarning(3T)
+
+routine.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:37 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFError.3t.html b/html/man/TIFFError.3t.html
new file mode 100755
index 0000000..9668fb6
--- /dev/null
+++ b/html/man/TIFFError.3t.html
@@ -0,0 +1,97 @@
+
+TIFFError
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFError, TIFFSetErrorHandler - library error handling interface
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+void TIFFError(const char* module, const char* fmt, ...)
+
+
+
+typedef void (*TIFFErrorHandler)(const char* module, const char* fmt, va_list ap);
+
+
+
+TIFFErrorHandler TIFFSetErrorHandler(TIFFErrorHandler handler);
+
+
+DESCRIPTION
+
+TIFFError
+
+invokes the library-wide error handling function
+to (normally) write an error message to the
+stderr.
+
+The
+fmt
+
+parameter is a
+printf(3S)
+
+format string, and any number arguments can be supplied.
+The
+module
+
+parameter, if non-zero, is printed before the message; it typically
+is used to identify the software module in which an error
+is detected.
+RETURN VALUES
+
+TIFFSetErrorHandler
+
+returns a reference to the previous error handling function.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFWarning(3T),
+
+printf(3S)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:37 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFFlush.3t.html b/html/man/TIFFFlush.3t.html
new file mode 100755
index 0000000..14e32e9
--- /dev/null
+++ b/html/man/TIFFFlush.3t.html
@@ -0,0 +1,93 @@
+
+TIFFFlush
+Section: Misc. Reference Manual Pages (3T)
Updated: December 16, 1991
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFFlush, TIFFFlushData - flush pending writes to an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFFlush(TIFF* tif)
+
+
+
+int TIFFFlushData(TIFF* tif)
+
+
+DESCRIPTION
+
+TIFFFlush
+
+causes any pending writes for the specified file (including writes
+for the current directory)
+to be done.
+In normal operation this call is never needed- the library
+automatically does any flushing required.
+RETURN VALUES
+
+0 is returned if an error is encountered, otherwise 1 is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFWriteEncodedStrip(3T),
+
+TIFFWriteEncodedTile(3T),
+
+TIFFWriteRawStrip(3T),
+
+TIFFWriteRawTile(3T),
+
+TIFFWriteScanline(3T),
+
+TIFFWriteTile(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:37 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFGetField.3t.html b/html/man/TIFFGetField.3t.html
new file mode 100755
index 0000000..d0f8fa3
--- /dev/null
+++ b/html/man/TIFFGetField.3t.html
@@ -0,0 +1,266 @@
+
+TIFFGetField
+Section: Misc. Reference Manual Pages (3T)
Updated: August 22, 1997
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFGetField, TIFFVGetField - get the value(s) of a tag in an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFGetField(TIFF* tif, ttag_t tag, ...)
+
+
+
+int TIFFVGetField(TIFF* tif, ttag_t tag, va_list ap)
+
+
+
+int TIFFVGetFieldDefaulted(TIFF* tif, ttag_t tag, va_list ap)
+
+
+DESCRIPTION
+
+TIFFGetField
+
+returns the value of a tag or pseudo-tag associated with the
+the current directory of the open
+TIFF
+file
+tif.
+
+(A
+pseudo-tag
+
+is a parameter that is used to control the operation of the
+TIFF
+library but whose value is not read or written to the underlying file.)
+The file must have been previously opened with
+TIFFOpen(3T).
+
+The tag is identified by
+tag,
+
+one of the values defined in the include file
+tiff.h
+
+(see also the table below).
+The type and number of values returned is dependent
+on the tag being requested.
+The programming interface uses a variable argument list
+as prescribed by the
+stdarg(3)
+
+interface.
+The returned values should only be interpreted if
+TIFFGetField
+
+returns 1.
+
+
+Tag Name Count Types Notes
+
+TIFFTAG_ARTIST 1 char**
+TIFFTAG_BADFAXLINES 1 uint32*
+TIFFTAG_BITSPERSAMPLE 1 uint16*
+TIFFTAG_CLEANFAXDATA 1 uint16*
+TIFFTAG_COLORMAP 3 uint16** 1<<BitsPerSample arrays
+TIFFTAG_COMPRESSION 1 uint16*
+TIFFTAG_CONSECUTIVEBADFAXLINES 1 uint32*
+TIFFTAG_DATATYPE 1 uint16*
+TIFFTAG_DATETIME 1 char**
+TIFFTAG_DOCUMENTNAME 1 char**
+TIFFTAG_DOTRANGE 2 uint16*
+TIFFTAG_EXTRASAMPLES 2 uint16*,uint16** count & types array
+TIFFTAG_FAXMODE 1 int* G3/G4 compression pseudo-tag
+TIFFTAG_FAXFILLFUNC 1 TIFFFaxFillFunc* G3/G4 compression pseudo-tag
+TIFFTAG_FILLORDER 1 uint16*
+TIFFTAG_GROUP3OPTIONS 1 uint32*
+TIFFTAG_GROUP4OPTIONS 1 uint32*
+TIFFTAG_HALFTONEHINTS 2 uint16*
+TIFFTAG_HOSTCOMPUTER 1 char**
+TIFFTAG_IMAGEDEPTH 1 uint32*
+TIFFTAG_IMAGEDESCRIPTION 1 char**
+TIFFTAG_IMAGELENGTH 1 uint32*
+TIFFTAG_IMAGEWIDTH 1 uint32*
+TIFFTAG_INKNAMES 1 char**
+TIFFTAG_INKSET 1 uint16*
+TIFFTAG_JPEGTABLES 2 u_short*,void** count & tables
+TIFFTAG_JPEGQUALITY 1 int* JPEG pseudo-tag
+TIFFTAG_JPEGCOLORMODE 1 int* JPEG pseudo-tag
+TIFFTAG_JPEGTABLESMODE 1 int* JPEG pseudo-tag
+TIFFTAG_MAKE 1 char**
+TIFFTAG_MATTEING 1 uint16*
+TIFFTAG_MAXSAMPLEVALUE 1 uint16*
+TIFFTAG_MINSAMPLEVALUE 1 uint16*
+TIFFTAG_MODEL 1 char**
+TIFFTAG_ORIENTATION 1 uint16*
+TIFFTAG_PAGENAME 1 char**
+TIFFTAG_PAGENUMBER 2 uint16*
+TIFFTAG_PHOTOMETRIC 1 uint16*
+TIFFTAG_PLANARCONFIG 1 uint16*
+TIFFTAG_PREDICTOR 1 uint16*
+TIFFTAG_PRIMARYCHROMATICITIES 1 float** 6-entry array
+TIFFTAG_REFERENCEBLACKWHITE 1 float** 2*SamplesPerPixel array
+TIFFTAG_RESOLUTIONUNIT 1 uint16*
+TIFFTAG_ROWSPERSTRIP 1 uint32*
+TIFFTAG_SAMPLEFORMAT 1 uint16*
+TIFFTAG_SAMPLESPERPIXEL 1 uint16*
+TIFFTAG_SMAXSAMPLEVALUE 1 double*
+TIFFTAG_SMINSAMPLEVALUE 1 double*
+TIFFTAG_SOFTWARE 1 char**
+TIFFTAG_STONITS 1 double**
+TIFFTAG_STRIPBYTECOUNTS 1 uint32**
+TIFFTAG_STRIPOFFSETS 1 uint32**
+TIFFTAG_SUBFILETYPE 1 uint32*
+TIFFTAG_SUBIFD 2 uint16*,uint32** count & offsets array
+TIFFTAG_TARGETPRINTER 1 char**
+TIFFTAG_THRESHHOLDING 1 uint16*
+TIFFTAG_TILEBYTECOUNTS 1 uint32**
+TIFFTAG_TILEDEPTH 1 uint32*
+TIFFTAG_TILELENGTH 1 uint32*
+TIFFTAG_TILEOFFSETS 1 uint32**
+TIFFTAG_TILEWIDTH 1 uint32*
+TIFFTAG_TRANSFERFUNCTION 1 or 3+ uint16**1<<BitsPerSample entry arrays
+TIFFTAG_WHITEPOINT 1 float** 2-entry array
+TIFFTAG_XPOSITION 1 float*
+TIFFTAG_XRESOLUTION 1 float*
+TIFFTAG_YCBCRCOEFFICIENTS 1 float** 3-entry array
+TIFFTAG_YCBCRPOSITIONING 1 uint16*
+TIFFTAG_YCBCRSUBSAMPLING 2 uint16*
+TIFFTAG_YPOSITION 1 float*
+TIFFTAG_YRESOLUTION 1 float*
+TIFFTAG_ICCPROFILE 2 uint32*,void** count, profile datadd
+
+
++ If
+SamplesPerPixel
+
+is one, then a single array is returned; otherwise three arrays are
+returned.
+
+dd The contents of this field are quite complex. See
+The ICC Profile Format Specification,
+
+Annex B.3 "Embedding ICC Profiles in TIFF Files"
+(available at http://www.color.org) for an explanation.
+
+RETURN VALUES
+
+1 is returned if the tag is defined in the current
+directory; otherwise a 0 is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFSetField(3T),
+
+TIFFSetDirectory(3T),
+
+TIFFReadDirectory(3T),
+
+TIFFWriteDirectory(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:37 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFOpen.3t.html b/html/man/TIFFOpen.3t.html
new file mode 100755
index 0000000..6c94a15
--- /dev/null
+++ b/html/man/TIFFOpen.3t.html
@@ -0,0 +1,361 @@
+
+TIFFOpen
+Section: Misc. Reference Manual Pages (3T)
Updated: January 9, 1996
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFOpen, TIFFFdOpen, TIFFClientOpen - open a
+TIFF
+file for reading or writing
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+TIFF* TIFFOpen(const char* filename, const char* mode)
+
+TIFF* TIFFFdOpen(const int fd, const char* filename, const char* mode)
+
+typedef tsize_t (*TIFFReadWriteProc)(thandle_t, tdata_t, tsize_t);
+typedef toff_t (*TIFFSeekProc)(thandle_t, toff_t, int);
+typedef int (*TIFFCloseProc)(thandle_t);
+typedef toff_t (*TIFFSizeProc)(thandle_t);
+typedef int (*TIFFMapFileProc)(thandle_t, tdata_t*, toff_t*);
+typedef void (*TIFFUnmapFileProc)(thandle_t, tdata_t, toff_t);
+
+TIFF* TIFFClientOpen(const char* filename, const char* mode, thandle_t clientdata,
+ TIFFReadWriteProc readproc, TIFFReadWriteProc writeproc, TIFFSeekProc seekproc,
+ TIFFCloseProc closeproc, TIFFSizeProc sizeproc, TIFFMapFileProc mapproc,
+ TIFFUnmapFileProc unmapproc)
+
+
+
+DESCRIPTION
+
+TIFFOpen
+
+opens a
+TIFF
+file whose name is
+filename
+
+and returns a handle to be used in subsequent calls to routines in
+libtiff.
+
+If the open operation fails, then zero is returned.
+The
+mode
+
+parameter specifies if the file is to be opened for reading (``r''),
+writing (``w''), or appending (``a'') and, optionally, whether
+to override certain default aspects of library operation (see below).
+When a file is opened for appending, existing data will not
+be touched; instead new data will be written as additional subfiles.
+If an existing file is opened for writing, all previous data is
+overwritten.
+OPTIONS
+
+The open mode parameter can include the following flags in
+addition to the ``r'', ``w'', and ``a'' flags.
+Note however that option flags must follow the read-write-append
+specification.
+
+
+
+BYTE ORDER
+
+The
+TIFF
+specification (all versions) states that compliant readers
+must be capable of reading images written in either byte order.
+
+Nonetheless some software that claims to support the reading of
+TIFF
+images is incapable of reading images in anything but the native
+CPU
+byte order on which the software was written.
+(Especially notorious
+are applications written to run on Intel-based machines.)
+By default the library will create new files with the native
+byte-order of the
+CPU
+on which the application is run.
+This ensures optimal performance and is portable to any application
+that conforms to the TIFF specification.
+To force the library to use a specific byte-order when creating
+a new file the ``b'' and ``l'' option flags may be included in
+the call to open a file; for example, ``wb'' or ``wl''.
+
+RETURN VALUES
+
+Upon successful completion
+TIFFOpen,
+
+TIFFFdOpen,
+
+and
+TIFFClientOpen
+
+return a
+TIFF
+pointer.
+Otherwise, NULL is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+Likewise, warning messages are directed to the
+TIFFWarning(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFClose(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:37 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFPrintDirectory.3t.html b/html/man/TIFFPrintDirectory.3t.html
new file mode 100755
index 0000000..0bf764b
--- /dev/null
+++ b/html/man/TIFFPrintDirectory.3t.html
@@ -0,0 +1,100 @@
+
+TIFFPrintDirectory
+Section: Misc. Reference Manual Pages (3T)
Updated: December 12, 1991
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFPrintDirectory - print a description of a
+TIFF
+directory
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+void TIFFPrintDirectory(TIFF* tif, FILE* fd, long flags)
+
+
+DESCRIPTION
+
+TIFFPrintDirectory
+
+prints a description of the current directory in the specified
+TIFF
+file to the standard I/O output stream
+fd.
+
+The
+flags
+
+parameter is used to control the
+level of detail
+
+of the printed information; it is a bit-or of the flags
+defined in
+tiffio.h:
+
+
+
+#define TIFFPRINT_NONE 0x0 /* no extra info */
+#define TIFFPRINT_STRIPS 0x1 /* strips/tiles info */
+#define TIFFPRINT_CURVES 0x2 /* color/gray response curves */
+#define TIFFPRINT_COLORMAP 0x4 /* colormap */
+#define TIFFPRINT_JPEGQTABLES 0x100 /* JPEG Q matrices */
+#define TIFFPRINT_JPEGACTABLES 0x200 /* JPEG AC tables */
+#define TIFFPRINT_JPEGDCTABLES 0x200 /* JPEG DC tables */
+
+
+
+NOTES
+
+In C++ the
+flags
+
+parameter defaults to 0.
+
+RETURN VALUES
+
+None.
+
+DIAGNOSTICS
+
+None.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFReadDirectory(3T),
+
+TIFFSetDirectory(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:37 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFRGBAImage.3t.html b/html/man/TIFFRGBAImage.3t.html
new file mode 100755
index 0000000..bec5ef7
--- /dev/null
+++ b/html/man/TIFFRGBAImage.3t.html
@@ -0,0 +1,370 @@
+
+TIFFRGBAImage
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFRGBAImage - read and decode an image into a raster
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+typedef unsigned char TIFFRGBValue;
+typedef struct _TIFFRGBAImage TIFFRGBAImage;
+int TIFFRGBAImageOK(TIFF* tif, char emsg[1024]);
+int TIFFRGBAImageBegin(TIFFRGBAImage* img, TIFF* tif, int stopOnError, char emsg[1024]);
+int TIFFRGBAImageGet(TIFFRGBAImage* img, uint32* raster, uint32 width, uint32 height);
+void TIFFRGBAImageEnd(TIFFRGBAImage* img);
+
+DESCRIPTION
+
+The routines described here provide a high-level interface
+through which
+TIFF
+images may be read into memory.
+Images may be strip- or tile-based and have a variety of different
+characteristics: bits/sample, samples/pixel, photometric, etc.
+Decoding state is encapsulated in a
+TIFFRGBAImage
+
+structure making it possible to capture state for multiple images
+and quickly switch between them.
+The target raster format can be customized to a particular application's
+needs by installing custom routines that manipulate image data
+according to application requirements.
+ALTERNATE RASTER FORMATS
+
+To use the core support for reading and processing
+TIFF
+images, but write the resulting raster data in a different format
+one need only override the ``put methods'' used to store raster data.
+These methods are are defined in the
+TIFFRGBAImage
+
+structure and initially setup by
+TIFFRGBAImageBegin
+
+to point to routines that pack raster data in the default
+ABGR
+pixel format.
+Two different routines are used according to the physical organization
+of the image data in the file:
+PlanarConfiguration=1
+
+(packed samples),
+and
+PlanarConfiguration=2
+
+(separated samples).
+Note that this mechanism can be used to transform the data before
+storing it in the raster.
+For example one can convert data
+to colormap indices for display on a colormap display.
+
+SIMULTANEOUS RASTER STORE AND DISPLAY
+
+It is simple to display an image as it is being read into memory
+by overriding the put methods as described above for supporting
+alternate raster formats.
+Simply keep a reference to the default put methods setup by
+TIFFRGBAImageBegin
+
+and then invoke them before or after each display operation.
+For example, the
+tiffgt(1)
+
+utility uses the following put method to update the display as
+the raster is being filled:
+
+static void
+putContigAndDraw(TIFFRGBAImage* img, uint32* raster,
+ uint32 x, uint32 y, uint32 w, uint32 h,
+ int32 fromskew, int32 toskew,
+ unsigned char* cp)
+{
+ (*putContig)(img, raster, x, y, w, h, fromskew, toskew, cp);
+ if (x+w == width) {
+ w = width;
+ if (img->orientation == ORIENTATION_TOPLEFT)
+ lrectwrite(0, y-(h-1), w-1, y, raster-x-(h-1)*w);
+ else
+ lrectwrite(0, y, w-1, y+h-1, raster);
+ }
+}
+
+
+SUPPORTING ADDITIONAL TIFF FORMATS
+
+The
+TIFFRGBAImage
+
+routines support the most commonly encountered flavors of
+TIFF.
+It is possible to extend this support by overriding the ``get method''
+invoked by
+TIFFRGBAImageGet
+
+to read
+TIFF
+image data.
+Details of doing this are a bit involved, it is best to make a copy
+of an existing get method and modify it to suit the needs of an
+application.
+
+NOTES
+
+Samples must be either 1, 2, 4, 8, or 16 bits.
+Colorimetric samples/pixel must be either 1, 3, or 4 (i.e.
+SamplesPerPixel
+
+minus
+ExtraSamples).
+
+RETURN VALUES
+
+All routines return
+1 if the operation was successful.
+Otherwise, 0 is returned if an error was encountered and
+stopOnError
+
+is zero.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+BUGS
+
+Orientations other than bottom-left, or top-left are
+not handled correctly.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFReadRGBAImage(3T),
+
+TIFFReadRGBAStrip(3T),
+
+TIFFReadRGBATile(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadDirectory.3t.html b/html/man/TIFFReadDirectory.3t.html
new file mode 100755
index 0000000..6ee870b
--- /dev/null
+++ b/html/man/TIFFReadDirectory.3t.html
@@ -0,0 +1,212 @@
+
+TIFFReadDirectory
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadDirectory - get the contents of the next directory in an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFReadDirectory(TIFF* tif)
+
+
+DESCRIPTION
+
+Read the next directory in the specified file and make it the
+current directory.
+Applications only need to call
+TIFFReadDirectory
+
+to read multiple subfiles in a single
+TIFF
+file-
+the first directory in a file is automatically read when
+TIFFOpen
+
+is called.
+
+NOTES
+
+If the library is compiled with
+STRIPCHOP_SUPPORT
+enabled, then images that have a single uncompressed strip or
+tile of data are automatically treated as if they were made
+up of multiple strips or tiles of approximately 8 kilobytes each.
+This operation is done only in-memory; it does not alter the
+contents of the file.
+However, the construction of the ``chopped strips'' is visible
+to the application through the number of strips [tiles]
+returned by
+TIFFNumberOfStrips
+
+[TIFFNumberOfTiles].
+
+
+RETURN VALUES
+
+If the next directory was successfully read, 1 is returned.
+Otherwise, 0 is returned if an error was encountered,
+or if there are no more directories to be read.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+All warning messages are directed to the
+TIFFWarning(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFWriteDirectory(3T),
+
+TIFFSetDirectory(3T),
+
+TIFFSetSubDirectory(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadEncodedStrip.3t.html b/html/man/TIFFReadEncodedStrip.3t.html
new file mode 100755
index 0000000..1e3e8f9
--- /dev/null
+++ b/html/man/TIFFReadEncodedStrip.3t.html
@@ -0,0 +1,103 @@
+
+TIFFReadEncodedStrip
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadEncodedStrip - read and decode a strip of data from an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFReadEncodedStrip(TIFF* tif, tstrip_t strip, tdata_t buf, tsize_t size)
+
+
+DESCRIPTION
+
+Read the specified strip of data and place up to
+size
+
+bytes of decompressed information in the (user supplied) data buffer.
+
+NOTES
+
+The value of
+strip
+
+is a ``raw strip number.''
+That is, the caller must take into account whether or not the
+data are organized in separate planes (PlanarConfiguration=2).
+
+To read a full strip of data the data buffer should typically be
+at least as large as the number returned by
+TIFFStripSize(3T).
+
+RETURN VALUES
+
+The actual number of bytes of data that were placed in
+buf
+
+is returned;
+TIFFReadEncodedStrip
+
+returns -1 if an error was encountered.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFReadRawStrip(3T),
+
+TIFFReadScanline(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadEncodedTile.3t.html b/html/man/TIFFReadEncodedTile.3t.html
new file mode 100755
index 0000000..de57a77
--- /dev/null
+++ b/html/man/TIFFReadEncodedTile.3t.html
@@ -0,0 +1,107 @@
+
+TIFFReadEncodedTile
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadEncodedTile - read and decode a tile of data from an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFReadEncodedTile(TIFF* tif, u_long tile, u_char* buf, u_long size)
+
+
+DESCRIPTION
+
+Read the specified tile of data and place up to
+size
+
+bytes of decompressed information in the (user supplied) data buffer.
+
+NOTES
+
+The value of
+tile
+
+is a ``raw tile number.''
+That is, the caller must take into account whether or not the
+data are organized in separate planes (PlanarConfiguration=2).
+
+TIFFComputeTile
+
+automatically does this when converting an (x,y,z,sample)
+coordinate quadruple to a tile number.
+To read a full tile of data the data buffer should be
+at least as large as the value returned by
+TIFFTileSize.
+
+RETURN VALUES
+
+The actual number of bytes of data that were placed in
+buf
+
+is returned;
+TIFFReadEncodedTile
+
+returns -1 if an error was encountered.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFReadRawTile(3T),
+
+TIFFReadTile(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadRGBAImage.3t.html b/html/man/TIFFReadRGBAImage.3t.html
new file mode 100755
index 0000000..9d1440e
--- /dev/null
+++ b/html/man/TIFFReadRGBAImage.3t.html
@@ -0,0 +1,262 @@
+
+TIFFReadRGBAImage
+Section: Misc. Reference Manual Pages (3T)
Updated: February 14, 1992
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadRGBAImage - read and decode an image into a fixed-format raster
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+
+#define TIFFGetR(abgr) ((abgr) & 0xff)
+#define TIFFGetG(abgr) (((abgr) >> 8) & 0xff)
+#define TIFFGetB(abgr) (((abgr) >> 16) & 0xff)
+#define TIFFGetA(abgr) (((abgr) >> 24) & 0xff)
+
+int TIFFReadRGBAImage(TIFF* tif, u_long width, u_long height, u_long* raster, int stopOnError)
+
+DESCRIPTION
+
+TIFFReadRGBAImage
+
+reads a strip- or tile-based image into memory, storing the
+result in the user supplied
+raster.
+
+The raster is assumed to be an array of
+width
+
+times
+height
+
+32-bit entries, where
+width
+
+must be less than or equal to the width of the image (height
+
+may be any non-zero size).
+If the raster dimensions are smaller than the image, the image data
+is cropped to the raster bounds.
+If the raster height is greater than that of the image, then the
+image data are placed in the lower part of the raster.
+(Note that the raster is assume to be organized such that the pixel
+at location (x,y) is raster[y*width+x];
+with the raster origin in the lower-left hand corner.)
+NOTES
+
+In C++ the
+stopOnError
+
+parameter defaults to 0.
+RETURN VALUES
+
+1 is returned if the image was successfully read and converted.
+Otherwise, 0 is returned if an error was encountered and
+stopOnError
+
+is zero.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+BUGS
+
+Orientations other than bottom-left, or top-left are
+not handled correctly.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFRGBAImage(3T),
+
+TIFFReadRGBAStrip(3T),
+
+TIFFReadRGBATile(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadRGBAStrip.3t.html b/html/man/TIFFReadRGBAStrip.3t.html
new file mode 100755
index 0000000..713a6b2
--- /dev/null
+++ b/html/man/TIFFReadRGBAStrip.3t.html
@@ -0,0 +1,249 @@
+
+TIFFReadRGBAStrip
+Section: Misc. Reference Manual Pages (3T)
Updated: December 10, 1998
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadRGBAStrip - read and decode an image strip into a fixed-format raster
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+
+#define TIFFGetR(abgr) ((abgr) & 0xff)
+#define TIFFGetG(abgr) (((abgr) >> 8) & 0xff)
+#define TIFFGetB(abgr) (((abgr) >> 16) & 0xff)
+#define TIFFGetA(abgr) (((abgr) >> 24) & 0xff)
+
+int TIFFReadRGBAStrip(TIFF* tif, tstrip_t strip, uint32 * raster )
+
+DESCRIPTION
+
+TIFFReadRGBAStrip
+
+reads a single strip of a strip-based image into memory,
+storing the result in the user supplied RGBA
+raster.
+
+The raster is assumed to be an array of
+width times rowsperstrip 32-bit entries, where width
+is the width of the image (TIFFTAG_IMAGEWIDTH) and
+rowsperstrip is the maximum lines in a strip (TIFFTAG_ROWSPERSTRIP).
+NOTES
+
+Samples must be either 1, 2, 4, 8, or 16 bits.
+Colorimetric samples/pixel must be either 1, 3, or 4 (i.e.
+SamplesPerPixel
+
+minus
+ExtraSamples).
+
+RETURN VALUES
+
+1 is returned if the image was successfully read and converted.
+Otherwise, 0 is returned if an error was encountered.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+BUGS
+
+Orientations other than bottom-left, or top-left are
+not handled correctly.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFRGBAImage(3T),
+
+TIFFReadRGBAImage(3T),
+
+TIFFReadRGBATile(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadRGBATile.3t.html b/html/man/TIFFReadRGBATile.3t.html
new file mode 100755
index 0000000..ef5eebe
--- /dev/null
+++ b/html/man/TIFFReadRGBATile.3t.html
@@ -0,0 +1,251 @@
+
+TIFFReadRGBATile
+Section: Misc. Reference Manual Pages (3T)
Updated: December 10, 1998
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadRGBATile - read and decode an image tile into a fixed-format raster
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+
+#define TIFFGetR(abgr) ((abgr) & 0xff)
+#define TIFFGetG(abgr) (((abgr) >> 8) & 0xff)
+#define TIFFGetB(abgr) (((abgr) >> 16) & 0xff)
+#define TIFFGetA(abgr) (((abgr) >> 24) & 0xff)
+
+int TIFFReadRGBATile(TIFF* tif, uint32 x, uint32 y, uint32 * raster )
+
+DESCRIPTION
+
+TIFFReadRGBATile
+
+reads a single tile of a tile-based image into memory,
+storing the result in the user supplied RGBA
+raster.
+
+The raster is assumed to be an array of
+width times length 32-bit entries, where width
+is the width of a tile (TIFFTAG_TILEWIDTH) and
+length is the height of a tile (TIFFTAG_TILELENGTH).
+NOTES
+
+Samples must be either 1, 2, 4, 8, or 16 bits.
+Colorimetric samples/pixel must be either 1, 3, or 4 (i.e.
+SamplesPerPixel
+
+minus
+ExtraSamples).
+
+RETURN VALUES
+
+1 is returned if the image was successfully read and converted.
+Otherwise, 0 is returned if an error was encountered.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+BUGS
+
+Orientations other than bottom-left, or top-left are
+not handled correctly.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFRGBAImage(3T),
+
+TIFFReadRGBAImage(3T),
+
+TIFFReadRGBAStrip(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadRawStrip.3t.html b/html/man/TIFFReadRawStrip.3t.html
new file mode 100755
index 0000000..f34c90f
--- /dev/null
+++ b/html/man/TIFFReadRawStrip.3t.html
@@ -0,0 +1,88 @@
+
+TIFFReadRawStrip
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadRawStrip - return the undecoded contents
+of a strip of data from an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFReadRawStrip(TIFF* tif, tstrip_t strip, tdata_t buf, tsize_t size)
+
+
+DESCRIPTION
+
+Read the contents of the specified strip into the
+(user supplied) data buffer.
+Note that the value of
+strip
+
+is a ``raw strip number.''
+That is, the caller must take into account whether or not the
+data is organized in separate planes (PlanarConfiguration=2).
+
+To read a full strip of data the data buffer should typically be
+at least as large as the number returned by
+TIFFStripSize.
+
+
+RETURN VALUES
+
+The actual number of bytes of data that were placed in
+buf
+
+is returned;
+TIFFReadEncodedStrip
+
+returns -1 if an error was encountered.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFReadEncodedStrip(3T),
+
+TIFFReadScanline(3T),
+
+TIFFStripSize(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadRawTile.3t.html b/html/man/TIFFReadRawTile.3t.html
new file mode 100755
index 0000000..d4fc935
--- /dev/null
+++ b/html/man/TIFFReadRawTile.3t.html
@@ -0,0 +1,91 @@
+
+TIFFReadRawTile
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadRawTile - return an undecoded tile of data from an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFReadRawTile(TIFF* tif, ttile_t tile, tdata_t buf, tsize_t size)
+
+
+DESCRIPTION
+
+Read the contents of the specified tile into the
+(user supplied) data buffer.
+Note that the value of
+tile
+
+is a ``raw tile number.''
+That is, the caller must take into account whether or not the
+data is organized in separate planes (PlanarConfiguration=2).
+
+TIFFComputeTile
+
+automatically does this when converting an (x,y,z,sample)
+coordinate quadruple to a tile number.
+To read a full tile of data the data buffer should typically be
+at least as large as the value returned by
+TIFFTileSize.
+
+
+RETURN VALUES
+
+The actual number of bytes of data that were placed in
+buf
+
+is returned;
+TIFFReadEncodedTile
+
+returns -1 if an error was encountered.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFReadEncodedTile(3T),
+
+TIFFReadTile(3T),
+
+TIFFTileSize(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadScanline.3t.html b/html/man/TIFFReadScanline.3t.html
new file mode 100755
index 0000000..e99b4bf
--- /dev/null
+++ b/html/man/TIFFReadScanline.3t.html
@@ -0,0 +1,139 @@
+
+TIFFReadScanline
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadScanline - read and decode a scanline of data from an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFReadScanline(TIFF* tif, tdata_t buf, uint32 row, tsample_t sample)
+
+
+DESCRIPTION
+
+Read the data for the specified row into the (user supplied)
+data buffer
+buf.
+
+The data are returned decompressed and, in the native byte-
+and bit-ordering, but are otherwise packed (see further below).
+The buffer must be large enough to hold an entire scanline of data.
+Applications should call the routine
+TIFFScanlineSize
+
+to find out the size (in bytes) of a scanline buffer.
+The
+row
+
+parameter is always used by
+TIFFReadScanline;
+
+the
+sample
+
+parameter is used only if data are organized in separate planes (PlanarConfiguration=2).
+
+
+NOTES
+
+The library attempts to hide bit- and byte-ordering differences
+between the image and the native machine by converting data
+to the native machine order.
+Bit reversal is done if the
+FillOrder
+
+tag is opposite to the native machine bit order.
+16- and 32-bit samples are automatically byte-swapped if the
+file was written with a byte order opposite to the native
+machine byte order,
+RETURN VALUES
+
+TIFFReadScanline
+
+returns -1 if it detects an error; otherwise 1 is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+BUGS
+
+Reading subsampled YCbCR data does not work correctly
+because, for
+PlanarConfiguration=2
+
+the size of a scanline is not calculated on a per-sample basis,
+and for
+PlanarConfiguration=1
+
+the library does not unpack the block-interleaved samples; use
+the strip- and tile-based interfaces to read these formats.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFReadEncodedStrip(3T),
+
+TIFFReadRawStrip(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFReadTile.3t.html b/html/man/TIFFReadTile.3t.html
new file mode 100755
index 0000000..12eddab
--- /dev/null
+++ b/html/man/TIFFReadTile.3t.html
@@ -0,0 +1,120 @@
+
+TIFFReadTile
+Section: Misc. Reference Manual Pages (3T)
Updated: December 16, 1991
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadTile - read and decode a tile of data from an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFReadTile(TIFF* tif, tdata_t buf, uint32 x, uint32 y, uint32 z, tsample_t sample)
+
+
+DESCRIPTION
+
+Return the data for the tile
+containing
+
+the specified coordinates.
+The data placed in
+buf
+
+are returned decompressed and, typically, in the native byte-
+and bit-ordering, but are otherwise packed (see further below).
+The buffer must be large enough to hold an entire tile of data.
+Applications should call the routine
+TIFFTileSize
+
+to find out the size (in bytes) of a tile buffer.
+The
+x
+
+and
+y
+
+parameters are always used by
+TIFFReadTile.
+
+The
+z
+
+parameter is used if the image is deeper than 1 slice (ImageDepth>1).
+
+The
+sample
+
+parameter is used only if data are organized in separate planes (PlanarConfiguration=2).
+
+
+NOTES
+
+The library attempts to hide bit- and byte-ordering differences
+between the image and the native machine by converting data
+to the native machine order.
+Bit reversal is done if the
+FillOrder
+
+tag is opposite to the native machine bit order.
+16- and 32-bit samples are automatically byte-swapped if the
+file was written with a byte order opposite to the native
+machine byte order,
+
+RETURN VALUES
+
+TIFFReadTile
+
+returns -1 if it detects an error; otherwise the number of
+bytes in the decoded tile is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFCheckTile(3T),
+
+TIFFComputeTile(3T),
+
+TIFFOpen(3T),
+
+TIFFReadEncodedTile(3T),
+
+TIFFReadRawTile(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFSetDirectory.3t.html b/html/man/TIFFSetDirectory.3t.html
new file mode 100755
index 0000000..3f5732d
--- /dev/null
+++ b/html/man/TIFFSetDirectory.3t.html
@@ -0,0 +1,114 @@
+
+TIFFSetDirectory
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFSetDirectory, TIFFSetSubDirectory - set the current directory for an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFSetDirectory(TIFF* tif, tdir_t dirnum)
+
+
+
+int TIFFSetSubDirectory(TIFF* tif, uint32 diroff)
+
+
+DESCRIPTION
+
+TIFFSetDirectory
+
+changes the current directory and reads its contents with
+TIFFReadDirectory.
+
+The parameter
+dirnum
+
+specifies the subfile/directory as an integer number, with
+the first directory numbered zero.
+RETURN VALUES
+
+On successful return 1 is returned.
+Otherwise, 0 is returned if
+dirnum
+
+or
+diroff
+
+specifies a non-existent directory, or if an error was
+encountered while reading the directory's contents.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFCurrentDirectory(3T),
+
+TIFFOpen(3T),
+
+TIFFReadDirectory(3T),
+
+TIFFWriteDirectory(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFSetField.3t.html b/html/man/TIFFSetField.3t.html
new file mode 100755
index 0000000..aae8ec9
--- /dev/null
+++ b/html/man/TIFFSetField.3t.html
@@ -0,0 +1,269 @@
+
+TIFFSetField
+Section: Misc. Reference Manual Pages (3T)
Updated: August 28, 1997
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFSetField - set the value(s) of a tag in a
+TIFF
+file open for writing
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFSetField(TIFF* tif, ttag_t tag, ...)
+
+
+
+#include <stdarg.h>
+
+
+
+int TIFFVSetField(TIFF* tif, ttag_t tag, va_list ap)
+
+
+DESCRIPTION
+
+TIFFSetField
+
+sets the value of a field
+or pseudo-tag in the current directory associated with
+the open
+TIFF
+file
+tif.
+
+(A
+pseudo-tag
+
+is a parameter that is used to control the operation of the
+TIFF
+library but whose value is not read or written to the underlying file.)
+To set the value of a field
+the file must have been previously opened for writing with
+TIFFOpen(3T);
+
+pseudo-tags can be set whether the file was opened for reading
+or writing.
+The field is identified by
+tag,
+
+one of the values defined in the include file
+tiff.h
+
+(see also the table below).
+The actual value is specified using a variable argument list,
+as prescribed by the
+stdarg(3)
+
+interface (or, on some machines, the
+varargs(3)
+
+interface.)
+
+
+Tag Name Count Types Notes
+
+TIFFTAG_ARTIST 1 char*
+TIFFTAG_BADFAXLINES 1 uint32
+TIFFTAG_BITSPERSAMPLE 1 uint16 +
+TIFFTAG_CLEANFAXDATA 1 uint16
+TIFFTAG_COLORMAP 3 uint16* 1<<BitsPerSample arrays
+TIFFTAG_COMPRESSION 1 uint16 +
+TIFFTAG_CONSECUTIVEBADFAXLINES 1 uint32
+TIFFTAG_DATETIME 1 char*
+TIFFTAG_DOCUMENTNAME 1 char*
+TIFFTAG_DOTRANGE 2 uint16
+TIFFTAG_EXTRASAMPLES 2 uint16,uint16* + count & types array
+TIFFTAG_FAXMODE 1 int + G3/G4 compression pseudo-tag
+TIFFTAG_FAXFILLFUNC 1 TIFFFaxFillFunc G3/G4 compression pseudo-tag
+TIFFTAG_FILLORDER 1 uint16 +
+TIFFTAG_GROUP3OPTIONS 1 uint32 +
+TIFFTAG_GROUP4OPTIONS 1 uint32 +
+TIFFTAG_HALFTONEHINTS 2 uint16
+TIFFTAG_HOSTCOMPUTER 1 char*
+TIFFTAG_IMAGEDESCRIPTION 1 char*
+TIFFTAG_IMAGEDEPTH 1 uint32 +
+TIFFTAG_IMAGELENGTH 1 uint32
+TIFFTAG_IMAGEWIDTH 1 uint32 +
+TIFFTAG_INKNAMES 1 char*
+TIFFTAG_INKSET 1 uint16 +
+TIFFTAG_JPEGTABLES 2 uint32*,void* + count & tables
+TIFFTAG_JPEGQUALITY 1 int JPEG pseudo-tag
+TIFFTAG_JPEGCOLORMODE 1 int + JPEG pseudo-tag
+TIFFTAG_JPEGTABLESMODE 1 int + JPEG pseudo-tag
+TIFFTAG_MAKE 1 char*
+TIFFTAG_MATTEING 1 uint16 +
+TIFFTAG_MAXSAMPLEVALUE 1 uint16
+TIFFTAG_MINSAMPLEVALUE 1 uint16
+TIFFTAG_MODEL 1 char*
+TIFFTAG_ORIENTATION 1 uint16
+TIFFTAG_PAGENAME 1 char*
+TIFFTAG_PAGENUMBER 2 uint16
+TIFFTAG_PHOTOMETRIC 1 uint16
+TIFFTAG_PLANARCONFIG 1 uint16 +
+TIFFTAG_PREDICTOR 1 uint16 +
+TIFFTAG_PRIMARYCHROMATICITIES 1 float* 6-entry array
+TIFFTAG_REFERENCEBLACKWHITE 1 float* + 2*SamplesPerPixel array
+TIFFTAG_RESOLUTIONUNIT 1 uint16
+TIFFTAG_ROWSPERSTRIP 1 uint32 + must be > 0
+TIFFTAG_SAMPLEFORMAT 1 uint16 +
+TIFFTAG_SAMPLESPERPIXEL 1 uint16 + value must be <= 4
+TIFFTAG_SMAXSAMPLEVALUE 1 double
+TIFFTAG_SMINSAMPLEVALUE 1 double
+TIFFTAG_SOFTWARE 1 char*
+TIFFTAG_STONITS 1 double +
+TIFFTAG_SUBFILETYPE 1 uint32
+TIFFTAG_SUBIFD 2 uint16,uint32* count & offsets array
+TIFFTAG_TARGETPRINTER 1 char*
+TIFFTAG_THRESHHOLDING 1 uint16
+TIFFTAG_TILEDEPTH 1 uint32 +
+TIFFTAG_TILELENGTH 1 uint32 + must be a multiple of 8
+TIFFTAG_TILEWIDTH 1 uint32 + must be a multiple of 8
+TIFFTAG_TRANSFERFUNCTION 1 or 3 dd uint16*1<<BitsPerSample entry arrays
+TIFFTAG_XPOSITION 1 float
+TIFFTAG_XRESOLUTION 1 float
+TIFFTAG_WHITEPOINT 1 float* 2-entry array
+TIFFTAG_YCBCRCOEFFICIENTS 1 float* + 3-entry array
+TIFFTAG_YCBCRPOSITIONING 1 uint16 +
+TIFFTAG_YCBCRSAMPLING 2 uint16 +
+TIFFTAG_YPOSITION 1 float
+TIFFTAG_YRESOLUTION 1 float
+TIFFTAG_ICCPROFILE 2 uint32,void* count, profile data*
+
+
+
+
+
+dd
+If
+SamplesPerPixel
+
+is one, then a single array is passed; otherwise three arrays should be
+passed.
+
+* The contents of this field are quite complex. See
+The ICC Profile Format Specification,
+
+Annex B.3 "Embedding ICC Profiles in TIFF Files"
+(available at http://www.color.org) for an explanation.
+
+
+
+RETURN VALUES
+
+1 is returned if the tag is defined in the current
+directory; otherwise a 0 is returned.
+
+RETURN VALUES
+
+1 is returned if the operation was successful.
+Otherwise, 0 is returned if an error was detected.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFGetField(3T),
+
+TIFFSetDirectory(3T),
+
+TIFFWriteDirectory(3T),
+
+TIFFReadDirectory(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFWarning.3t.html b/html/man/TIFFWarning.3t.html
new file mode 100755
index 0000000..f7fbbca
--- /dev/null
+++ b/html/man/TIFFWarning.3t.html
@@ -0,0 +1,98 @@
+
+TIFFWarning
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFWarning, TIFFSetWarningHandler - library warning interface
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+void TIFFWarning(const char* module, const char* fmt, ...)
+
+
+
+typedef void (*TIFFWarningHandler)(const char* module, const char* fmt, va_list ap);
+
+
+
+TIFFWarningHandler TIFFSetWarningHandler(TIFFWarningHandler handler);
+
+
+DESCRIPTION
+
+TIFFWarning
+
+invokes the library-wide warning handler function
+to (normally) write a warning message to the
+stderr.
+
+The
+fmt
+
+parameter is a
+printf(3S)
+
+format string, and any number arguments can be supplied.
+The
+module
+
+parameter is interpreted as a string that, if non-zero,
+should be printed before the message; it typically
+is used to identify the software module in which a warning
+is detected.
+RETURN VALUES
+
+TIFFSetWarningHandler
+
+returns a reference to the previous error handling function.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFError(3T),
+
+printf(3S)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFWriteDirectory.3t.html b/html/man/TIFFWriteDirectory.3t.html
new file mode 100755
index 0000000..86e6ffa
--- /dev/null
+++ b/html/man/TIFFWriteDirectory.3t.html
@@ -0,0 +1,148 @@
+
+TIFFWriteDirectory
+Section: Misc. Reference Manual Pages (3T)
Updated: December 16, 1991
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFWriteDirectory - write the current directory in an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFWriteDirectory(TIFF* tif)
+
+
+DESCRIPTION
+
+Write the contents of the current directory to the file and setup
+to create a new subfile in the same file.
+Applications only need to call
+TIFFWriteDirectory
+
+when writing multiple subfiles to a single
+TIFF
+file.
+TIFFWriteDirectory
+
+is automatically called by
+TIFFClose
+
+and
+TIFFFlush
+
+to write a modified directory if the file is open for writing.
+
+RETURN VALUES
+
+1 is returned when the contents are successfully
+written to the file.
+Otherwise, 0 is returned if an error was encountered when writing
+the directory contents.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFError(3T),
+
+TIFFReadDirectory(3T),
+
+TIFFSetDirectory(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFWriteEncodedStrip.3t.html b/html/man/TIFFWriteEncodedStrip.3t.html
new file mode 100755
index 0000000..d56a668
--- /dev/null
+++ b/html/man/TIFFWriteEncodedStrip.3t.html
@@ -0,0 +1,147 @@
+
+TIFFWriteEncodedStrip
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFWritedEncodedStrip - compress and write a strip of data to an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFWriteEncodedStrip(TIFF* tif, tstrip_t strip, tdata_t buf, tsize_t size)
+
+
+DESCRIPTION
+
+Compress
+size
+
+bytes of raw data from
+buf
+
+and write the result to the specified strip; replacing
+any previously written data.
+Note that the value of
+strip
+
+is a ``raw strip number.''
+That is, the caller must take into account whether or not the
+data are organized in separate places (PlanarConfiguration=2).
+
+
+NOTES
+
+The library writes encoded data using the native machine byte order.
+Correctly implemented
+TIFF
+readers are expected to do any necessary byte-swapping to
+correctly process image data with BitsPerSample greater than 8.
+RETURN VALUES
+
+-1 is returned if an error was encountered.
+Otherwise, the value of
+size
+
+is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFWriteScanline(3T),
+
+TIFFWriteRawStrip(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFWriteEncodedTile.3t.html b/html/man/TIFFWriteEncodedTile.3t.html
new file mode 100755
index 0000000..556b55e
--- /dev/null
+++ b/html/man/TIFFWriteEncodedTile.3t.html
@@ -0,0 +1,137 @@
+
+TIFFWriteEncodedTile
+Section: Misc. Reference Manual Pages (3T)
Updated: December 16, 1991
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFWritedEncodedTile - compress and write a tile of data to an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFWriteEncodedTile(TIFF* tif, ttile_t tile, tdata_t buf, tsize_t size)
+
+
+DESCRIPTION
+
+Compress
+size
+
+bytes of raw data from
+buf
+
+and
+append
+
+the result to the end of the specified tile.
+Note that the value of
+tile
+
+is a ``raw tile number.''
+That is, the caller must take into account whether or not the
+data are organized in separate places (PlanarConfiguration=2).
+
+TIFFComputeTile
+
+automatically does this when converting an (x,y,z,sample)
+coordinate quadruple to a tile number.
+
+NOTES
+
+The library writes encoded data using the native machine byte order.
+Correctly implemented
+TIFF
+readers are expected to do any necessary byte-swapping to
+correctly process image data with BitsPerSample greater than 8.
+
+RETURN VALUES
+
+-1 is returned if an error was encountered.
+Otherwise, the value of
+size
+
+is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFWriteTile(3T),
+
+TIFFWriteRawTile(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFWriteRawStrip.3t.html b/html/man/TIFFWriteRawStrip.3t.html
new file mode 100755
index 0000000..a5dbf8a
--- /dev/null
+++ b/html/man/TIFFWriteRawStrip.3t.html
@@ -0,0 +1,134 @@
+
+TIFFWriteRawstrip
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFWriteRawStrip - write a strip of raw data to an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFWriteRawStrip(TIFF* tif, tstrip_t strip, tdata_t buf, tsize_t size)
+
+
+DESCRIPTION
+
+Append
+size
+
+bytes of raw data to the specified strip.
+
+NOTES
+
+The strip number must be valid according to the current settings
+of the
+ImageLength
+
+and
+RowsPerStrip
+
+tags.
+An image may be dynamically grown by increasing the value of
+ImageLength
+
+prior to each call to
+TIFFWriteRawStrip.
+
+
+RETURN VALUES
+
+-1 is returned if an error occurred.
+Otherwise, the value of
+size
+
+is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFWriteEncodedStrip(3T),
+
+TIFFWriteScanline(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFWriteRawTile.3t.html b/html/man/TIFFWriteRawTile.3t.html
new file mode 100755
index 0000000..09d9101
--- /dev/null
+++ b/html/man/TIFFWriteRawTile.3t.html
@@ -0,0 +1,116 @@
+
+TIFFWriteRawtile
+Section: Misc. Reference Manual Pages (3T)
Updated: December 16, 1991
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFWriteRawTile - write a tile of raw data to an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFWriteRawTile(TIFF* tif, ttile_t tile, tdata_t buf, tsize_t size)
+
+
+DESCRIPTION
+
+Append
+size
+
+bytes of raw data to the specified tile.
+
+RETURN VALUES
+
+-1 is returned if an error occurred.
+Otherwise, the value of
+size
+
+is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFWriteEncodedTile(3T),
+
+TIFFWriteScanline(3T)
+
+
+
+ Index
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:38 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFWriteScanline.3t.html b/html/man/TIFFWriteScanline.3t.html
new file mode 100755
index 0000000..75f5c78
--- /dev/null
+++ b/html/man/TIFFWriteScanline.3t.html
@@ -0,0 +1,225 @@
+
+TIFFWriteScanline
+Section: Misc. Reference Manual Pages (3T)
Updated: December 16, 1991
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFWriteScanline - write a scanline to an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+int TIFFWriteScanline(TIFF* tif, tdata_t buf, uint32 row, tsample_t sample)
+
+
+DESCRIPTION
+
+Write data to a file at the specified row.
+The
+sample
+
+parameter is used only if data are organized in separate planes (PlanarConfiguration=2).
+
+The data are assumed to be uncompressed and in the native
+bit- and byte-order of the host machine.
+The data written to the file is
+compressed according to the compression scheme
+of the current
+TIFF
+directory (see further below).
+If the current scanline is past the end of the current subfile, the
+ImageLength
+
+field is automatically increased to include the scanline (except
+for
+PlanarConfiguration=2,
+
+where the
+ImageLength
+
+cannot be changed once the first data are written).
+If the
+ImageLength
+
+is increased, the
+StripOffsets
+
+and
+StripByteCounts
+
+fields are similarly enlarged to reflect data written past the
+previous end of image.
+
+NOTES
+
+The library writes encoded data using the native machine byte order.
+Correctly implemented
+TIFF
+readers are expected to do any necessary byte-swapping to
+correctly process image data with BitsPerSample greater than 8.
+The library attempts to hide bit-ordering differences
+between the image and the native machine by converting data
+from the native machine order.
+RETURN VALUES
+
+TIFFWriteScanline
+
+returns -1 if it immediately detects an error
+and 1 for a successful write.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+BUGS
+
+Writing subsampled YCbCR data does not work correctly
+because, for
+PlanarConfiguration=2
+
+the size of a scanline is not calculated on a per-sample basis,
+and for
+PlanarConfiguration=1
+
+the library does not pack the block-interleaved samples.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFWriteEncodedStrip(3T),
+
+TIFFWriteRawStrip(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:39 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFWriteTile.3t.html b/html/man/TIFFWriteTile.3t.html
new file mode 100755
index 0000000..b8d676c
--- /dev/null
+++ b/html/man/TIFFWriteTile.3t.html
@@ -0,0 +1,109 @@
+Content-type: text/html
+
+
+TIFFWriteTile
+Section: Misc. Reference Manual Pages (3T)
Updated: November 29, 1999
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFWriteTile - encode and write a tile of data to an open
+TIFF
+file
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+tsize_t TIFFWriteTile(TIFF* tif, tdata_t buf, uint32 x, uint32 y, uint32 z, tsample_t sample)
+
+
+DESCRIPTION
+
+Write the data for the tile
+containing
+
+the specified coordinates.
+The data in
+buf
+
+are is (potentially) compressed, and written to the indicated file, normally
+being appended to the end of the file.
+The buffer must be contain an entire tile of data.
+Applications should call the routine
+TIFFTileSize
+
+to find out the size (in bytes) of a tile buffer.
+The
+x
+
+and
+y
+
+parameters are always used by
+TIFFWriteTile.
+
+The
+z
+
+parameter is used if the image is deeper than 1 slice (ImageDepth>1).
+
+The
+sample
+
+parameter is used only if data are organized in separate planes (PlanarConfiguration=2).
+
+
+RETURN VALUES
+
+TIFFWriteTile
+
+returns -1 if it detects an error; otherwise the number of
+bytes in the tile is returned.
+
+DIAGNOSTICS
+
+All error messages are directed to the
+TIFFError(3T)
+
+routine.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFCheckTile(3T),
+
+TIFFComputeTile(3T),
+
+TIFFOpen(3T),
+
+TIFFReadTile(3T),
+
+TIFFWriteScanline(3T),
+
+TIFFWriteEncodedTile(3T),
+
+TIFFWriteRawTile(3T)
+
+
+
+ Index
+
+
+Time: 18:38:00 GMT, November 30, 1999
+
+
diff --git a/html/man/TIFFbuffer.3t.html b/html/man/TIFFbuffer.3t.html
new file mode 100755
index 0000000..00fdb2e
--- /dev/null
+++ b/html/man/TIFFbuffer.3t.html
@@ -0,0 +1,101 @@
+
+TIFFBUFFER
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReadBufferSetup,
+TIFFWriteBufferSetup
+- I/O buffering control routines
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+int TIFFReadBufferSetup(TIFF*, tdata_t buffer, tsize_t size);
+int TIFFWriteBufferSetup(TIFF*, tdata_t buffer, tsize_t size);
+
+
+
+DESCRIPTION
+
+The following routines are provided for client-control of the
+I/O buffers used by the library.
+Applications need never use these routines; they are provided only
+for ``intelligent clients'' that wish to optimize memory usage and/or
+eliminate potential copy operations that can occur when working with
+images that have data stored without compression.
+DIAGNOSTICS
+
+%s: No space for data buffer at scanline %ld.
+
+TIFFReadBufferSetup
+
+was unable to dynamically allocate space for a data buffer.
+SEE ALSO
+
+libtiff(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:39 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFcodec.3t.html b/html/man/TIFFcodec.3t.html
new file mode 100755
index 0000000..cda02c8
--- /dev/null
+++ b/html/man/TIFFcodec.3t.html
@@ -0,0 +1,102 @@
+
+CODEC
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFFindCODEC, TIFFRegisterCODEC, TIFFUnRegisterCODEC - codec-related utility routines
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+const TIFFCodec* TIFFFindCODEC(uint16 scheme);
+
+
+
+TIFFCodec* TIFFRegisterCODEC(uint16 scheme, const char* method, TIFFInitMethod init);
+
+
+
+void TIFFUnRegisterCODEC(TIFFCodec* codec);
+
+
+DESCRIPTION
+
+libtiff
+
+supports a variety of compression schemes implemented by software
+codecs.
+
+Each codec adheres to a modular interface that provides for
+the decoding and encoding of image data; as well as some other
+methods for initialization, setup, cleanup, and the control
+of default strip and tile sizes.
+Codecs are identified by the associated value of the
+TIFF
+Compression
+
+tag; e.g. 5 for
+LZW
+compression.
+DIAGNOSTICS
+
+No space to register compression scheme %s.
+
+TIFFRegisterCODEC
+
+was unable to allocate memory for the data structures needed
+to register a codec.
+SEE ALSO
+
+libtiff(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:39 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFmemory.3t.html b/html/man/TIFFmemory.3t.html
new file mode 100755
index 0000000..bf92beb
--- /dev/null
+++ b/html/man/TIFFmemory.3t.html
@@ -0,0 +1,104 @@
+
+MEMORY
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+_TIFFmalloc, _TIFFrealloc, _TIFFfree, _TIFFmemset, _TIFFmemcpy, _TIFFmemcmp, - memory management-related functions for use with
+TIFF
+files
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+tdata_t _TIFFmalloc(tsize_t);
+tdata_t _TIFFrealloc(tdata_t, tsize_t);
+void _TIFFfree(tdata_t);
+void _TIFFmemset(tdata_t, int, tsize_t);
+void _TIFFmemcpy(tdata_t, const tdata_t, tsize_t);
+int _TIFFmemcmp(const tdata_t, const tdata_t, tsize_t);
+
+
+
+DESCRIPTION
+
+These routines are provided for writing portable software that uses
+libtiff;
+
+they hide any memory-management related issues, such as dealing with
+segmented architectures found on 16-bit machines.
+DIAGNOSTICS
+
+None.
+
+SEE ALSO
+
+libtiff(3T),
+
+malloc(3C),
+
+memory(3C)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:39 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFquery.3t.html b/html/man/TIFFquery.3t.html
new file mode 100755
index 0000000..5a364d9
--- /dev/null
+++ b/html/man/TIFFquery.3t.html
@@ -0,0 +1,178 @@
+
+QUERY
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFCurrentRow,
+TIFFCurrentStrip,
+TIFFCurrentTile,
+TIFFCurrentDirectory,
+TIFFLastDirectory,
+TIFFFileno,
+TIFFFileName,
+TIFFGetMode,
+TIFFIsTiled,
+TIFFIsByteSwapped,
+TIFFIsUpSampled,
+TIFFIsMSB2LSB
+- query routines
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+uint32 TIFFCurrentRow(TIFF* tif)
+tstrip_t TIFFCurrentStrip(TIFF* tif)
+ttile_t TIFFCurrentTile(TIFF* tif)
+tdir_t TIFFCurrentDirectory(TIFF* tif)
+int TIFFLastDirectory(TIFF* tif)
+int TIFFFileno(TIFF* tif)
+char* TIFFFileName(TIFF* tif)
+int TIFFGetMode(TIFF* tif)
+int TIFFIsTiled(TIFF* tif)
+int TIFFIsByteSwapped(TIFF* tif)
+int TIFFIsUpSampled(TIFF* tif)
+int TIFFIsMSB2LSB(TIFF* tif)
+const char* TIFFGetVersion(void)
+
+
+
+DESCRIPTION
+
+The following routines return status information about an open
+TIFF
+file.
+DIAGNOSTICS
+
+None.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFFdOpen(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:39 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFsize.3t.html b/html/man/TIFFsize.3t.html
new file mode 100755
index 0000000..d88d332
--- /dev/null
+++ b/html/man/TIFFsize.3t.html
@@ -0,0 +1,75 @@
+
+TIFFSIZE
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFScanlineSize,
+TIFFRasterScanlineSize,
+- return the size of various items associated with an open
+TIFF
+file
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+tsize_t TIFFRasterScanlineSize(TIFF* tif)
+tsize_t TIFFScanlineSize(TIFF* tif)
+
+DESCRIPTION
+
+TIFFScanlineSize
+
+returns the size in bytes of a row of data as it would be
+returned in a call to
+TIFFReadScanline,
+
+or as it would be expected in a call to
+TIFFWriteScanline.
+
+DIAGNOSTICS
+
+None.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFOpen(3T),
+
+TIFFReadScanline(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:39 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFstrip.3t.html b/html/man/TIFFstrip.3t.html
new file mode 100755
index 0000000..788c54f
--- /dev/null
+++ b/html/man/TIFFstrip.3t.html
@@ -0,0 +1,131 @@
+
+TIFFSTRIP
+Section: Misc. Reference Manual Pages (3T)
Updated: October 15, 1995
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFDefaultStripSize,
+TIFFStripSize,
+TIFFVStripSize,
+TIFFComputeStrip,
+TIFFNumberOfStrips
+- strip-related utility routines
+
+SYNOPSIS
+
+
+#include <tiffio.h>
+uint32 TIFFDefaultStripSize(TIFF* tif, uint32 estimate)
+tsize_t TIFFStripSize(TIFF* tif)
+tsize_t TIFFVStripSize(TIFF* tif, uint32 nrows)
+tstrip_t TIFFComputeStrip(TIFF* tif, uint32 row, tsample_t sample)
+tstrip_t TIFFNumberOfStrips(TIFF* tif)
+
+
+
+DESCRIPTION
+
+TIFFDefaultStripSize
+
+returns the number of rows for a reasonable-sized strip according
+to the current settings of the
+ImageWidth,
+
+BitsPerSample,
+
+SamplesPerPixel,
+
+tags and any compression-specific requirements.
+If the
+estimate
+
+parameter, if non-zero, then it is taken as an estimate of the desired
+strip size and adjusted according to any compression-specific requirements.
+The value returned by this function is typically used to define the
+RowsPerStrip
+
+tag.
+In lieu of any unusual requirements
+TIFFDefaultStripSize
+
+tries to create strips that have approximately
+8 kilobytes of uncompressed data.
+DIAGNOSTICS
+
+None.
+
+SEE ALSO
+
+libtiff(3T),
+
+TIFFReadEncodedStrip(3T),
+
+TIFFReadRawStrip(3T),
+
+TIFFWriteEncodedStrip(3T),
+
+TIFFWriteRawStrip(3T)
+
+
+
+ Index
+
+
+
+This document was created by
+man2html,
+using the manual pages.
+Time: 01:31:39 GMT, November 23, 1999
+
+
diff --git a/html/man/TIFFswab.3t.html b/html/man/TIFFswab.3t.html
new file mode 100755
index 0000000..268b0ce
--- /dev/null
+++ b/html/man/TIFFswab.3t.html
@@ -0,0 +1,108 @@
+
+SWAB
+Section: Misc. Reference Manual Pages (3T)
Updated: December 16, 1991
Index
+
Return to Main Contents
+
+
+
+NAME
+
+TIFFReverseBits, TIFFSwabShort, TIFFSwabLong, TIFFSwabArrayOfShort, TIFFSwabArrayOfLong - byte- and bit-swapping routines
+
+SYNOPSIS
+
+#include <tiffio.h>
+
+
+
+const unsigned char* TIFFGetBitRevTable(int reversed);
+
+
+
+void TIFFReverseBits(u_char* data, unsigned long nbytes)
+
+
+
+void TIFFSwabShort(uint16* data)
+
+
+
+void TIFFSwabLong(uint32* data)
+
+
+
+void TIFFSwabArrayOfShort(uint16* data, unsigned long nshorts)
+
+
+
+void TIFFSwabArrayOfLong(uint32* data, unsigned long nlongs)
+
+
+DESCRIPTION
+
+The following routines are used by the library to swap
+16- and 32-bit data and to reverse the order of bits in bytes.
+DIAGNOSTICS
+
+None.
+
+SEE ALSO
+
+libtiff(3T),
+
+
+
+ Index
+
+