summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Leffler <sam@engr.sgi.com>1996-01-10 20:37:08 +0000
committerRoger Leigh <rleigh@codelibre.net>2022-06-22 18:36:16 +0100
commit98ce01d4275de67a73e57548172d9a35caa84b92 (patch)
tree4a3ec4b42339f9451974c58af8797f9af8905500
parent74a4ba75cb606153ec47c90b3bb625cf025821ae (diff)
downloadlibtiff-git-98ce01d4275de67a73e57548172d9a35caa84b92.tar.gz
v3.4beta028 releasev3.4beta028
-rw-r--r--COPYRIGHT4
-rw-r--r--Makefile.in10
-rw-r--r--README6
-rwxr-xr-xconfig.guess2
-rw-r--r--config.site6
-rwxr-xr-xconfigure53
-rw-r--r--contrib/win95/Makefile.w95134
-rw-r--r--contrib/win95/README50
-rw-r--r--contrib/win95/tiff2dib.c372
-rw-r--r--contrib/winnt/README26
-rw-r--r--contrib/winnt/fax3sm.c1046
-rw-r--r--contrib/winnt/libtiff.def72
-rw-r--r--contrib/winnt/libtiff.mak1947
-rw-r--r--contrib/winnt/libtiff.vcpbin0 -> 17408 bytes
-rw-r--r--contrib/winnt/version.h1
-rw-r--r--dist/newversion6
-rw-r--r--dist/tiff.alpha2
-rw-r--r--dist/tiff.spec6
-rw-r--r--html/Makefile.in6
-rw-r--r--html/index.html4
-rwxr-xr-xlibtiff/Makefile.acorn112
-rw-r--r--libtiff/Makefile.in10
-rw-r--r--libtiff/Makefile.lcc6
-rw-r--r--libtiff/Makefile.msc6
-rw-r--r--libtiff/mkg3states.c6
-rw-r--r--libtiff/mkspans.c6
-rwxr-xr-xlibtiff/mkversion.c10
-rw-r--r--libtiff/t4.h6
-rwxr-xr-xlibtiff/tif_acorn.c519
-rw-r--r--libtiff/tif_apple.c6
-rw-r--r--libtiff/tif_atari.c6
-rw-r--r--libtiff/tif_aux.c6
-rw-r--r--libtiff/tif_close.c6
-rw-r--r--libtiff/tif_codec.c20
-rw-r--r--libtiff/tif_compress.c44
-rw-r--r--libtiff/tif_dir.c58
-rw-r--r--libtiff/tif_dir.h17
-rw-r--r--libtiff/tif_dirinfo.c6
-rw-r--r--libtiff/tif_dirread.c9
-rw-r--r--libtiff/tif_dirwrite.c8
-rw-r--r--libtiff/tif_dumpmode.c6
-rw-r--r--libtiff/tif_error.c6
-rw-r--r--libtiff/tif_fax3.c75
-rw-r--r--libtiff/tif_fax3.h6
-rw-r--r--libtiff/tif_flush.c6
-rw-r--r--libtiff/tif_getimage.c6
-rw-r--r--libtiff/tif_jpeg.c15
-rw-r--r--libtiff/tif_lzw.c6
-rw-r--r--libtiff/tif_msdos.c6
-rw-r--r--libtiff/tif_next.c6
-rw-r--r--libtiff/tif_open.c149
-rw-r--r--libtiff/tif_packbits.c6
-rw-r--r--libtiff/tif_predict.c6
-rw-r--r--libtiff/tif_predict.h6
-rw-r--r--libtiff/tif_print.c6
-rw-r--r--libtiff/tif_read.c6
-rw-r--r--libtiff/tif_strip.c6
-rw-r--r--libtiff/tif_swab.c6
-rw-r--r--libtiff/tif_thunder.c6
-rw-r--r--libtiff/tif_tile.c6
-rw-r--r--libtiff/tif_unix.c6
-rw-r--r--libtiff/tif_version.c6
-rw-r--r--libtiff/tif_vms.c6
-rw-r--r--libtiff/tif_warning.c6
-rw-r--r--libtiff/tif_win3.c6
-rw-r--r--libtiff/tif_win32.c6
-rw-r--r--libtiff/tif_write.c6
-rw-r--r--libtiff/tif_zip.c6
-rw-r--r--libtiff/tiff.h19
-rw-r--r--libtiff/tiffcomp.h6
-rw-r--r--libtiff/tiffconf.h6
-rw-r--r--libtiff/tiffio.h6
-rw-r--r--libtiff/tiffiop.h13
-rw-r--r--man/TIFFOpen.3t101
-rw-r--r--man/libtiff.3t5
-rw-r--r--man/tiffcp.118
-rw-r--r--port/Makefile.in6
-rw-r--r--port/install.sh.in6
-rw-r--r--tools/Makefile.in6
-rw-r--r--tools/Makefile.lcc6
-rw-r--r--tools/fax2ps.c11
-rw-r--r--tools/fax2tiff.c6
-rw-r--r--tools/gif2tiff.c6
-rw-r--r--tools/pal2rgb.c6
-rw-r--r--tools/ppm2tiff.c6
-rw-r--r--tools/ras2tiff.c8
-rw-r--r--tools/rgb2ycbcr.c6
-rw-r--r--tools/sgi2tiff.c6
-rw-r--r--tools/sgigt.c6
-rw-r--r--tools/sgisv.c6
-rw-r--r--tools/thumbnail.c6
-rw-r--r--tools/tiff2bw.c6
-rw-r--r--tools/tiff2ps.c6
-rw-r--r--tools/tiffcmp.c6
-rw-r--r--tools/tiffcp.c180
-rw-r--r--tools/tiffdither.c6
-rw-r--r--tools/tiffdump.c11
-rw-r--r--tools/tiffinfo.c6
-rw-r--r--tools/tiffsplit.c6
99 files changed, 5058 insertions, 449 deletions
diff --git a/COPYRIGHT b/COPYRIGHT
index 78cb834e..b9fc9fe2 100644
--- a/COPYRIGHT
+++ b/COPYRIGHT
@@ -1,5 +1,5 @@
-Copyright (c) 1988-1995 Sam Leffler
-Copyright (c) 1991-1995 Silicon Graphics, Inc.
+Copyright (c) 1988-1996 Sam Leffler
+Copyright (c) 1991-1996 Silicon Graphics, Inc.
Permission to use, copy, modify, distribute, and sell this software and
its documentation for any purpose is hereby granted without fee, provided
diff --git a/Makefile.in b/Makefile.in
index b1dd3b3f..14c79064 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,12 +1,12 @@
#! smake
-# $Header: /usr/people/sam/tiff/RCS/Makefile.in,v 1.37 1995/10/16 22:01:20 sam Exp $
+# $Header: /usr/people/sam/tiff/RCS/Makefile.in,v 1.41 1996/01/10 19:30:44 sam Exp $
#
# @WARNING@
#
# Tag Image File Format Library
#
-# Copyright (c) 1988-1995 Sam Leffler
-# Copyright (c) 1991-1995 Silicon Graphics, Inc.
+# Copyright (c) 1988-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
@@ -109,6 +109,7 @@ TIFFFILES=\
libtiff/Makefile.in \
libtiff/Makefile.lcc \
libtiff/Makefile.msc \
+ libtiff/Makefile.acorn \
libtiff/t4.h \
libtiff/tiff.h \
libtiff/tiffcomp.h \
@@ -118,6 +119,7 @@ TIFFFILES=\
libtiff/mkg3states.c \
libtiff/mkspans.c \
libtiff/mkversion.c \
+ libtiff/tif_acorn.c \
libtiff/tif_apple.c \
libtiff/tif_atari.c \
libtiff/tif_aux.c \
@@ -301,6 +303,8 @@ CONTRIBFILES=\
contrib/mac-mpw \
contrib/acorn \
contrib/win32 \
+ contrib/win95 \
+ contrib/winnt \
${NULL}
DISTFILES=\
${TIFFFILES} \
diff --git a/README b/README
index cb680214..edeff123 100644
--- a/README
+++ b/README
@@ -1,4 +1,4 @@
-$Header: /usr/people/sam/tiff/RCS/README,v 1.26 1995/07/01 00:57:02 sam Exp $
+$Header: /usr/people/sam/tiff/RCS/README,v 1.27 1996/01/10 19:31:42 sam Exp $
TIFF Software Distribution
--------------------------
@@ -37,8 +37,8 @@ also be interested in knowing about it and, hopefully, be acknowledged.
The legal way of saying that is:
-Copyright (c) 1988-1995 Sam Leffler
-Copyright (c) 1991-1995 Silicon Graphics, Inc.
+Copyright (c) 1988-1996 Sam Leffler
+Copyright (c) 1991-1996 Silicon Graphics, Inc.
Permission to use, copy, modify, distribute, and sell this software and
its documentation for any purpose is hereby granted without fee, provided
diff --git a/config.guess b/config.guess
index 595d40fa..1626b108 100755
--- a/config.guess
+++ b/config.guess
@@ -267,7 +267,7 @@ EOF
i[34]86:BSD/386:*:*)
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
exit 0 ;;
- i[34]86:BSD/OS:*:*)
+ *:BSD/OS:*:*)
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
exit 0 ;;
*:FreeBSD:*:*)
diff --git a/config.site b/config.site
index a680210e..54a1b746 100644
--- a/config.site
+++ b/config.site
@@ -1,9 +1,9 @@
-# $Header: /usr/people/sam/tiff/RCS/config.site,v 1.7 1995/10/10 01:03:54 sam Exp $
+# $Header: /usr/people/sam/tiff/RCS/config.site,v 1.8 1996/01/10 19:31:37 sam Exp $
#
# TIFF Software
#
-# Copyright (c) 1990-1995 Sam Leffler
-# Copyright (c) 1991-1995 Silicon Graphics, Inc.
+# Copyright (c) 1990-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/configure b/configure
index 6211ecef..b68f57b6 100755
--- a/configure
+++ b/configure
@@ -1,10 +1,10 @@
#!/bin/sh
-# $Header: /usr/people/sam/tiff/RCS/configure,v 1.26 1995/10/15 23:39:31 sam Exp $
+# $Header: /usr/people/sam/tiff/RCS/configure,v 1.32 1996/01/10 19:31:39 sam Exp $
#
# Tag Image File Format (TIFF) Software
#
-# Copyright (c) 1988-1995 Sam Leffler
-# Copyright (c) 1991-1995 Silicon Graphics, Inc.
+# Copyright (c) 1988-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
@@ -85,6 +85,7 @@ Options: [defaults in brackets after descriptions]
--help print this message
--quiet do not print `Using ...' messages
--verbose opposite of --quiet
+ --noninteractive don't ask any questions
--version print the version of autoconf that created configure
--target=TARGET configure for TARGET [TARGET=HOST]
--srcdir=DIR find the sources in DIR [configure dir or ..]
@@ -93,6 +94,7 @@ EOF
}
QUIET=no
+NONINTERACTIVE=no
SITE=
TARGET=
SRCDIR=
@@ -130,6 +132,7 @@ do
;;
-quiet|--quiet) QUIET=yes;;
-verbose|--verbose) QUIET=no;;
+ -noninteractive|--noninteractive) NONINTERACTIVE=yes;;
-site|--site) ac_prev=SITE;;
-site=*|--site=*) SITE="$ac_optarg";;
-srcdir|--srcdir) ac_prev=SRCDIR;;
@@ -137,7 +140,7 @@ do
-target|--target) ac_prev=TARGET;;
-target=*|--target=*) TARGET="$ac_optarg" ;;
-version|--version)
- echo "This is TIFF configure $Revision: 1.26 $"
+ echo "This is TIFF configure $Revision: 1.32 $"
exit 0
;;
-help|--help) usage; exit 0;;
@@ -183,14 +186,14 @@ test "$SRCDIR" || {
done
}
if [ ! -r $SRCDIR/VERSION ]; then
- bitch "Can not locate sources in $SRCDIR."
+ bitch "Cannot locate sources in $SRCDIR."
kill -1 $$
fi
SRCDIR=`echo "$SRCDIR" | sed 's;\([^/]\)/*$;\1;'`
if [ -r ${SRCDIR}/tif_version.c ] ; then
SRCDIR_IS_LIBTIFF=yes
- PORDOTH=port.h
+ PORTDOTH=port.h
else
SRCDIR_IS_LIBTIFF=no
PORTDOTH=libtiff/port.h
@@ -227,7 +230,11 @@ Note()
}
Note ""
-Note "Configuring TIFF Software $VERSION."
+if [ $SRCDIR_IS_LIBTIFF = yes ] ; then
+ Note "Configuring TIFF Software (library only) $VERSION."
+else
+ Note "Configuring TIFF Software $VERSION."
+fi
Note ""
#
@@ -370,6 +377,9 @@ findHeader()
esac
for i in ${DIRS_LIBINC}; do
test -r $i/$1 && {
+ case "$i" in
+ /*) echo "$i/$1"; return ;;
+ esac
if [ $SRCDIR_IS_LIBTIFF = yes ]; then
echo "$i/$1";
else
@@ -558,14 +568,13 @@ fi
# in the Makefiles. If not, we add an explicit define
# for places where recursive calls are made.
#
-if [ -z "${SETMAKE:-}" ]; then
-M=
-eval `(cat<<'EOF'
+if [ -z "${SETMAKE-}" ]; then
+ if (cat<<'EOF'
+SHELL=/bin/sh
all:
- @echo M="${MAKE}"
+ @if [ -n "${MAKE}" ] ; then echo "make sets make" ; fi
EOF
-) | $MAKE -f - 2>&5`
- if [ "$M" ]; then
+) | $MAKE -f - | grep "make sets make" > /dev/null ; then
SETMAKE=
else
Note "Looks like $MAKE does not setup MAKE in Makefiles, will compensate."
@@ -584,7 +593,7 @@ if [ -z "$RANLIB" ]; then
Note "Warning, no ranlib, assuming it's not needed."
RANLIB=":"
$RM dummy.a
- if $AR rcs dummy.a; then
+ if $AR rcs dummy.a >/dev/null 2>&1; then
AROPTS=crs
Note "Looks like ar has an s option to build symbol tables."
fi
@@ -935,7 +944,7 @@ BuildPortDotH()
CheckFuncDecl floor 'extern double floor(double);' math.h
CheckFuncDecl ceil 'extern double ceil(double);' math.h
CheckFuncDecl exp 'extern double exp(double);' math.h
- CheckFuncDecl pow 'extern double pow(double);' math.h
+ CheckFuncDecl pow 'extern double pow(double, double);' math.h
CheckFuncDecl read 'extern int read(int, const void*, unsigned int);' unistd.h
CheckFuncDecl malloc 'extern void* malloc(size_t);' stdlib.h
CheckFuncDecl realloc 'extern void* realloc(void*, size_t);' stdlib.h
@@ -946,7 +955,7 @@ BuildPortDotH()
Note "Done creating $PORTDOTH."
}
-if test -f $PORTDOTH && CheckPortDotH; then
+if [ "$PORT" != no ] && test -f $PORTDOTH && CheckPortDotH; then
Note ""
Note "Using previously created $PORTDOTH."
else
@@ -1381,7 +1390,7 @@ EOF
fi
}
-if [ $QUIET = no ]; then
+if [ $NONINTERACTIVE = no ] ; then
ok=skip
while [ "$ok" != y ] && [ "$ok" != yes ]; do
if [ "$ok" != skip ]; then
@@ -1467,12 +1476,12 @@ relativize()
if [ $SRCDIR_IS_LIBTIFF = no ]; then
(for i do
case "$i" in
- ./*|../*) echo "../$i" ;;
- *) echo "$i" ;;
+ /*) echo "$i" ;;
+ *) echo "../$i" ;;
esac
done) | tr '\012' ' '
else
- echo "$@"
+ (for i do echo "$i" ; done ) | tr '\012' ' '
fi
}
#
@@ -1483,13 +1492,13 @@ makeIncArgs()
{
(for i do
case "$i" in
- ./*|../*)
+ /*) echo "-I$i" ;;
+ *)
if [ $SRCDIR_IS_LIBTIFF = yes ]; then
echo "-I$i"
else
echo "-I../$i"
fi ;;
- *) echo "-I$i" ;;
esac
done) | tr '\012' ' '
}
diff --git a/contrib/win95/Makefile.w95 b/contrib/win95/Makefile.w95
new file mode 100644
index 00000000..3f461ef5
--- /dev/null
+++ b/contrib/win95/Makefile.w95
@@ -0,0 +1,134 @@
+# $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.w95,v 1.2 1994/11/28
+06:13:31 sam Exp $
+#
+# Tag Image File Format Library
+#
+# Copyright (c) 1988, 1989, 1990, 1991, 1992 Sam Leffler
+# Copyright (c) 1991, 1992 Silicon Graphics, Inc.
+#
+# Permission to use, copy, modify, distribute, and sell this software and
+# its documentation for any purpose is hereby granted without fee, provided
+# that (i) the above copyright notices and this permission notice appear in
+# all copies of the software and related documentation, and (ii) the names of
+# Sam Leffler and Silicon Graphics may not be used in any advertising or
+# publicity relating to the software without the specific, prior written
+# permission of Sam Leffler and Silicon Graphics.
+#
+# THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
+# EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
+# WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
+#
+# IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
+# ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
+# OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+# WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF
+# LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+# OF THIS SOFTWARE.
+#
+# This Makefile is for use with microsoft nmake version 1.50 and
+# Microsoft 32-bit C/C++ Compiler 9.00
+#
+DESTDIR=.
+#
+IPATH= -I.
+CONF_LIBRARY=$(NULL)
+COPTS= -Oxa -DBSDTYPES -Zd
+CFLAGS= $(COPTS) $(CONF_LIBRARY)
+#
+INCS= tiff.h tiffio.h
+SRCS= tif_aux.c \
+ tif_close.c \
+ tif_codec.c \
+ tif_compress.c \
+ tif_dir.c \
+ tif_dirinfo.c \
+ tif_dirread.c \
+ tif_dirwrite.c \
+ tif_dumpmode.c \
+ tif_error.c \
+ tif_getimage.c \
+ tif_jpeg.c \
+ tif_flush.c \
+ tif_lzw.c \
+ tif_next.c \
+ tif_open.c \
+ tif_packbits.c \
+ tif_predict \
+ tif_print.c \
+ tif_read.c \
+ tif_swab.c \
+ tif_strip.c \
+ tif_thunder.c \
+ tif_tile.c \
+ tif_version.c \
+ tif_warning.c \
+ tif_write.c \
+ tif_win32.c
+
+
+OBJS= tif_aux.obj \
+ tif_close.obj \
+ tif_codec.obj \
+ tif_compress.obj \
+ tif_dir.obj \
+ tif_dirinfo.obj \
+ tif_dirread.obj \
+ tif_dirwrite.obj \
+ tif_dumpmode.obj \
+ tif_error.obj \
+ tif_getimage.obj \
+ tif_jpeg.obj \
+ tif_flush.obj \
+ tif_lzw.obj \
+ tif_next.obj \
+ tif_open.obj \
+ tif_packbits.obj \
+ tif_predict.obj \
+ tif_print.obj \
+ tif_read.obj \
+ tif_swab.obj \
+ tif_strip.obj \
+ tif_thunder.obj \
+ tif_tile.obj \
+ tif_version.obj \
+ tif_warning.obj \
+ tif_write.obj \
+ tif_win32.obj
+
+
+
+ALL= libtiff.lib
+
+all: $(ALL)
+
+%.obj : %.c
+ $(CC) $(CFLAGS) -c $*.c
+
+
+#.INCLUDE .IGNORE : depend
+
+libtiff.lib: $(OBJS)
+ - del libtiff.lib
+ lib /OUT:libtiff.lib $(OBJS)
+
+
+#To include fax3 support, you need to modify mkg3states.c so it could run
+#under windows 95 or NT. This application make the file g3state.h.
+#after that, you have to add to the build script : tif_fax3.c and tif_fax3.obj
+#and define CCITT_SUPPORT in the file tifconf.h
+
+#$(OBJS): tiffio.h tiff.h tiffcomp.h tiffiop.h tiffconf.h
+#tif_fax3.obj: tif_fax3.c g3states.h t4.h tif_fax3.h
+
+#g3states.h: mkg3states.c t4.h
+# $(CC) $(CFLAGS) mkg3states.c
+# mkg3states -c > g3states.h
+
+
+clean:
+ del *.obj
+ del mkg3stat
+ del g3states.h
+
+tags: $(SRCS)
+ $(CTAGS) $(SRCS)
diff --git a/contrib/win95/README b/contrib/win95/README
new file mode 100644
index 00000000..edb05d33
--- /dev/null
+++ b/contrib/win95/README
@@ -0,0 +1,50 @@
+Date: 04 Dec 95 10:34:23 EST
+From: Philippe <100423.3705@compuserve.com>
+To: TIFF/sam Leffler <sam@cthulhu.engr.sgi.com>
+Subject: TIFF library and Windows 95
+Message-Id: <951204153422_100423.3705_BHG101-1@CompuServe.COM>
+
+Sam,
+
+First, let me thanks all of you how have worked
+on that great TIFF library !
+
+Here is some information that may help someone.
+
+I build the library under Windows 95 as a 32-bit library.
+The contribution of Scott Wagner (tif_win32.c) worked fine, but
+the makefile "makefile.msc" was unsable because it was
+written for DOS or Windows 3.1 and all the files names
+are limited to 8 characters.
+
+Here is the makefile I used : makefile.w95
+
+Also, I had to disable fax3 support because I wasn't able
+to build (as it is) the tool "mkg3states" to generate the include
+file "g3states.h".
+This source file must be modify to be build under Windows 95.
+
+To build the library under Windows 95 with Visual C++ 2.0,
+I had to :
+
+- undefine CCITT_SUPPORT in "tiffconf.h"
+
+- create the file version.h with this line :
+ #define VERSION "3.4beta024"
+
+- build the makefile "makefile.w95"
+
+I also join the source file "tif2dib.c" that I created,
+it contain the function LoadTIFFinDIB that load
+a TIFF file and build a memory DIB with it and return the
+HANDLE (HDIB) of the memory bloc containing this DIB.
+Since DIB is the "natural" bitmap format for Windows 3.1, 95 and NT,
+this function sould be usefull for some Windows 95 (or NT) developer.
+
+
+Sorry for my approximate english ...
+
+Regards,
+
+Philippe Tenenhaus 100423.3705@compuserve.com
+Paris
diff --git a/contrib/win95/tiff2dib.c b/contrib/win95/tiff2dib.c
new file mode 100644
index 00000000..f5d4040f
--- /dev/null
+++ b/contrib/win95/tiff2dib.c
@@ -0,0 +1,372 @@
+/*************************************************************************
+ *
+ * Source file for Windows 95/Win32.
+ *
+ * The function LoadTIFFinDIB in this source file let you load
+ * a TIFF file and build a memory DIB with it and return the
+ * HANDLE (HDIB) of the memory bloc containing the DIB.
+ *
+ * Example :
+ *
+ * HDIB hDIB;
+ * hDIB = LoadTIFFinDIB("sample.tif");
+ *
+ *
+ * To build this source file you must include the TIFF library
+ * in your project.
+ *
+ * 4/12/95 Philippe Tenenhaus 100423.3705@compuserve.com
+ *
+ ************************************************************************/
+
+
+#include "tiffio.h"
+
+#define HDIB HANDLE
+#define IS_WIN30_DIB(lpbi) ((*(LPDWORD)(lpbi)) == sizeof(BITMAPINFOHEADER))
+#define CVT(x) (((x) * 255L) / ((1L<<16)-1))
+
+static HDIB CreateDIB(DWORD dwWidth, DWORD dwHeight, WORD wBitCount);
+static LPSTR FindDIBBits(LPSTR lpDIB);
+static WORD PaletteSize(LPSTR lpDIB);
+static WORD DIBNumColors(LPSTR lpDIB);
+static int checkcmap(int n, uint16* r, uint16* g, uint16* b);
+
+
+
+/*************************************************************************
+ *
+ * HDIB LoadTIFFinDIB(LPSTR lpFileName)
+ *
+ * Parameter:
+ *
+ * LPSTR lpDIB - File name of a tiff imag
+ *
+ * Return Value:
+ *
+ * LPSTR - HANDLE of a DIB
+ *
+ * Description:
+ *
+ * This function load a TIFF file and build a memory DIB with it
+ * and return the HANDLE (HDIB) of the memory bloc containing
+ * the DIB.
+ *
+ * 4/12/95 Philippe Tenenhaus 100423.3705@compuserve.com
+ *
+ ************************************************************************/
+
+HDIB LoadTIFFinDIB(LPSTR lpFileName)
+{
+ TIFF *tif;
+ unsigned long imageLength;
+ unsigned long imageWidth;
+ unsigned int BitsPerSample;
+ unsigned long LineSize;
+ unsigned int SamplePerPixel;
+ unsigned long RowsPerStrip;
+ int PhotometricInterpretation;
+ long nrow;
+ unsigned long row;
+ char *buf;
+ LPBITMAPINFOHEADER lpDIB;
+ HDIB hDIB;
+ char *lpBits;
+ HGLOBAL hStrip;
+ int i,l;
+ int Align;
+
+ tif = TIFFOpen(lpFileName, "r");
+
+ if (!tif)
+ goto TiffOpenError;
+
+ TIFFGetField(tif, TIFFTAG_IMAGEWIDTH, &imageWidth);
+ TIFFGetField(tif, TIFFTAG_IMAGELENGTH, &imageLength);
+ TIFFGetField(tif, TIFFTAG_BITSPERSAMPLE, &BitsPerSample);
+ TIFFGetField(tif, TIFFTAG_ROWSPERSTRIP, &RowsPerStrip);
+ TIFFGetField(tif, TIFFTAG_ROWSPERSTRIP, &RowsPerStrip);
+ TIFFGetField(tif, TIFFTAG_PHOTOMETRIC, &PhotometricInterpretation);
+
+ LineSize = TIFFScanlineSize(tif); //Number of byte in ine line
+
+ SamplePerPixel = (int) (LineSize/imageWidth);
+
+ //Align = Number of byte to add at the end of each line of the DIB
+ Align = 4 - (LineSize % 4);
+ if (Align == 4) Align = 0;
+
+
+ //Create a new DIB
+ hDIB = CreateDIB((DWORD) imageWidth, (DWORD) imageLength, (WORD)
+(BitsPerSample*SamplePerPixel));
+ lpDIB = (LPBITMAPINFOHEADER) GlobalLock(hDIB);
+ if (!lpDIB)
+ goto OutOfDIBMemory;
+
+ if (lpDIB)
+ lpBits = FindDIBBits((LPSTR) lpDIB);
+
+ //In the tiff file the lines are save from up to down
+ //In a DIB the lines must be save from down to up
+ if (lpBits)
+ {
+ lpBits = FindDIBBits((LPSTR) lpDIB);
+ lpBits+=((imageWidth*SamplePerPixel)+Align)*(imageLength-1);
+ //now lpBits pointe on the bottom line
+
+ hStrip = GlobalAlloc(GHND,TIFFStripSize(tif));
+ buf = GlobalLock(hStrip);
+
+ if (!buf)
+ goto OutOfBufMemory;
+
+ //PhotometricInterpretation = 2 image is RGB
+ //PhotometricInterpretation = 3 image have a color palette
+ if (PhotometricInterpretation == 3)
+ {
+ uint16* red;
+ uint16* green;
+ uint16* blue;
+ int16 i;
+ LPBITMAPINFO lpbmi;
+ int Palette16Bits;
+
+ TIFFGetField(tif, TIFFTAG_COLORMAP, &red, &green, &blue);
+
+ //Is the palette 16 or 8 bits ?
+ if (checkcmap(1<<BitsPerSample, red, green, blue) == 16)
+ Palette16Bits = TRUE;
+ else
+ Palette16Bits = FALSE;
+
+ lpbmi = (LPBITMAPINFO)lpDIB;
+
+ //load the palette in the DIB
+ for (i = (1<<BitsPerSample)-1; i >= 0; i--)
+ {
+ if (Palette16Bits)
+ {
+ lpbmi->bmiColors[i].rgbRed =(BYTE) CVT(red[i]);
+ lpbmi->bmiColors[i].rgbGreen = (BYTE) CVT(green[i]);
+ lpbmi->bmiColors[i].rgbBlue = (BYTE) CVT(blue[i]);
+ }
+ else
+ {
+ lpbmi->bmiColors[i].rgbRed = (BYTE) red[i];
+ lpbmi->bmiColors[i].rgbGreen = (BYTE) green[i];
+ lpbmi->bmiColors[i].rgbBlue = (BYTE) blue[i];
+ }
+ }
+
+ }
+
+ //read the tiff lines and save them in the DIB
+ //with RGB mode, we have to change the order of the 3 samples RGB
+<=> BGR
+ for (row = 0; row < imageLength; row += RowsPerStrip)
+ {
+ nrow = (row + RowsPerStrip > imageLength ? imageLength - row :
+RowsPerStrip);
+ if (TIFFReadEncodedStrip(tif, TIFFComputeStrip(tif, row, 0),
+ buf, nrow*LineSize)==-1)
+ {
+ goto TiffReadError;
+ }
+ else
+ {
+ for (l = 0; l < nrow; l++)
+ {
+ if (SamplePerPixel == 3)
+ for (i=0;i< (int) (imageWidth);i++)
+ {
+ lpBits[i*SamplePerPixel+0]=buf[l*LineSize+i*Sample
+PerPixel+2];
+ lpBits[i*SamplePerPixel+1]=buf[l*LineSize+i*Sample
+PerPixel+1];
+ lpBits[i*SamplePerPixel+2]=buf[l*LineSize+i*Sample
+PerPixel+0];
+ }
+ else
+ memcpy(lpBits, &buf[(int) (l*LineSize)], (int)
+imageWidth*SamplePerPixel);
+
+ lpBits-=imageWidth*SamplePerPixel+Align;
+
+ }
+ }
+ }
+ GlobalUnlock(hStrip);
+ GlobalFree(hStrip);
+ GlobalUnlock(hDIB);
+ TIFFClose(tif);
+ }
+
+ return hDIB;
+
+ OutOfBufMemory:
+
+ TiffReadError:
+ GlobalUnlock(hDIB);
+ GlobalFree(hStrip);
+ OutOfDIBMemory:
+ TIFFClose(tif);
+ TiffOpenError:
+ return (HANDLE) 0;
+
+
+}
+
+
+static int checkcmap(int n, uint16* r, uint16* g, uint16* b)
+{
+ while (n-- > 0)
+ if (*r++ >= 256 || *g++ >= 256 || *b++ >= 256)
+ return (16);
+
+ return (8);
+}
+
+
+
+/*************************************************************************
+ * All the following functions were created by microsoft, they are
+ * parts of the sample project "wincap" given with the SDK Win32.
+ *
+ * Microsoft says that :
+ *
+ * You have a royalty-free right to use, modify, reproduce and
+ * distribute the Sample Files (and/or any modified version) in
+ * any way you find useful, provided that you agree that
+ * Microsoft has no warranty obligations or liability for any
+ * Sample Application Files which are modified.
+ *
+ ************************************************************************/
+
+HDIB CreateDIB(DWORD dwWidth, DWORD dwHeight, WORD wBitCount)
+{
+ BITMAPINFOHEADER bi; // bitmap header
+ LPBITMAPINFOHEADER lpbi; // pointer to BITMAPINFOHEADER
+ DWORD dwLen; // size of memory block
+ HDIB hDIB;
+ DWORD dwBytesPerLine; // Number of bytes per scanline
+
+
+ // Make sure bits per pixel is valid
+ if (wBitCount <= 1)
+ wBitCount = 1;
+ else if (wBitCount <= 4)
+ wBitCount = 4;
+ else if (wBitCount <= 8)
+ wBitCount = 8;
+ else if (wBitCount <= 24)
+ wBitCount = 24;
+ else
+ wBitCount = 4; // set default value to 4 if parameter is bogus
+
+ // initialize BITMAPINFOHEADER
+ bi.biSize = sizeof(BITMAPINFOHEADER);
+ bi.biWidth = dwWidth; // fill in width from parameter
+ bi.biHeight = dwHeight; // fill in height from parameter
+ bi.biPlanes = 1; // must be 1
+ bi.biBitCount = wBitCount; // from parameter
+ bi.biCompression = BI_RGB;
+ bi.biSizeImage = (dwWidth*dwHeight*wBitCount)/8; //0; // 0's here
+mean "default"
+ bi.biXPelsPerMeter = 2834; //0;
+ bi.biYPelsPerMeter = 2834; //0;
+ bi.biClrUsed = 0;
+ bi.biClrImportant = 0;
+
+ // calculate size of memory block required to store the DIB. This
+ // block should be big enough to hold the BITMAPINFOHEADER, the color
+ // table, and the bits
+
+ dwBytesPerLine = (((wBitCount * dwWidth) + 31) / 32 * 4);
+ dwLen = bi.biSize + PaletteSize((LPSTR)&bi) + (dwBytesPerLine * dwHeight);
+
+ // alloc memory block to store our bitmap
+ hDIB = GlobalAlloc(GHND, dwLen);
+
+ // major bummer if we couldn't get memory block
+ if (!hDIB)
+ {
+ return NULL;
+ }
+
+ // lock memory and get pointer to it
+ lpbi = (VOID FAR *)GlobalLock(hDIB);
+
+ // use our bitmap info structure to fill in first part of
+ // our DIB with the BITMAPINFOHEADER
+ *lpbi = bi;
+
+ // Since we don't know what the colortable and bits should contain,
+ // just leave these blank. Unlock the DIB and return the HDIB.
+
+ GlobalUnlock(hDIB);
+
+ /* return handle to the DIB */
+ return hDIB;
+}
+
+
+LPSTR FAR FindDIBBits(LPSTR lpDIB)
+{
+ return (lpDIB + *(LPDWORD)lpDIB + PaletteSize(lpDIB));
+}
+
+
+WORD FAR PaletteSize(LPSTR lpDIB)
+{
+ /* calculate the size required by the palette */
+ if (IS_WIN30_DIB (lpDIB))
+ return (DIBNumColors(lpDIB) * sizeof(RGBQUAD));
+ else
+ return (DIBNumColors(lpDIB) * sizeof(RGBTRIPLE));
+}
+
+
+WORD DIBNumColors(LPSTR lpDIB)
+{
+ WORD wBitCount; // DIB bit count
+
+ /* If this is a Windows-style DIB, the number of colors in the
+ * color table can be less than the number of bits per pixel
+ * allows for (i.e. lpbi->biClrUsed can be set to some value).
+ * If this is the case, return the appropriate value.
+ */
+
+ if (IS_WIN30_DIB(lpDIB))
+ {
+ DWORD dwClrUsed;
+
+ dwClrUsed = ((LPBITMAPINFOHEADER)lpDIB)->biClrUsed;
+ if (dwClrUsed)
+ return (WORD)dwClrUsed;
+ }
+
+ /* Calculate the number of colors in the color table based on
+ * the number of bits per pixel for the DIB.
+ */
+ if (IS_WIN30_DIB(lpDIB))
+ wBitCount = ((LPBITMAPINFOHEADER)lpDIB)->biBitCount;
+ else
+ wBitCount = ((LPBITMAPCOREHEADER)lpDIB)->bcBitCount;
+
+ /* return number of colors based on bits per pixel */
+ switch (wBitCount)
+ {
+ case 1:
+ return 2;
+
+ case 4:
+ return 16;
+
+ case 8:
+ return 256;
+
+ default:
+ return 0;
+ }
+}
diff --git a/contrib/winnt/README b/contrib/winnt/README
new file mode 100644
index 00000000..68c64410
--- /dev/null
+++ b/contrib/winnt/README
@@ -0,0 +1,26 @@
+Date: Fri, 10 Nov 1995 13:02:33 -0800
+Message-Id: <199511102102.NAA07993@lido>
+To: tiff@sgi.engr.sgi.com
+Subject: Contribution: libtiff for Windows-nt
+Reply-To: Dave Dyer <ddyer@triple-i.com>
+Sender: owner-tiff@sgi.engr.sgi.com
+Precedence: bulk
+
+
+Since I needed it, and the support for windows-nt versions of libtiff
+is sketchy at best, I packaged up my port of libtiff v3.4beta024
+to windows-nt.
+
+ ftp://torii.triple-i.com/pub/ddyer/libtiff.tar.gz
+
+this contains "libtiff.mak", a makefile for microsoft visual c++,
+a couple of hand-built .h and .c files (corresponding to those which
+are automatically constructed by unix makefiles) and static libraries
+compiled for intel and dec alpha.
+
+As customary, I make no claims regarding the completeness or
+correctness of these libraries, and accept no responsibily for any
+mishaps you may have as a result of using them. They work for me.
+
+I hope Sam will copy and incorporate this into the "contrib" section
+of the next libtiff release.
diff --git a/contrib/winnt/fax3sm.c b/contrib/winnt/fax3sm.c
new file mode 100644
index 00000000..1d0f34a3
--- /dev/null
+++ b/contrib/winnt/fax3sm.c
@@ -0,0 +1,1046 @@
+/* WARNING, this file was automatically generated by the
+ mkg3states program */
+#include "tiff.h"
+#include "tif_fax3.h"
+ const TIFFFaxTabEnt TIFFFaxMainTable[128] = {
+12,7,0,3,1,0,5,3,1,3,1,0,2,3,0,3,1,0,4,3,1,3,1,0,1,4,0,3,1,0,5,3,1,3,1,0,
+2,3,0,3,1,0,4,3,1,3,1,0,5,6,2,3,1,0,5,3,1,3,1,0,2,3,0,3,1,0,4,3,1,3,1,0,
+1,4,0,3,1,0,5,3,1,3,1,0,2,3,0,3,1,0,4,3,1,3,1,0,5,7,3,3,1,0,5,3,1,3,1,0,
+2,3,0,3,1,0,4,3,1,3,1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,4,6,
+7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,
+7,8,41,7,6,16,9,9,960,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,704,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,
+9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,11,11,1792,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,832,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,
+7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1600,7,4,5,
+7,8,44,7,6,17,9,9,1344,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,
+7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1088,7,4,6,
+7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,
+7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1536,7,4,5,7,8,43,7,6,17,9,9,1280,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,
+7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,1024,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,768,7,4,6,
+7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+11,11,1856,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,896,7,4,6,
+7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,
+7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1728,7,4,5,7,8,44,7,6,17,9,9,1408,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,
+7,8,42,7,6,16,9,9,1152,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,
+9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,
+7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1472,7,4,5,
+7,8,43,7,6,17,9,9,1216,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,
+7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,960,7,4,6,
+7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,9,704,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,11,12,2112,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,40,7,6,16,9,9,832,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,
+7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1600,7,4,5,7,8,44,7,6,17,9,9,1344,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,
+7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1088,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,
+7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,
+7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,
+7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1536,7,4,5,7,8,43,7,6,17,9,9,1280,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,
+7,8,41,7,6,16,9,9,1024,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,768,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,
+9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,11,12,2368,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,896,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,
+7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1728,7,4,5,
+7,8,44,7,6,17,9,9,1408,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,
+7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1152,7,4,6,
+7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,
+7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1472,7,4,5,7,8,43,7,6,17,9,9,1216,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,
+7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,960,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,704,7,4,6,
+7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+11,12,1984,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,832,7,4,6,
+7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,
+7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1600,7,4,5,7,8,44,7,6,17,9,9,1344,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,
+7,8,42,7,6,16,9,9,1088,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,
+9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,
+7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1536,7,4,5,
+7,8,43,7,6,17,9,9,1280,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,
+7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,1024,7,4,6,
+7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,9,768,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,11,11,1920,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,40,7,6,16,9,9,896,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,
+7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1728,7,4,5,7,8,44,7,6,17,9,9,1408,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,
+7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1152,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,
+7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,
+7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,
+7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1472,7,4,5,7,8,43,7,6,17,9,9,1216,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,
+7,8,41,7,6,16,9,9,960,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,704,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,
+9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,11,12,2240,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,832,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,
+7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1600,7,4,5,
+7,8,44,7,6,17,9,9,1344,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,
+7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1088,7,4,6,
+7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,
+7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1536,7,4,5,7,8,43,7,6,17,9,9,1280,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,
+7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,1024,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,768,7,4,6,
+7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+11,12,2496,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,896,7,4,6,
+7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,
+7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1728,7,4,5,7,8,44,7,6,17,9,9,1408,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,
+7,8,42,7,6,16,9,9,1152,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,
+9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,12,11,0,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,
+7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1472,7,4,5,
+7,8,43,7,6,17,9,9,1216,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,
+7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,960,7,4,6,
+7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,9,704,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,11,11,1792,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,40,7,6,16,9,9,832,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,
+7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1600,7,4,5,7,8,44,7,6,17,9,9,1344,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,
+7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1088,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,
+7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,
+7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,
+7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1536,7,4,5,7,8,43,7,6,17,9,9,1280,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,
+7,8,41,7,6,16,9,9,1024,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,768,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,
+9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,11,11,1856,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,896,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,
+7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1728,7,4,5,
+7,8,44,7,6,17,9,9,1408,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,
+7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1152,7,4,6,
+7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,
+7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1472,7,4,5,7,8,43,7,6,17,9,9,1216,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,
+7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,960,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,704,7,4,6,
+7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+11,12,2176,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,832,7,4,6,
+7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,
+7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1600,7,4,5,7,8,44,7,6,17,9,9,1344,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,
+7,8,42,7,6,16,9,9,1088,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,
+9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,
+7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1536,7,4,5,
+7,8,43,7,6,17,9,9,1280,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,
+7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,1024,7,4,6,
+7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,9,768,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,11,12,2432,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,40,7,6,16,9,9,896,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,
+7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1728,7,4,5,7,8,44,7,6,17,9,9,1408,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,
+7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1152,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,
+7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,
+7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,
+7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1472,7,4,5,7,8,43,7,6,17,9,9,1216,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,
+7,8,41,7,6,16,9,9,960,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,704,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,
+9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,11,12,2048,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,832,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,
+7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1600,7,4,5,
+7,8,44,7,6,17,9,9,1344,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,
+7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1088,7,4,6,
+7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,
+7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1536,7,4,5,7,8,43,7,6,17,9,9,1280,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,
+7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,1024,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,768,7,4,6,
+7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+11,11,1920,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,896,7,4,6,
+7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,
+7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1728,7,4,5,7,8,44,7,6,17,9,9,1408,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,7,8,48,7,4,3,7,8,60,7,4,5,
+7,8,42,7,6,16,9,9,1152,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,7,8,38,9,5,128,7,7,25,7,6,15,
+9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,0,0,0,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,7,7,19,7,5,8,7,8,55,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,7,8,53,7,5,9,9,8,448,7,4,6,
+7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1472,7,4,5,
+7,8,43,7,6,17,9,9,1216,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,8,33,9,5,128,7,8,49,7,6,14,
+7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,7,8,41,7,6,16,9,9,960,7,4,6,
+7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,
+7,7,26,7,5,9,9,9,704,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,9,8,320,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,11,12,2304,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,
+7,8,40,7,6,16,9,9,832,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,7,8,36,9,5,128,7,8,52,7,6,15,
+7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1600,7,4,5,7,8,44,7,6,17,9,9,1344,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,30,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,8,34,9,5,128,7,8,50,7,6,14,7,8,62,7,4,4,7,4,2,7,4,7,
+7,8,48,7,4,3,7,8,60,7,4,5,7,8,42,7,6,16,9,9,1088,7,4,6,7,8,32,7,5,8,7,8,58,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,8,640,7,4,6,
+7,8,38,9,5,128,7,7,25,7,6,15,9,8,384,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,
+7,7,21,7,6,17,9,7,256,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+0,0,0,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,
+7,7,28,7,4,4,7,4,2,7,4,7,7,7,23,7,4,3,7,7,27,7,4,5,7,8,39,7,6,16,9,8,576,7,4,6,
+7,7,19,7,5,8,7,8,55,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,7,8,45,7,4,3,7,5,11,7,4,5,
+7,8,53,7,5,9,9,8,448,7,4,6,7,8,35,9,5,128,7,8,51,7,6,15,7,8,63,7,4,4,7,4,2,7,4,7,
+7,6,13,7,4,3,9,9,1536,7,4,5,7,8,43,7,6,17,9,9,1280,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,29,7,4,3,7,5,11,7,4,5,7,6,12,7,5,9,9,6,1664,7,4,6,
+7,8,33,9,5,128,7,8,49,7,6,14,7,8,61,7,4,4,7,4,2,7,4,7,7,8,47,7,4,3,7,8,59,7,4,5,
+7,8,41,7,6,16,9,9,1024,7,4,6,7,8,31,7,5,8,7,8,57,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,
+7,7,22,7,4,3,7,5,11,7,4,5,7,7,26,7,5,9,9,9,768,7,4,6,7,8,37,9,5,128,7,7,25,7,6,15,
+9,8,320,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,7,7,18,7,4,5,7,7,21,7,6,17,9,7,256,7,4,6,
+7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7,4,2,7,4,7,11,12,2560,7,4,3,7,5,11,7,4,5,
+7,6,12,7,5,9,9,6,1664,7,4,6,7,7,20,9,5,128,7,7,24,7,6,14,7,7,28,7,4,4,7,4,2,7,4,7,
+7,7,23,7,4,3,7,7,27,7,4,5,7,8,40,7,6,16,9,9,896,7,4,6,7,7,19,7,5,8,7,8,56,9,5,64,
+7,5,10,7,4,4,7,4,2,7,4,7,7,8,46,7,4,3,7,5,11,7,4,5,7,8,54,7,5,9,9,8,512,7,4,6,
+7,8,36,9,5,128,7,8,52,7,6,15,7,8,0,7,4,4,7,4,2,7,4,7,7,6,13,7,4,3,9,9,1728,7,4,5,
+7,8,44,7,6,17,9,9,1408,7,4,6,7,6,1,7,5,8,9,6,192,9,5,64,7,5,10,7,4,4,7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,3,8,3,1,8,2,2,8,4,5,8,2,3,8,3,4,8,2,2,
+11,12,2560,8,2,3,8,3,1,8,2,2,8,4,6,8,2,3,8,3,4,8,2,2,8,6,9,8,2,3,8,3,1,8,2,2,
+8,4,5,8,2,3,8,3,4,8,2,2,8,7,10,8,2,3,8,3,1,8,2,2,8,4,6,8,2,3,8,3,4,8,2,2,
+8,5,7,8,2,3,8,3,1,8,2,2,8,4,5,8,2,3,8,3,4,8,2,2,8,10,16,8,2,3,8,3,1,8,2,2,
+8,4,6,8,2,3,8,3,4,8,2,2,8,6,8,8,2,3,8,3,1,8,2,2,8,4,5,8,2,3,8,3,4,8,2,2,
+8,10,0,8,2,3,8,3,1,8,2,2,8,4,6,8,2,3,8,3,4,8,2,2,8,5,7,8,2,3,8,3,1,8,2,2,
+8,4,5,8,2,3,8,3,4,8,2,2,10,10,64,8,2,3,8,3,1,8,2,2,8,4,6,8,2,3,8,3,4,8,2,2,
+8,6,9,8,2,3,8,3,1,8,2,2,8,4,5,8,2,3,8,3,4,8,2,2,8,7,11,8,2,3,8,3,1,8,2,2,
+8,4,6,8,2,3,8,3,4,8,2,2,8,5,7,8,2,3,8,3,1,8,2,2,8,4,5,8,2,3,8,3,4,8,2,2,
+8,8,14,8,2,3,8,3,1,8,2,2,8,4,6,8,2,3,8,3,4,8,2,2,8,6,8,8,2,3,8,3,1,8,2,2,
+8,4,5,8,2,3,8,3,4,8,2,2,8,7,12,8,2,3,8,3,1,8,2,2,8,4,6,8,2,3,8,3,4,8,2,2,
+8,5,7,8,2,3,8,3,1,8,2,2,8,4,5,8,2,3,8,3,4,8,2,2
+};
diff --git a/contrib/winnt/libtiff.def b/contrib/winnt/libtiff.def
new file mode 100644
index 00000000..7ed4e7b6
--- /dev/null
+++ b/contrib/winnt/libtiff.def
@@ -0,0 +1,72 @@
+LIBRARY libtiff
+EXPORTS TIFFOpen
+ TIFFGetVersion
+ TIFFClose
+ TIFFFlush
+ TIFFFlushData
+ TIFFFlushdata1
+ TIFFGetField
+ TIFFVGetField
+ TIFFGetFieldDefaulted
+ TIFFVGetFieldDefaulted
+ TIFFReadDirectory
+ TIFFScanlineSize
+ TIFFStripSize
+ TIFFVStripSize
+ TIFFTileRowSize
+ TIFFTileSize
+ TIFFVTileSize
+ TIFFFileno
+ TIFFGetMode
+ TIFFIsTiled
+ TIFFIsByteSwapped
+ TIFFCurrentRow
+ TIFFCurrentDirectory
+ TIFFCurrentStrip
+ TIFFCurrentTile
+ TIFFReadBufferSetup
+ TIFFLastDirectory
+ TIFFSetDirectory
+ TIFFSetSubDirectory
+ TIFFUnlinkDirectory
+ TIFFSetField
+ TIFFVSetField
+ TIFFWriteDirectory
+ TIFFPrintDirectory
+ TIFFReadScanline
+ TIFFWriteScanline
+ TIFFReadRGBAImage
+ TIFFPrintDirectory
+ TIFFReadScanline
+ TIFFWriteScanline
+ TIFFReadRGBAImage
+ TIFFFdOpen
+ TIFFClientOpen
+ TIFFFileName
+ TIFFError
+ TIFFWarning
+ TIFFSetErrorHandler
+ TIFFSetWarningHandler
+ TIFFComputeTile
+ TIFFCheckTile
+ TIFFNumberOfTiles
+ TIFFReadTile
+ TIFFWriteTile
+ TIFFComputeStrip
+ TIFFNumberOfStrips
+ TIFFReadEncodedStrip
+ TIFFReadRawStrip
+ TIFFReadEncodedTile
+ TIFFReadRawTile
+ TIFFWriteEncodedStrip
+ TIFFWriteRawStrip
+ TIFFWriteEncodedTile
+ TIFFWriteRawTile
+ TIFFSetWriteOffset
+ TIFFSwabShort
+ TIFFSwabLong
+ TIFFSwabArrayOfShort
+ TIFFSwabArrayOfLong
+ TIFFReverseBits
+ TIFFGetBitRevTable
+ TIFFModeCCITTFax3
diff --git a/contrib/winnt/libtiff.mak b/contrib/winnt/libtiff.mak
new file mode 100644
index 00000000..c5a351e0
--- /dev/null
+++ b/contrib/winnt/libtiff.mak
@@ -0,0 +1,1947 @@
+# Microsoft Visual C++ Generated NMAKE File, Format Version 2.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (ALPHA) Static Library" 0x0604
+# TARGTYPE "Macintosh Static Library" 0x0304
+# TARGTYPE "Win32 (x86) Static Library" 0x0104
+
+!IF "$(CFG)" == ""
+CFG=Win32 Debug
+!MESSAGE No configuration specified. Defaulting to Win32 Debug.
+!ENDIF
+
+!IF "$(CFG)" != "Win32 Release" && "$(CFG)" != "Win32 Debug" && "$(CFG)" !=\
+ "Macintosh Release" && "$(CFG)" != "Macintosh Debug" && "$(CFG)" != "APXrel" &&\
+ "$(CFG)" != "APXdeb"
+!MESSAGE Invalid configuration "$(CFG)" specified.
+!MESSAGE You can specify a configuration when running NMAKE on this makefile
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "libtiff.mak" CFG="Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "Win32 Release" (based on "Win32 (x86) Static Library")
+!MESSAGE "Win32 Debug" (based on "Win32 (x86) Static Library")
+!MESSAGE "Macintosh Release" (based on "Macintosh Static Library")
+!MESSAGE "Macintosh Debug" (based on "Macintosh Static Library")
+!MESSAGE "APXrel" (based on "Win32 (ALPHA) Static Library")
+!MESSAGE "APXdeb" (based on "Win32 (ALPHA) Static Library")
+!MESSAGE
+!ERROR An invalid configuration is specified.
+!ENDIF
+
+################################################################################
+# Begin Project
+# PROP Target_Last_Scanned "Win32 Release"
+
+!IF "$(CFG)" == "Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "WinRel"
+# PROP BASE Intermediate_Dir "WinRel"
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "WinRel"
+# PROP Intermediate_Dir "WinRel"
+OUTDIR=.\WinRel
+INTDIR=.\WinRel
+
+ALL : $(OUTDIR)/""libtiff.lib"" $(OUTDIR)/""libtiff.bsc""
+
+$(OUTDIR) :
+ if not exist $(OUTDIR)/nul mkdir $(OUTDIR)
+
+CPP=cl.exe
+# ADD BASE CPP /nologo /W3 /GX /YX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /FR /c
+# ADD CPP /nologo /MT /W3 /GX /YX /O2 /I "." /I ".." /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /FR /c
+CPP_PROJ=/nologo /MT /W3 /GX /YX /O2 /I "." /I ".." /D "WIN32" /D "NDEBUG" /D\
+ "_WINDOWS" /FR$(INTDIR)/ /Fp$(OUTDIR)/"libtiff.pch" /Fo$(INTDIR)/ /c
+CPP_OBJS=.\WinRel/
+
+.c{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cpp{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cxx{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+BSC32_FLAGS=/nologo /o$(OUTDIR)/"libtiff.bsc"
+BSC32_SBRS= \
+ $(INTDIR)/"tif_jpeg.sbr" \
+ $(INTDIR)/"tif_dirinfo.sbr" \
+ $(INTDIR)/"tif_win32.sbr" \
+ $(INTDIR)/"tif_flush.sbr" \
+ $(INTDIR)/"tif_thunder.sbr" \
+ $(INTDIR)/"tif_compress.sbr" \
+ $(INTDIR)/"tif_print.sbr" \
+ $(INTDIR)/"tif_dirread.sbr" \
+ $(INTDIR)/"tif_getimage.sbr" \
+ $(INTDIR)/"tif_fax3.sbr" \
+ $(INTDIR)/"tif_version.sbr" \
+ $(INTDIR)/"tif_codec.sbr" \
+ $(INTDIR)/"tif_dir.sbr" \
+ $(INTDIR)/"tif_predict.sbr" \
+ $(INTDIR)/"tif_close.sbr" \
+ $(INTDIR)/"tif_dumpmode.sbr" \
+ $(INTDIR)/"tif_aux.sbr" \
+ $(INTDIR)/"tif_error.sbr" \
+ $(INTDIR)/"tif_lzw.sbr" \
+ $(INTDIR)/"tif_zip.sbr" \
+ $(INTDIR)/"tif_read.sbr" \
+ $(INTDIR)/"tif_packbits.sbr" \
+ $(INTDIR)/"tif_swab.sbr" \
+ $(INTDIR)/"tif_dirwrite.sbr" \
+ $(INTDIR)/"tif_open.sbr" \
+ $(INTDIR)/"tif_warning.sbr" \
+ $(INTDIR)/"tif_tile.sbr" \
+ $(INTDIR)/"tif_strip.sbr" \
+ $(INTDIR)/"tif_next.sbr" \
+ $(INTDIR)/"tif_write.sbr" \
+ $(INTDIR)/"fax3sm.sbr"
+
+$(OUTDIR)/"libtiff.bsc" : $(OUTDIR) $(BSC32_SBRS)
+ $(BSC32) @<<
+ $(BSC32_FLAGS) $(BSC32_SBRS)
+<<
+
+LIB32=lib.exe
+# ADD BASE LIB32 /NOLOGO
+# ADD LIB32 /NOLOGO
+LIB32_FLAGS=/NOLOGO /OUT:$(OUTDIR)\"libtiff.lib"
+DEF_FLAGS=
+DEF_FILE=
+LIB32_OBJS= \
+ $(INTDIR)/"tif_jpeg.obj" \
+ $(INTDIR)/"tif_dirinfo.obj" \
+ $(INTDIR)/"tif_win32.obj" \
+ $(INTDIR)/"tif_flush.obj" \
+ $(INTDIR)/"tif_thunder.obj" \
+ $(INTDIR)/"tif_compress.obj" \
+ $(INTDIR)/"tif_print.obj" \
+ $(INTDIR)/"tif_dirread.obj" \
+ $(INTDIR)/"tif_getimage.obj" \
+ $(INTDIR)/"tif_fax3.obj" \
+ $(INTDIR)/"tif_version.obj" \
+ $(INTDIR)/"tif_codec.obj" \
+ $(INTDIR)/"tif_dir.obj" \
+ $(INTDIR)/"tif_predict.obj" \
+ $(INTDIR)/"tif_close.obj" \
+ $(INTDIR)/"tif_dumpmode.obj" \
+ $(INTDIR)/"tif_aux.obj" \
+ $(INTDIR)/"tif_error.obj" \
+ $(INTDIR)/"tif_lzw.obj" \
+ $(INTDIR)/"tif_zip.obj" \
+ $(INTDIR)/"tif_read.obj" \
+ $(INTDIR)/"tif_packbits.obj" \
+ $(INTDIR)/"tif_swab.obj" \
+ $(INTDIR)/"tif_dirwrite.obj" \
+ $(INTDIR)/"tif_open.obj" \
+ $(INTDIR)/"tif_warning.obj" \
+ $(INTDIR)/"tif_tile.obj" \
+ $(INTDIR)/"tif_strip.obj" \
+ $(INTDIR)/"tif_next.obj" \
+ $(INTDIR)/"tif_write.obj" \
+ $(INTDIR)/"fax3sm.obj"
+
+$(OUTDIR)/"libtiff.lib" : $(OUTDIR) $(DEF_FILE) $(LIB32_OBJS)
+ $(LIB32) @<<
+ $(LIB32_FLAGS) $(DEF_FLAGS) $(LIB32_OBJS)
+<<
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "WinDebug"
+# PROP BASE Intermediate_Dir "WinDebug"
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "WinDebug"
+# PROP Intermediate_Dir "WinDebug"
+OUTDIR=.\WinDebug
+INTDIR=.\WinDebug
+
+ALL : $(OUTDIR)/""dlibtiff.lib"" $(OUTDIR)/""libtiff.bsc""
+
+$(OUTDIR) :
+ if not exist $(OUTDIR)/nul mkdir $(OUTDIR)
+
+CPP=cl.exe
+# ADD BASE CPP /nologo /W3 /GX /Z7 /YX /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FR /c
+# ADD CPP /nologo /MT /W3 /GX /Z7 /YX /Od /I "." /I ".." /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FAs /FR /c
+CPP_PROJ=/nologo /MT /W3 /GX /Z7 /YX /Od /I "." /I ".." /D "WIN32" /D "_DEBUG"\
+ /D "_WINDOWS" /FAs /Fa$(INTDIR)/ /FR$(INTDIR)/ /Fp$(OUTDIR)/"libtiff.pch"\
+ /Fo$(INTDIR)/ /c
+CPP_OBJS=.\WinDebug/
+
+.c{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cpp{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cxx{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+BSC32_FLAGS=/nologo /o$(OUTDIR)/"libtiff.bsc"
+BSC32_SBRS= \
+ $(INTDIR)/"tif_jpeg.sbr" \
+ $(INTDIR)/"tif_dirinfo.sbr" \
+ $(INTDIR)/"tif_win32.sbr" \
+ $(INTDIR)/"tif_flush.sbr" \
+ $(INTDIR)/"tif_thunder.sbr" \
+ $(INTDIR)/"tif_compress.sbr" \
+ $(INTDIR)/"tif_print.sbr" \
+ $(INTDIR)/"tif_dirread.sbr" \
+ $(INTDIR)/"tif_getimage.sbr" \
+ $(INTDIR)/"tif_fax3.sbr" \
+ $(INTDIR)/"tif_version.sbr" \
+ $(INTDIR)/"tif_codec.sbr" \
+ $(INTDIR)/"tif_dir.sbr" \
+ $(INTDIR)/"tif_predict.sbr" \
+ $(INTDIR)/"tif_close.sbr" \
+ $(INTDIR)/"tif_dumpmode.sbr" \
+ $(INTDIR)/"tif_aux.sbr" \
+ $(INTDIR)/"tif_error.sbr" \
+ $(INTDIR)/"tif_lzw.sbr" \
+ $(INTDIR)/"tif_zip.sbr" \
+ $(INTDIR)/"tif_read.sbr" \
+ $(INTDIR)/"tif_packbits.sbr" \
+ $(INTDIR)/"tif_swab.sbr" \
+ $(INTDIR)/"tif_dirwrite.sbr" \
+ $(INTDIR)/"tif_open.sbr" \
+ $(INTDIR)/"tif_warning.sbr" \
+ $(INTDIR)/"tif_tile.sbr" \
+ $(INTDIR)/"tif_strip.sbr" \
+ $(INTDIR)/"tif_next.sbr" \
+ $(INTDIR)/"tif_write.sbr" \
+ $(INTDIR)/"fax3sm.sbr"
+
+$(OUTDIR)/"libtiff.bsc" : $(OUTDIR) $(BSC32_SBRS)
+ $(BSC32) @<<
+ $(BSC32_FLAGS) $(BSC32_SBRS)
+<<
+
+LIB32=lib.exe
+# ADD BASE LIB32 /NOLOGO
+# ADD LIB32 /NOLOGO /OUT:"WinDebug\dlibtiff.lib"
+LIB32_FLAGS=/NOLOGO /OUT:"WinDebug\dlibtiff.lib"
+DEF_FLAGS=
+DEF_FILE=
+LIB32_OBJS= \
+ $(INTDIR)/"tif_jpeg.obj" \
+ $(INTDIR)/"tif_dirinfo.obj" \
+ $(INTDIR)/"tif_win32.obj" \
+ $(INTDIR)/"tif_flush.obj" \
+ $(INTDIR)/"tif_thunder.obj" \
+ $(INTDIR)/"tif_compress.obj" \
+ $(INTDIR)/"tif_print.obj" \
+ $(INTDIR)/"tif_dirread.obj" \
+ $(INTDIR)/"tif_getimage.obj" \
+ $(INTDIR)/"tif_fax3.obj" \
+ $(INTDIR)/"tif_version.obj" \
+ $(INTDIR)/"tif_codec.obj" \
+ $(INTDIR)/"tif_dir.obj" \
+ $(INTDIR)/"tif_predict.obj" \
+ $(INTDIR)/"tif_close.obj" \
+ $(INTDIR)/"tif_dumpmode.obj" \
+ $(INTDIR)/"tif_aux.obj" \
+ $(INTDIR)/"tif_error.obj" \
+ $(INTDIR)/"tif_lzw.obj" \
+ $(INTDIR)/"tif_zip.obj" \
+ $(INTDIR)/"tif_read.obj" \
+ $(INTDIR)/"tif_packbits.obj" \
+ $(INTDIR)/"tif_swab.obj" \
+ $(INTDIR)/"tif_dirwrite.obj" \
+ $(INTDIR)/"tif_open.obj" \
+ $(INTDIR)/"tif_warning.obj" \
+ $(INTDIR)/"tif_tile.obj" \
+ $(INTDIR)/"tif_strip.obj" \
+ $(INTDIR)/"tif_next.obj" \
+ $(INTDIR)/"tif_write.obj" \
+ $(INTDIR)/"fax3sm.obj"
+
+$(OUTDIR)/"dlibtiff.lib" : $(OUTDIR) $(DEF_FILE) $(LIB32_OBJS)
+ $(LIB32) @<<
+ $(LIB32_FLAGS) $(DEF_FLAGS) $(LIB32_OBJS)
+<<
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "MacRel"
+# PROP BASE Intermediate_Dir "MacRel"
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "MacRel"
+# PROP Intermediate_Dir "MacRel"
+OUTDIR=.\MacRel
+INTDIR=.\MacRel
+
+ALL : $(OUTDIR)/""libtiff.lib"" $(OUTDIR)/""libtiff.bsc""
+
+$(OUTDIR) :
+ if not exist $(OUTDIR)/nul mkdir $(OUTDIR)
+
+CPP=cl.exe
+# ADD BASE CPP /nologo /AL /W3 /GX /YX /O2 /D "_WINDOWS" /D "_MAC" /D "_68K_" /D "NDEBUG" /FR /c
+# ADD CPP /nologo /AL /W3 /GX /YX /O2 /D "_WINDOWS" /D "_MAC" /D "_68K_" /D "NDEBUG" /FR /c
+CPP_PROJ=/nologo /AL /W3 /GX /YX /O2 /D "_WINDOWS" /D "_MAC" /D "_68K_" /D\
+ "NDEBUG" /FR$(INTDIR)/ /Fp$(OUTDIR)/"libtiff.pch" /Fo$(INTDIR)/ /c
+CPP_OBJS=.\MacRel/
+
+.c{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cpp{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cxx{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+BSC32_FLAGS=/nologo /o$(OUTDIR)/"libtiff.bsc"
+BSC32_SBRS= \
+ $(INTDIR)/"tif_jpeg.sbr" \
+ $(INTDIR)/"tif_dirinfo.sbr" \
+ $(INTDIR)/"tif_win32.sbr" \
+ $(INTDIR)/"tif_flush.sbr" \
+ $(INTDIR)/"tif_thunder.sbr" \
+ $(INTDIR)/"tif_compress.sbr" \
+ $(INTDIR)/"tif_print.sbr" \
+ $(INTDIR)/"tif_dirread.sbr" \
+ $(INTDIR)/"tif_getimage.sbr" \
+ $(INTDIR)/"tif_fax3.sbr" \
+ $(INTDIR)/"tif_version.sbr" \
+ $(INTDIR)/"tif_codec.sbr" \
+ $(INTDIR)/"tif_dir.sbr" \
+ $(INTDIR)/"tif_predict.sbr" \
+ $(INTDIR)/"tif_close.sbr" \
+ $(INTDIR)/"tif_dumpmode.sbr" \
+ $(INTDIR)/"tif_aux.sbr" \
+ $(INTDIR)/"tif_error.sbr" \
+ $(INTDIR)/"tif_lzw.sbr" \
+ $(INTDIR)/"tif_zip.sbr" \
+ $(INTDIR)/"tif_read.sbr" \
+ $(INTDIR)/"tif_packbits.sbr" \
+ $(INTDIR)/"tif_swab.sbr" \
+ $(INTDIR)/"tif_dirwrite.sbr" \
+ $(INTDIR)/"tif_open.sbr" \
+ $(INTDIR)/"tif_warning.sbr" \
+ $(INTDIR)/"tif_tile.sbr" \
+ $(INTDIR)/"tif_strip.sbr" \
+ $(INTDIR)/"tif_next.sbr" \
+ $(INTDIR)/"tif_write.sbr" \
+ $(INTDIR)/"fax3sm.sbr"
+
+$(OUTDIR)/"libtiff.bsc" : $(OUTDIR) $(BSC32_SBRS)
+ $(BSC32) @<<
+ $(BSC32_FLAGS) $(BSC32_SBRS)
+<<
+
+LIB32=lib.exe
+# ADD BASE LIB32 /NOLOGO
+# ADD LIB32 /NOLOGO
+LIB32_FLAGS=/NOLOGO /OUT:$(OUTDIR)\"libtiff.lib"
+DEF_FLAGS=
+DEF_FILE=
+LIB32_OBJS= \
+ $(INTDIR)/"tif_jpeg.obj" \
+ $(INTDIR)/"tif_dirinfo.obj" \
+ $(INTDIR)/"tif_win32.obj" \
+ $(INTDIR)/"tif_flush.obj" \
+ $(INTDIR)/"tif_thunder.obj" \
+ $(INTDIR)/"tif_compress.obj" \
+ $(INTDIR)/"tif_print.obj" \
+ $(INTDIR)/"tif_dirread.obj" \
+ $(INTDIR)/"tif_getimage.obj" \
+ $(INTDIR)/"tif_fax3.obj" \
+ $(INTDIR)/"tif_version.obj" \
+ $(INTDIR)/"tif_codec.obj" \
+ $(INTDIR)/"tif_dir.obj" \
+ $(INTDIR)/"tif_predict.obj" \
+ $(INTDIR)/"tif_close.obj" \
+ $(INTDIR)/"tif_dumpmode.obj" \
+ $(INTDIR)/"tif_aux.obj" \
+ $(INTDIR)/"tif_error.obj" \
+ $(INTDIR)/"tif_lzw.obj" \
+ $(INTDIR)/"tif_zip.obj" \
+ $(INTDIR)/"tif_read.obj" \
+ $(INTDIR)/"tif_packbits.obj" \
+ $(INTDIR)/"tif_swab.obj" \
+ $(INTDIR)/"tif_dirwrite.obj" \
+ $(INTDIR)/"tif_open.obj" \
+ $(INTDIR)/"tif_warning.obj" \
+ $(INTDIR)/"tif_tile.obj" \
+ $(INTDIR)/"tif_strip.obj" \
+ $(INTDIR)/"tif_next.obj" \
+ $(INTDIR)/"tif_write.obj" \
+ $(INTDIR)/"fax3sm.obj"
+
+$(OUTDIR)/"libtiff.lib" : $(OUTDIR) $(DEF_FILE) $(LIB32_OBJS)
+ $(LIB32) @<<
+ $(LIB32_FLAGS) $(DEF_FLAGS) $(LIB32_OBJS)
+<<
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "MacDebug"
+# PROP BASE Intermediate_Dir "MacDebug"
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "MacDebug"
+# PROP Intermediate_Dir "MacDebug"
+OUTDIR=.\MacDebug
+INTDIR=.\MacDebug
+
+ALL : $(OUTDIR)/""libtiff.lib"" $(OUTDIR)/""libtiff.bsc""
+
+$(OUTDIR) :
+ if not exist $(OUTDIR)/nul mkdir $(OUTDIR)
+
+CPP=cl.exe
+# ADD BASE CPP /nologo /AL /Q68m /W3 /GX /Z7 /YX /Od /D "_WINDOWS" /D "_MAC" /D "_68K_" /D "_DEBUG" /FR /c
+# ADD CPP /nologo /AL /Q68m /W3 /GX /Z7 /YX /Od /D "_WINDOWS" /D "_MAC" /D "_68K_" /D "_DEBUG" /FR /c
+CPP_PROJ=/nologo /AL /Q68m /W3 /GX /Z7 /YX /Od /D "_WINDOWS" /D "_MAC" /D\
+ "_68K_" /D "_DEBUG" /FR$(INTDIR)/ /Fp$(OUTDIR)/"libtiff.pch" /Fo$(INTDIR)/ /c
+CPP_OBJS=.\MacDebug/
+
+.c{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cpp{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cxx{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+BSC32_FLAGS=/nologo /o$(OUTDIR)/"libtiff.bsc"
+BSC32_SBRS= \
+ $(INTDIR)/"tif_jpeg.sbr" \
+ $(INTDIR)/"tif_dirinfo.sbr" \
+ $(INTDIR)/"tif_win32.sbr" \
+ $(INTDIR)/"tif_flush.sbr" \
+ $(INTDIR)/"tif_thunder.sbr" \
+ $(INTDIR)/"tif_compress.sbr" \
+ $(INTDIR)/"tif_print.sbr" \
+ $(INTDIR)/"tif_dirread.sbr" \
+ $(INTDIR)/"tif_getimage.sbr" \
+ $(INTDIR)/"tif_fax3.sbr" \
+ $(INTDIR)/"tif_version.sbr" \
+ $(INTDIR)/"tif_codec.sbr" \
+ $(INTDIR)/"tif_dir.sbr" \
+ $(INTDIR)/"tif_predict.sbr" \
+ $(INTDIR)/"tif_close.sbr" \
+ $(INTDIR)/"tif_dumpmode.sbr" \
+ $(INTDIR)/"tif_aux.sbr" \
+ $(INTDIR)/"tif_error.sbr" \
+ $(INTDIR)/"tif_lzw.sbr" \
+ $(INTDIR)/"tif_zip.sbr" \
+ $(INTDIR)/"tif_read.sbr" \
+ $(INTDIR)/"tif_packbits.sbr" \
+ $(INTDIR)/"tif_swab.sbr" \
+ $(INTDIR)/"tif_dirwrite.sbr" \
+ $(INTDIR)/"tif_open.sbr" \
+ $(INTDIR)/"tif_warning.sbr" \
+ $(INTDIR)/"tif_tile.sbr" \
+ $(INTDIR)/"tif_strip.sbr" \
+ $(INTDIR)/"tif_next.sbr" \
+ $(INTDIR)/"tif_write.sbr" \
+ $(INTDIR)/"fax3sm.sbr"
+
+$(OUTDIR)/"libtiff.bsc" : $(OUTDIR) $(BSC32_SBRS)
+ $(BSC32) @<<
+ $(BSC32_FLAGS) $(BSC32_SBRS)
+<<
+
+LIB32=lib.exe
+# ADD BASE LIB32 /NOLOGO
+# ADD LIB32 /NOLOGO
+LIB32_FLAGS=/NOLOGO /OUT:$(OUTDIR)\"libtiff.lib"
+DEF_FLAGS=
+DEF_FILE=
+LIB32_OBJS= \
+ $(INTDIR)/"tif_jpeg.obj" \
+ $(INTDIR)/"tif_dirinfo.obj" \
+ $(INTDIR)/"tif_win32.obj" \
+ $(INTDIR)/"tif_flush.obj" \
+ $(INTDIR)/"tif_thunder.obj" \
+ $(INTDIR)/"tif_compress.obj" \
+ $(INTDIR)/"tif_print.obj" \
+ $(INTDIR)/"tif_dirread.obj" \
+ $(INTDIR)/"tif_getimage.obj" \
+ $(INTDIR)/"tif_fax3.obj" \
+ $(INTDIR)/"tif_version.obj" \
+ $(INTDIR)/"tif_codec.obj" \
+ $(INTDIR)/"tif_dir.obj" \
+ $(INTDIR)/"tif_predict.obj" \
+ $(INTDIR)/"tif_close.obj" \
+ $(INTDIR)/"tif_dumpmode.obj" \
+ $(INTDIR)/"tif_aux.obj" \
+ $(INTDIR)/"tif_error.obj" \
+ $(INTDIR)/"tif_lzw.obj" \
+ $(INTDIR)/"tif_zip.obj" \
+ $(INTDIR)/"tif_read.obj" \
+ $(INTDIR)/"tif_packbits.obj" \
+ $(INTDIR)/"tif_swab.obj" \
+ $(INTDIR)/"tif_dirwrite.obj" \
+ $(INTDIR)/"tif_open.obj" \
+ $(INTDIR)/"tif_warning.obj" \
+ $(INTDIR)/"tif_tile.obj" \
+ $(INTDIR)/"tif_strip.obj" \
+ $(INTDIR)/"tif_next.obj" \
+ $(INTDIR)/"tif_write.obj" \
+ $(INTDIR)/"fax3sm.obj"
+
+$(OUTDIR)/"libtiff.lib" : $(OUTDIR) $(DEF_FILE) $(LIB32_OBJS)
+ $(LIB32) @<<
+ $(LIB32_FLAGS) $(DEF_FLAGS) $(LIB32_OBJS)
+<<
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "APXrel"
+# PROP BASE Intermediate_Dir "APXrel"
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "APXrel"
+# PROP Intermediate_Dir "APXrel"
+OUTDIR=.\APXrel
+INTDIR=.\APXrel
+
+ALL : $(OUTDIR)/"libtiff.lib" $(OUTDIR)/"libtiff.bsc"
+
+$(OUTDIR) :
+ if not exist $(OUTDIR)/nul mkdir $(OUTDIR)
+
+CPP=cl.exe
+# ADD BASE CPP /nologo /ML /Gt0 /W3 /GX /YX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /FR /c
+# ADD CPP /nologo /MT /Gt0 /W3 /GX /YX /O2 /I ".." /I "." /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /FR /c
+CPP_PROJ=/nologo /MT /Gt0 /W3 /GX /YX /O2 /I ".." /I "." /D "WIN32" /D "NDEBUG"\
+ /D "_WINDOWS" /FR$(INTDIR)/ /Fp$(OUTDIR)/"libtiff.pch" /Fo$(INTDIR)/ /c
+CPP_OBJS=.\APXrel/
+
+.c{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cpp{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cxx{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+BSC32_FLAGS=/nologo /o$(OUTDIR)/"libtiff.bsc"
+BSC32_SBRS= \
+ $(INTDIR)/"tif_jpeg.sbr" \
+ $(INTDIR)/"tif_dirinfo.sbr" \
+ $(INTDIR)/"tif_win32.sbr" \
+ $(INTDIR)/"tif_flush.sbr" \
+ $(INTDIR)/"tif_thunder.sbr" \
+ $(INTDIR)/"tif_compress.sbr" \
+ $(INTDIR)/"tif_print.sbr" \
+ $(INTDIR)/"tif_dirread.sbr" \
+ $(INTDIR)/"tif_getimage.sbr" \
+ $(INTDIR)/"tif_fax3.sbr" \
+ $(INTDIR)/"tif_version.sbr" \
+ $(INTDIR)/"tif_codec.sbr" \
+ $(INTDIR)/"tif_dir.sbr" \
+ $(INTDIR)/"tif_predict.sbr" \
+ $(INTDIR)/"tif_close.sbr" \
+ $(INTDIR)/"tif_dumpmode.sbr" \
+ $(INTDIR)/"tif_aux.sbr" \
+ $(INTDIR)/"tif_error.sbr" \
+ $(INTDIR)/"tif_lzw.sbr" \
+ $(INTDIR)/"tif_zip.sbr" \
+ $(INTDIR)/"tif_read.sbr" \
+ $(INTDIR)/"tif_packbits.sbr" \
+ $(INTDIR)/"tif_swab.sbr" \
+ $(INTDIR)/"tif_dirwrite.sbr" \
+ $(INTDIR)/"tif_open.sbr" \
+ $(INTDIR)/"tif_warning.sbr" \
+ $(INTDIR)/"tif_tile.sbr" \
+ $(INTDIR)/"tif_strip.sbr" \
+ $(INTDIR)/"tif_next.sbr" \
+ $(INTDIR)/"tif_write.sbr" \
+ $(INTDIR)/"fax3sm.sbr"
+
+$(OUTDIR)/"libtiff.bsc" : $(OUTDIR) $(BSC32_SBRS)
+ $(BSC32) @<<
+ $(BSC32_FLAGS) $(BSC32_SBRS)
+<<
+
+LIB32=lib.exe
+# ADD BASE LIB32 /NOLOGO
+# ADD LIB32 /NOLOGO
+LIB32_FLAGS=/NOLOGO /OUT:$(OUTDIR)\"libtiff.lib"
+DEF_FLAGS=
+DEF_FILE=
+LIB32_OBJS= \
+ $(INTDIR)/"tif_jpeg.obj" \
+ $(INTDIR)/"tif_dirinfo.obj" \
+ $(INTDIR)/"tif_win32.obj" \
+ $(INTDIR)/"tif_flush.obj" \
+ $(INTDIR)/"tif_thunder.obj" \
+ $(INTDIR)/"tif_compress.obj" \
+ $(INTDIR)/"tif_print.obj" \
+ $(INTDIR)/"tif_dirread.obj" \
+ $(INTDIR)/"tif_getimage.obj" \
+ $(INTDIR)/"tif_fax3.obj" \
+ $(INTDIR)/"tif_version.obj" \
+ $(INTDIR)/"tif_codec.obj" \
+ $(INTDIR)/"tif_dir.obj" \
+ $(INTDIR)/"tif_predict.obj" \
+ $(INTDIR)/"tif_close.obj" \
+ $(INTDIR)/"tif_dumpmode.obj" \
+ $(INTDIR)/"tif_aux.obj" \
+ $(INTDIR)/"tif_error.obj" \
+ $(INTDIR)/"tif_lzw.obj" \
+ $(INTDIR)/"tif_zip.obj" \
+ $(INTDIR)/"tif_read.obj" \
+ $(INTDIR)/"tif_packbits.obj" \
+ $(INTDIR)/"tif_swab.obj" \
+ $(INTDIR)/"tif_dirwrite.obj" \
+ $(INTDIR)/"tif_open.obj" \
+ $(INTDIR)/"tif_warning.obj" \
+ $(INTDIR)/"tif_tile.obj" \
+ $(INTDIR)/"tif_strip.obj" \
+ $(INTDIR)/"tif_next.obj" \
+ $(INTDIR)/"tif_write.obj" \
+ $(INTDIR)/"fax3sm.obj"
+
+$(OUTDIR)/"libtiff.lib" : $(OUTDIR) $(DEF_FILE) $(LIB32_OBJS)
+ $(LIB32) @<<
+ $(LIB32_FLAGS) $(DEF_FLAGS) $(LIB32_OBJS)
+<<
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "APXdeb"
+# PROP BASE Intermediate_Dir "APXdeb"
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "APXdeb"
+# PROP Intermediate_Dir "APXdeb"
+OUTDIR=.\APXdeb
+INTDIR=.\APXdeb
+
+ALL : $(OUTDIR)/"dlibtiff.lib" $(OUTDIR)/"libtiff.bsc"
+
+$(OUTDIR) :
+ if not exist $(OUTDIR)/nul mkdir $(OUTDIR)
+
+CPP=cl.exe
+# ADD BASE CPP /nologo /ML /Gt0 /W3 /GX /Z7 /YX /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FR /c
+# ADD CPP /nologo /MT /Gt0 /W3 /GX /Z7 /YX /Od /I ".." /I "." /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FR /c
+CPP_PROJ=/nologo /MT /Gt0 /W3 /GX /Z7 /YX /Od /I ".." /I "." /D "WIN32" /D\
+ "_DEBUG" /D "_WINDOWS" /FR$(INTDIR)/ /Fp$(OUTDIR)/"libtiff.pch" /Fo$(INTDIR)/\
+ /c
+CPP_OBJS=.\APXdeb/
+
+.c{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cpp{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+.cxx{$(CPP_OBJS)}.obj:
+ $(CPP) $(CPP_PROJ) $<
+
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+BSC32_FLAGS=/nologo /o$(OUTDIR)/"libtiff.bsc"
+BSC32_SBRS= \
+ $(INTDIR)/"tif_jpeg.sbr" \
+ $(INTDIR)/"tif_dirinfo.sbr" \
+ $(INTDIR)/"tif_win32.sbr" \
+ $(INTDIR)/"tif_flush.sbr" \
+ $(INTDIR)/"tif_thunder.sbr" \
+ $(INTDIR)/"tif_compress.sbr" \
+ $(INTDIR)/"tif_print.sbr" \
+ $(INTDIR)/"tif_dirread.sbr" \
+ $(INTDIR)/"tif_getimage.sbr" \
+ $(INTDIR)/"tif_fax3.sbr" \
+ $(INTDIR)/"tif_version.sbr" \
+ $(INTDIR)/"tif_codec.sbr" \
+ $(INTDIR)/"tif_dir.sbr" \
+ $(INTDIR)/"tif_predict.sbr" \
+ $(INTDIR)/"tif_close.sbr" \
+ $(INTDIR)/"tif_dumpmode.sbr" \
+ $(INTDIR)/"tif_aux.sbr" \
+ $(INTDIR)/"tif_error.sbr" \
+ $(INTDIR)/"tif_lzw.sbr" \
+ $(INTDIR)/"tif_zip.sbr" \
+ $(INTDIR)/"tif_read.sbr" \
+ $(INTDIR)/"tif_packbits.sbr" \
+ $(INTDIR)/"tif_swab.sbr" \
+ $(INTDIR)/"tif_dirwrite.sbr" \
+ $(INTDIR)/"tif_open.sbr" \
+ $(INTDIR)/"tif_warning.sbr" \
+ $(INTDIR)/"tif_tile.sbr" \
+ $(INTDIR)/"tif_strip.sbr" \
+ $(INTDIR)/"tif_next.sbr" \
+ $(INTDIR)/"tif_write.sbr" \
+ $(INTDIR)/"fax3sm.sbr"
+
+$(OUTDIR)/"libtiff.bsc" : $(OUTDIR) $(BSC32_SBRS)
+ $(BSC32) @<<
+ $(BSC32_FLAGS) $(BSC32_SBRS)
+<<
+
+LIB32=lib.exe
+# ADD BASE LIB32 /NOLOGO
+# ADD LIB32 /NOLOGO /OUT:"APXdeb\dlibtiff.lib"
+LIB32_FLAGS=/NOLOGO /OUT:"APXdeb\dlibtiff.lib"
+DEF_FLAGS=
+DEF_FILE=
+LIB32_OBJS= \
+ $(INTDIR)/"tif_jpeg.obj" \
+ $(INTDIR)/"tif_dirinfo.obj" \
+ $(INTDIR)/"tif_win32.obj" \
+ $(INTDIR)/"tif_flush.obj" \
+ $(INTDIR)/"tif_thunder.obj" \
+ $(INTDIR)/"tif_compress.obj" \
+ $(INTDIR)/"tif_print.obj" \
+ $(INTDIR)/"tif_dirread.obj" \
+ $(INTDIR)/"tif_getimage.obj" \
+ $(INTDIR)/"tif_fax3.obj" \
+ $(INTDIR)/"tif_version.obj" \
+ $(INTDIR)/"tif_codec.obj" \
+ $(INTDIR)/"tif_dir.obj" \
+ $(INTDIR)/"tif_predict.obj" \
+ $(INTDIR)/"tif_close.obj" \
+ $(INTDIR)/"tif_dumpmode.obj" \
+ $(INTDIR)/"tif_aux.obj" \
+ $(INTDIR)/"tif_error.obj" \
+ $(INTDIR)/"tif_lzw.obj" \
+ $(INTDIR)/"tif_zip.obj" \
+ $(INTDIR)/"tif_read.obj" \
+ $(INTDIR)/"tif_packbits.obj" \
+ $(INTDIR)/"tif_swab.obj" \
+ $(INTDIR)/"tif_dirwrite.obj" \
+ $(INTDIR)/"tif_open.obj" \
+ $(INTDIR)/"tif_warning.obj" \
+ $(INTDIR)/"tif_tile.obj" \
+ $(INTDIR)/"tif_strip.obj" \
+ $(INTDIR)/"tif_next.obj" \
+ $(INTDIR)/"tif_write.obj" \
+ $(INTDIR)/"fax3sm.obj"
+
+$(OUTDIR)/"dlibtiff.lib" : $(OUTDIR) $(DEF_FILE) $(LIB32_OBJS)
+ $(LIB32) @<<
+ $(LIB32_FLAGS) $(DEF_FLAGS) $(LIB32_OBJS)
+<<
+
+!ENDIF
+
+################################################################################
+# Begin Group "Source Files"
+
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_jpeg.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_jpeg.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_jpeg.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_jpeg.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_jpeg.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_jpeg.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_jpeg.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_dirinfo.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_dirinfo.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_dirinfo.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_dirinfo.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_dirinfo.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_dirinfo.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_dirinfo.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_win32.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_win32.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_win32.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_win32.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_win32.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_win32.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_win32.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_flush.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_flush.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_flush.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_flush.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_flush.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_flush.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_flush.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_thunder.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_thunder.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_thunder.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_thunder.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_thunder.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_thunder.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_thunder.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_compress.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_compress.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_compress.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_compress.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_compress.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_compress.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_compress.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_print.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_print.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_print.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_print.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_print.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_print.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_print.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_dirread.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_dirread.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_dirread.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_dirread.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_dirread.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_dirread.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_dirread.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_getimage.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_getimage.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_getimage.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_getimage.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_getimage.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_getimage.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_getimage.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_fax3.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_fax3.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_fax3.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_fax3.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_fax3.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_fax3.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_fax3.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_version.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_version.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_version.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_version.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_version.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_version.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_version.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_codec.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_codec.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_codec.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_codec.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_codec.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_codec.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_codec.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_dir.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_dir.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_dir.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_dir.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_dir.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_dir.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_dir.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_predict.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_predict.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_predict.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_predict.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_predict.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_predict.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_predict.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_close.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_close.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_close.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_close.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_close.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_close.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_close.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_dumpmode.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_dumpmode.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_dumpmode.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_dumpmode.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_dumpmode.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_dumpmode.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_dumpmode.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_aux.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_aux.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_aux.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_aux.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_aux.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_aux.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_aux.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_error.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_error.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_error.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_error.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_error.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_error.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_error.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_lzw.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_lzw.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_lzw.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_lzw.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_lzw.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_lzw.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_lzw.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_zip.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_zip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_zip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_zip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_zip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_zip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_zip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_read.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_read.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_read.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_read.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_read.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_read.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_read.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_packbits.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_packbits.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_packbits.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_packbits.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_packbits.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_packbits.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_packbits.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_swab.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_swab.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_swab.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_swab.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_swab.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_swab.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_swab.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_dirwrite.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_dirwrite.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_dirwrite.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_dirwrite.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_dirwrite.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_dirwrite.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_dirwrite.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_open.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_open.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_open.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_open.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_open.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_open.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_open.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_warning.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_warning.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_warning.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_warning.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_warning.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_warning.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_warning.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE=.\libtiff.def
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_tile.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_tile.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_tile.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_tile.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_tile.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_tile.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_tile.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_strip.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_strip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_strip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_strip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_strip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_strip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_strip.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_next.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_next.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_next.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_next.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_next.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_next.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_next.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE="\tiff\tiff-v3.4beta024\libtiff\tif_write.c"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"tif_write.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"tif_write.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"tif_write.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"tif_write.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"tif_write.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"tif_write.obj" : $(SOURCE) $(INTDIR)
+ $(CPP) $(CPP_PROJ) $(SOURCE)
+
+!ENDIF
+
+# End Source File
+################################################################################
+# Begin Source File
+
+SOURCE=.\fax3sm.c
+DEP_FAX3S=\
+ "\tiff\tiff-v3.4beta024\libtiff\tiff.h"\
+ "\tiff\tiff-v3.4beta024\libtiff\tif_fax3.h"
+
+!IF "$(CFG)" == "Win32 Release"
+
+$(INTDIR)/"fax3sm.obj" : $(SOURCE) $(DEP_FAX3S) $(INTDIR)
+
+!ELSEIF "$(CFG)" == "Win32 Debug"
+
+$(INTDIR)/"fax3sm.obj" : $(SOURCE) $(DEP_FAX3S) $(INTDIR)
+
+!ELSEIF "$(CFG)" == "Macintosh Release"
+
+$(INTDIR)/"fax3sm.obj" : $(SOURCE) $(DEP_FAX3S) $(INTDIR)
+
+!ELSEIF "$(CFG)" == "Macintosh Debug"
+
+$(INTDIR)/"fax3sm.obj" : $(SOURCE) $(DEP_FAX3S) $(INTDIR)
+
+!ELSEIF "$(CFG)" == "APXrel"
+
+$(INTDIR)/"fax3sm.obj" : $(SOURCE) $(DEP_FAX3S) $(INTDIR)
+
+!ELSEIF "$(CFG)" == "APXdeb"
+
+$(INTDIR)/"fax3sm.obj" : $(SOURCE) $(DEP_FAX3S) $(INTDIR)
+
+!ENDIF
+
+# End Source File
+# End Group
+# End Project
+################################################################################
diff --git a/contrib/winnt/libtiff.vcp b/contrib/winnt/libtiff.vcp
new file mode 100644
index 00000000..4c63936d
--- /dev/null
+++ b/contrib/winnt/libtiff.vcp
Binary files differ
diff --git a/contrib/winnt/version.h b/contrib/winnt/version.h
new file mode 100644
index 00000000..11b9435c
--- /dev/null
+++ b/contrib/winnt/version.h
@@ -0,0 +1 @@
+#define VERSION "LIBTIFF, Version 3.4beta024\nCopyright (c) 1988-1995 Sam Leffler\nCopyright (c) 1991-1995 Silicon Graphics, Inc."
diff --git a/dist/newversion b/dist/newversion
index cea07c5f..22a5d294 100644
--- a/dist/newversion
+++ b/dist/newversion
@@ -1,10 +1,10 @@
#! /bin/sh
-# $Header: /usr/people/sam/tiff/dist/RCS/newversion,v 1.1 1994/12/17 18:27:58 sam Exp $
+# $Header: /usr/people/sam/tiff/dist/RCS/newversion,v 1.2 1996/01/10 19:37:40 sam Exp $
#
# TIFF Software
#
-# Copyright (c) 1994, 1995 Sam Leffler
-# Copyright (c) 1994, 1995 Silicon Graphics, Inc.
+# Copyright (c) 1994-1996 Sam Leffler
+# Copyright (c) 1994-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/dist/tiff.alpha b/dist/tiff.alpha
index 0fe3f9f2..3907e4a2 100644
--- a/dist/tiff.alpha
+++ b/dist/tiff.alpha
@@ -1 +1 @@
-define ALPHA 024
+define ALPHA 028
diff --git a/dist/tiff.spec b/dist/tiff.spec
index 4c4c181c..a4efc953 100644
--- a/dist/tiff.spec
+++ b/dist/tiff.spec
@@ -1,9 +1,9 @@
-# $Header: /usr/people/sam/tiff/dist/RCS/tiff.spec,v 1.2 1995/06/28 04:59:00 sam Exp $
+# $Header: /usr/people/sam/tiff/dist/RCS/tiff.spec,v 1.3 1996/01/10 19:37:41 sam Exp $
#
# TIFF Software
#
-# Copyright (c) 1994 Sam Leffler
-# Copyright (c) 1994 Silicon Graphics, Inc.
+# Copyright (c) 1994-1996 Sam Leffler
+# Copyright (c) 1994-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/html/Makefile.in b/html/Makefile.in
index d11bce14..3c7b2909 100644
--- a/html/Makefile.in
+++ b/html/Makefile.in
@@ -1,11 +1,11 @@
-# $Header: /usr/people/sam/tiff/html/RCS/Makefile.in,v 1.5 1995/10/10 16:56:09 sam Exp $
+# $Header: /usr/people/sam/tiff/html/RCS/Makefile.in,v 1.6 1996/01/10 19:36:59 sam Exp $
#
# @WARNING@
#
# Tag Image File Format Library Manual Pages
#
-# Copyright (c) 1991-1995 Sam Leffler
-# Copyright (c) 1991-1995 Silicon Graphics, Inc.
+# Copyright (c) 1991-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/html/index.html b/html/index.html
index a414133d..cc9adf34 100644
--- a/html/index.html
+++ b/html/index.html
@@ -12,7 +12,7 @@ TIFF Software
</H1>
<B>Latest Release</B>: <I>None</I><BR>
-<B>Latest Software</B>: <A HREF="v3.4beta024.html">v3.4beta024</A><BR>
+<B>Latest Software</B>: <A HREF="v3.4beta028.html">v3.4beta028</A><BR>
<B>Master FTP Site</B>: <A HREF="ftp://ftp.sgi.com/graphics/tiff">ftp.sgi.com (192.48.153.1), directory graphics/tiff</A><BR>
<B>Home Page</B>: <A HREF="http://www-mipl.jpl.nasa.gov/~ndr/tiff/">
http://www-mipl.jpl.nasa.gov/~ndr/tiff/</A> <BR>
@@ -81,7 +81,7 @@ the master FTP site listed above.
<ADDRESS>
<A HREF="sam.html">Sam Leffler</A> / <A HREF="mailto:sam@engr.sgi.com">sam@engr.sgi.com</A>.
-Last updated: $Date: 1995/10/10 16:56:09 $
+Last updated: $Date: 1996/01/10 20:27:41 $
</ADDRESS>
</BODY>
diff --git a/libtiff/Makefile.acorn b/libtiff/Makefile.acorn
new file mode 100755
index 00000000..6c0d46b6
--- /dev/null
+++ b/libtiff/Makefile.acorn
@@ -0,0 +1,112 @@
+# Project: LibTIFF
+
+
+# Toolflags:
+CCflags = -c -zo -ffah -depend !Depend -IC:
+C++flags = -c -depend !Depend -IC: -throwback
+Linkflags = -aif -c++ -o $@
+DrLinkflags = -nounused -aif -c++ -o $@
+ObjAsmflags = -throwback -NoCache -depend !Depend
+CMHGflags =
+LibFileflags = -c -o $@
+Squeezeflags = -o $@
+
+
+# Final targets:
+@.o.LIBTIFF: @.o.tif_acorn @.o.tif_aux @.o.tif_close @.o.tif_codec \
+ @.o.tif_compress @.o.tif_dir @.o.tif_dirinfo @.o.tif_dirread @.o.tif_dirwrite @.o.tif_dumpmode \
+ @.o.tif_error @.o.tif_fax3 @.o.tif_flush @.o.tif_getimage @.o.tif_jpeg @.o.tif_lzw \
+ @.o.tif_next @.o.tif_open @.o.tif_packbits @.o.tif_predict @.o.tif_print @.o.tif_read \
+ @.o.tif_strip @.o.tif_swab @.o.tif_thunder @.o.tif_tile @.o.tif_version @.o.tif_warning \
+ @.o.tif_write @.o.tif_zip @.o.tif_fax3sm @.h.version
+ LibFile $(LibFileflags) @.o.tif_acorn @.o.tif_aux @.o.tif_close \
+ @.o.tif_codec @.o.tif_compress @.o.tif_dir @.o.tif_dirinfo @.o.tif_dirread @.o.tif_dirwrite \
+ @.o.tif_dumpmode @.o.tif_error @.o.tif_fax3 @.o.tif_flush @.o.tif_getimage @.o.tif_jpeg \
+ @.o.tif_lzw @.o.tif_next @.o.tif_open @.o.tif_packbits @.o.tif_predict @.o.tif_print \
+ @.o.tif_read @.o.tif_strip @.o.tif_swab @.o.tif_thunder @.o.tif_tile @.o.tif_version \
+ @.o.tif_warning @.o.tif_write @.o.tif_zip @.o.tif_fax3sm
+
+
+# User-editable dependencies:
+@.mkversion: @.o.mkversion C:o.Stubs
+ Link $(linkflags) @.o.mkversion C:o.Stubs
+@.h.version: @.VERSION @.mkversion
+ <Prefix$Dir>.mkversion @.VERSION @.h.version
+@.mkg3states: @.o.mkg3states @.o.getopt C:o.Stubs
+ link $(linkflags) @.o.mkg3states C:o.Stubs @.o.getopt
+@.c.tif_fax3sm: @.mkg3states
+ <Prefix$Dir>.mkg3states -c const @.c.tif_fax3sm
+
+# Static dependencies:
+@.o.tif_acorn: @.c.tif_acorn
+ cc $(ccflags) -o @.o.tif_acorn @.c.tif_acorn
+@.o.tif_aux: @.c.tif_aux
+ cc $(ccflags) -o @.o.tif_aux @.c.tif_aux
+@.o.tif_close: @.c.tif_close
+ cc $(ccflags) -o @.o.tif_close @.c.tif_close
+@.o.tif_codec: @.c.tif_codec
+ cc $(ccflags) -o @.o.tif_codec @.c.tif_codec
+@.o.tif_compress: @.c.tif_compress
+ cc $(ccflags) -o @.o.tif_compress @.c.tif_compress
+@.o.tif_dir: @.c.tif_dir
+ cc $(ccflags) -o @.o.tif_dir @.c.tif_dir
+@.o.tif_dirinfo: @.c.tif_dirinfo
+ cc $(ccflags) -o @.o.tif_dirinfo @.c.tif_dirinfo
+@.o.tif_dirread: @.c.tif_dirread
+ cc $(ccflags) -o @.o.tif_dirread @.c.tif_dirread
+@.o.tif_dirwrite: @.c.tif_dirwrite
+ cc $(ccflags) -o @.o.tif_dirwrite @.c.tif_dirwrite
+@.o.tif_dumpmode: @.c.tif_dumpmode
+ cc $(ccflags) -o @.o.tif_dumpmode @.c.tif_dumpmode
+@.o.tif_error: @.c.tif_error
+ cc $(ccflags) -o @.o.tif_error @.c.tif_error
+@.o.tif_fax3: @.c.tif_fax3
+ cc $(ccflags) -o @.o.tif_fax3 @.c.tif_fax3
+@.o.tif_flush: @.c.tif_flush
+ cc $(ccflags) -o @.o.tif_flush @.c.tif_flush
+@.o.tif_getimage: @.c.tif_getimage
+ cc $(ccflags) -o @.o.tif_getimage @.c.tif_getimage
+@.o.tif_jpeg: @.c.tif_jpeg
+ cc $(ccflags) -o @.o.tif_jpeg @.c.tif_jpeg
+@.o.tif_lzw: @.c.tif_lzw
+ cc $(ccflags) -o @.o.tif_lzw @.c.tif_lzw
+@.o.tif_next: @.c.tif_next
+ cc $(ccflags) -o @.o.tif_next @.c.tif_next
+@.o.tif_open: @.c.tif_open
+ cc $(ccflags) -o @.o.tif_open @.c.tif_open
+@.o.tif_packbits: @.c.tif_packbits
+ cc $(ccflags) -o @.o.tif_packbits @.c.tif_packbits
+@.o.tif_predict: @.c.tif_predict
+ cc $(ccflags) -o @.o.tif_predict @.c.tif_predict
+@.o.tif_print: @.c.tif_print
+ cc $(ccflags) -o @.o.tif_print @.c.tif_print
+@.o.tif_read: @.c.tif_read
+ cc $(ccflags) -o @.o.tif_read @.c.tif_read
+@.o.tif_strip: @.c.tif_strip
+ cc $(ccflags) -o @.o.tif_strip @.c.tif_strip
+@.o.tif_swab: @.c.tif_swab
+ cc $(ccflags) -o @.o.tif_swab @.c.tif_swab
+@.o.tif_thunder: @.c.tif_thunder
+ cc $(ccflags) -o @.o.tif_thunder @.c.tif_thunder
+@.o.tif_tile: @.c.tif_tile
+ cc $(ccflags) -o @.o.tif_tile @.c.tif_tile
+@.o.tif_version: @.c.tif_version
+ cc $(ccflags) -o @.o.tif_version @.c.tif_version
+@.o.tif_warning: @.c.tif_warning
+ cc $(ccflags) -o @.o.tif_warning @.c.tif_warning
+@.o.tif_write: @.c.tif_write
+ cc $(ccflags) -o @.o.tif_write @.c.tif_write
+@.o.tif_zip: @.c.tif_zip
+ cc $(ccflags) -o @.o.tif_zip @.c.tif_zip
+@.o.mkg3states: @.c.mkg3states
+ cc $(ccflags) -o @.o.mkg3states @.c.mkg3states
+@.o.getopt: @.c.getopt
+ cc $(ccflags) -o @.o.getopt @.c.getopt
+@.o.mkspans: @.c.mkspans
+ cc $(ccflags) -o @.o.mkspans @.c.mkspans
+@.o.tif_fax3sm: @.c.tif_fax3sm
+ cc $(ccflags) -o @.o.tif_fax3sm @.c.tif_fax3sm
+@.o.mkversion: @.c.mkversion
+ cc $(ccflags) -o @.o.mkversion @.c.mkversion
+
+# Dynamic dependencies:
diff --git a/libtiff/Makefile.in b/libtiff/Makefile.in
index 5915b504..c7b9491f 100644
--- a/libtiff/Makefile.in
+++ b/libtiff/Makefile.in
@@ -1,9 +1,9 @@
-# $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.in,v 1.24 1995/10/16 19:15:09 sam Exp $
+# $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.in,v 1.27 1996/01/10 19:35:01 sam Exp $
#
# Tag Image File Format Library
#
-# Copyright (c) 1988-1995 Sam Leffler
-# Copyright (c) 1991-1995 Silicon Graphics, Inc.
+# Copyright (c) 1988-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
@@ -259,10 +259,10 @@ installDSO: @DSO@dso
install: all installHdrs
${INSTALL} -idb tiff.sw.dev -m 755 -dir @DIR_LIB@
${INSTALL} -idb tiff.sw.dev -m 444 -F @DIR_LIB@ -O libtiff.a
- if [ @DSO@dso != dso ]; then \
+ if [ @DSO@dso != nodso ]; then \
${MAKE} installDSO; \
fi
clean:
rm -f ${TARGETS} ${OBJS} core a.out mkg3states tif_fax3sm.c version.h \
- libtiff.@DSOSUF@ *dso
+ libtiff.@DSOSUF@ *dso mkversion
diff --git a/libtiff/Makefile.lcc b/libtiff/Makefile.lcc
index 5da688da..46f8cbce 100644
--- a/libtiff/Makefile.lcc
+++ b/libtiff/Makefile.lcc
@@ -1,9 +1,9 @@
-# $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.lcc,v 1.2 1994/11/28 06:13:31 sam Exp $
+# $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.lcc,v 1.3 1996/01/10 19:32:51 sam Exp $
#
# Tag Image File Format Library
#
-# Copyright (c) 1988, 1989, 1990, 1991, 1992 Sam Leffler
-# Copyright (c) 1991, 1992 Silicon Graphics, Inc.
+# Copyright (c) 1988-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/Makefile.msc b/libtiff/Makefile.msc
index f1c9e30f..16935189 100644
--- a/libtiff/Makefile.msc
+++ b/libtiff/Makefile.msc
@@ -1,9 +1,9 @@
-# $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.msc,v 1.2 1994/11/28 06:13:31 sam Exp $
+# $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.msc,v 1.3 1996/01/10 19:32:51 sam Exp $
#
# Tag Image File Format Library
#
-# Copyright (c) 1988, 1989, 1990, 1991, 1992 Sam Leffler
-# Copyright (c) 1991, 1992 Silicon Graphics, Inc.
+# Copyright (c) 1988-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/mkg3states.c b/libtiff/mkg3states.c
index 50ab6099..dc477afb 100644
--- a/libtiff/mkg3states.c
+++ b/libtiff/mkg3states.c
@@ -1,8 +1,8 @@
-/* "$Header: /usr/people/sam/tiff/libtiff/RCS/mkg3states.c,v 1.33 1995/10/16 19:14:33 sam Exp $ */
+/* "$Header: /usr/people/sam/tiff/libtiff/RCS/mkg3states.c,v 1.34 1996/01/10 19:32:52 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/mkspans.c b/libtiff/mkspans.c
index 9ab069e6..6a4fe312 100644
--- a/libtiff/mkspans.c
+++ b/libtiff/mkspans.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/mkspans.c,v 1.9 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/mkspans.c,v 1.10 1996/01/10 19:32:53 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/mkversion.c b/libtiff/mkversion.c
index b31e5d87..674ba87a 100755
--- a/libtiff/mkversion.c
+++ b/libtiff/mkversion.c
@@ -1,8 +1,8 @@
-/* "$Header: /usr/people/sam/tiff/libtiff/RCS/mkversion.c,v 1.2 1995/10/16 19:14:11 sam Exp $ */
+/* "$Header: /usr/people/sam/tiff/libtiff/RCS/mkversion.c,v 1.4 1996/01/10 19:34:25 sam Exp $ */
/*
- * Copyright (c) 1995 Sam Leffler
- * Copyright (c) 1995 Silicon Graphics, Inc.
+ * Copyright (c) 1995-1996 Sam Leffler
+ * Copyright (c) 1995-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -123,8 +123,8 @@ main(int argc, char* argv[])
} else
fd = stdout;
fprintf(fd, "#define VERSION \"LIBTIFF, Version %s\\n", version);
- fprintf(fd, "Copyright (c) 1988-1995 Sam Leffler\\n");
- fprintf(fd, "Copyright (c) 1991-1995 Silicon Graphics, Inc.\"\n");
+ fprintf(fd, "Copyright (c) 1988-1996 Sam Leffler\\n");
+ fprintf(fd, "Copyright (c) 1991-1996 Silicon Graphics, Inc.\"\n");
if (fd != stdout)
fclose(fd);
diff --git a/libtiff/t4.h b/libtiff/t4.h
index ff7d1d10..30dc5aef 100644
--- a/libtiff/t4.h
+++ b/libtiff/t4.h
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/t4.h,v 1.14 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/t4.h,v 1.15 1996/01/10 19:33:20 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_acorn.c b/libtiff/tif_acorn.c
new file mode 100755
index 00000000..40ce58dd
--- /dev/null
+++ b/libtiff/tif_acorn.c
@@ -0,0 +1,519 @@
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_acorn.c,v 1.1 1995/09/06 00:24:10 sam Exp $ */
+
+/*
+ * Copyright (c) 1988-1995 Sam Leffler
+ * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and
+ * its documentation for any purpose is hereby granted without fee, provided
+ * that (i) the above copyright notices and this permission notice appear in
+ * all copies of the software and related documentation, and (ii) the names of
+ * Sam Leffler and Silicon Graphics may not be used in any advertising or
+ * publicity relating to the software without the specific, prior written
+ * permission of Sam Leffler and Silicon Graphics.
+ *
+ * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
+ * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
+ *
+ * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
+ * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
+ * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+ * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF
+ * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+ * OF THIS SOFTWARE.
+ */
+
+/*
+ * TIFF Library RISC OS specific Routines.
+ * Developed out of the Unix version.
+ * Peter Greenham, May 1995
+ */
+#include "tiffiop.h"
+#include <stdio.h>
+#include <stdlib.h>
+
+/*
+Low-level file handling
+~~~~~~~~~~~~~~~~~~~~~~~
+The functions in osfcn.h are unavailable when compiling under C, as it's a
+C++ header. Therefore they have been implemented here.
+
+Now, why have I done it this way?
+
+The definitive API library for RISC OS is Jonathan Coxhead's OSLib, which
+uses heavily optimised ARM assembler or even plain inline SWI calls for
+maximum performance and minimum runtime size. However, I don't want to make
+LIBTIFF need that to survive. Therefore I have also emulated the functions
+using macros to _swi() and _swix() defined in the swis.h header, and
+borrowing types from kernel.h, which is less efficient but doesn't need any
+third-party libraries.
+ */
+
+#ifdef INCLUDE_OSLIB
+
+#include "osfile.h"
+#include "osgbpb.h"
+#include "osargs.h"
+#include "osfind.h"
+
+#else
+
+/* OSLIB EMULATION STARTS */
+
+#include "kernel.h"
+#include "swis.h"
+
+/* From oslib:types.h */
+typedef unsigned int bits;
+typedef unsigned char byte;
+#ifndef TRUE
+#define TRUE 1
+#endif
+#ifndef FALSE
+#define FALSE 0
+#endif
+#ifndef NULL
+#define NULL 0
+#endif
+#ifndef SKIP
+#define SKIP 0
+#endif
+
+/* From oslib:os.h */
+typedef _kernel_oserror os_error;
+typedef byte os_f;
+
+/* From oslib:osfile.h */
+#undef OS_File
+#define OS_File 0x8
+
+/* From oslib:osgbpb.h */
+#undef OS_GBPB
+#define OS_GBPB 0xC
+#undef OSGBPB_Write
+#define OSGBPB_Write 0x2
+#undef OSGBPB_Read
+#define OSGBPB_Read 0x4
+
+extern os_error *xosgbpb_write (os_f file,
+ byte *data,
+ int size,
+ int *unwritten);
+extern int osgbpb_write (os_f file,
+ byte *data,
+ int size);
+
+#define xosgbpb_write(file, data, size, unwritten) \
+ (os_error*) _swix(OS_GBPB, _IN(0)|_IN(1)|_IN(2)|_IN(3)|_IN(4)|_OUT(3), \
+ OSGBPB_WriteAt, \
+ file, \
+ data, \
+ size, \
+ unwritten)
+
+#define osgbpb_write(file, data, size) \
+ _swi(OS_GBPB, _IN(0)|_IN(1)|_IN(2)|_IN(3)|_RETURN(3), \
+ OSGBPB_Write, \
+ file, \
+ data, \
+ size)
+
+extern os_error *xosgbpb_read (os_f file,
+ byte *buffer,
+ int size,
+ int *unread);
+extern int osgbpb_read (os_f file,
+ byte *buffer,
+ int size);
+
+#define xosgbpb_read(file, buffer, size, unread) \
+ (os_error*) _swix(OS_GBPB, _IN(0)|_IN(1)|_IN(2)|_IN(3)|_OUT(3), \
+ OSGBPB_Read, \
+ file, \
+ buffer, \
+ size, \
+ unread)
+
+#define osgbpb_read(file, buffer, size) \
+ _swi(OS_GBPB, _IN(0)|_IN(1)|_IN(2)|_IN(3)|_RETURN(3), \
+ OSGBPB_Read, \
+ file, \
+ buffer, \
+ size)
+
+/* From oslib:osfind.h */
+#undef OS_Find
+#define OS_Find 0xD
+#undef OSFind_Openin
+#define OSFind_Openin 0x40
+#undef OSFind_Openout
+#define OSFind_Openout 0x80
+#undef OSFind_Openup
+#define OSFind_Openup 0xC0
+#undef OSFind_Close
+#define OSFind_Close 0x0
+
+#define xosfind_open(reason, file_name, path, file) \
+ (os_error*) _swix(OS_Find, _IN(0)|_IN(1)|_IN(2)|_OUT(0), \
+ reason, file_name, path, file)
+
+#define osfind_open(reason, file_name, path) \
+ (os_f) _swi(OS_Find, _IN(0)|_IN(1)|_IN(2)|_RETURN(0), \
+ reason, file_name, path)
+
+extern os_error *xosfind_openin (bits flags,
+ char *file_name,
+ char *path,
+ os_f *file);
+extern os_f osfind_openin (bits flags,
+ char *file_name,
+ char *path);
+
+#define xosfind_openin(flags, file_name, path, file) \
+ xosfind_open(flags | OSFind_Openin, file_name, path, file)
+
+#define osfind_openin(flags, file_name, path) \
+ osfind_open(flags | OSFind_Openin, file_name, path)
+
+extern os_error *xosfind_openout (bits flags,
+ char *file_name,
+ char *path,
+ os_f *file);
+extern os_f osfind_openout (bits flags,
+ char *file_name,
+ char *path);
+
+#define xosfind_openout(flags, file_name, path, file) \
+ xosfind_open(flags | OSFind_Openout, file_name, path, file)
+
+#define osfind_openout(flags, file_name, path) \
+ osfind_open(flags | OSFind_Openout, file_name, path)
+
+extern os_error *xosfind_openup (bits flags,
+ char *file_name,
+ char *path,
+ os_f *file);
+extern os_f osfind_openup (bits flags,
+ char *file_name,
+ char *path);
+
+#define xosfind_openup(flags, file_name, path, file) \
+ xosfind_open(flags | OSFind_Openup, file_name, path, file)
+
+#define osfind_openup(flags, file_name, path) \
+ osfind_open(flags | OSFind_Openup, file_name, path)
+
+extern os_error *xosfind_close (os_f file);
+extern void osfind_close (os_f file);
+
+#define xosfind_close(file) \
+ (os_error*) _swix(OS_Find, _IN(0)|_IN(1), \
+ OSFind_Close, \
+ file)
+
+#define osfind_close(file) \
+ (void) _swi(OS_Find, _IN(0)|_IN(1), \
+ OSFind_Close, \
+ file)
+
+/* From oslib:osargs.h */
+#undef OS_Args
+#define OS_Args 0x9
+#undef OSArgs_ReadPtr
+#define OSArgs_ReadPtr 0x0
+#undef OSArgs_SetPtr
+#define OSArgs_SetPtr 0x1
+#undef OSArgs_ReadExt
+#define OSArgs_ReadExt 0x2
+
+extern os_error *xosargs_read_ptr (os_f file,
+ int *ptr);
+extern int osargs_read_ptr (os_f file);
+
+#define xosargs_read_ptr(file, ptr) \
+ (os_error*) _swix(OS_Args, _IN(0)|_IN(1)|_OUT(2), \
+ OSArgs_ReadPtr, \
+ file, \
+ ptr)
+
+#define osargs_read_ptr(file) \
+ _swi(OS_Args, _IN(0)|_IN(1)|_RETURN(2), \
+ OSArgs_ReadPtr, \
+ file)
+
+extern os_error *xosargs_set_ptr (os_f file,
+ int ptr);
+extern void osargs_set_ptr (os_f file,
+ int ptr);
+
+#define xosargs_set_ptr(file, ptr) \
+ (os_error*) _swix(OS_Args, _IN(0)|_IN(1)|_IN(2), \
+ OSArgs_SetPtr, \
+ file, \
+ ptr)
+
+#define osargs_set_ptr(file, ptr) \
+ (void) _swi(OS_Args, _IN(0)|_IN(1)|_IN(2), \
+ OSArgs_SetPtr, \
+ file, \
+ ptr)
+
+extern os_error *xosargs_read_ext (os_f file,
+ int *ext);
+extern int osargs_read_ext (os_f file);
+
+#define xosargs_read_ext(file, ext) \
+ (os_error*) _swix(OS_Args, _IN(0)|_IN(1)|_OUT(2), \
+ OSArgs_ReadExt, \
+ file, \
+ ext)
+
+#define osargs_read_ext(file) \
+ _swi(OS_Args, _IN(0)|_IN(1)|_RETURN(2), \
+ OSArgs_ReadExt, \
+ file)
+
+/* OSLIB EMULATION ENDS */
+
+#endif
+
+#ifndef __osfcn_h
+/* Will be set or not during tiffcomp.h */
+/* You get this to compile under C++? Please say how! */
+
+extern int open(const char* name, int flags, int mode)
+{
+ /* From what I can tell, should return <0 for failure */
+ os_error* e = (os_error*) 1; /* Cheeky way to use a pointer eh? :-) */
+ os_f file = (os_f) -1;
+
+ flags = flags;
+
+ switch(mode)
+ {
+ case O_RDONLY:
+ {
+ e = xosfind_openin(SKIP, name, SKIP, &file);
+ break;
+ }
+ case O_WRONLY:
+ case O_RDWR|O_CREAT:
+ case O_RDWR|O_CREAT|O_TRUNC:
+ {
+ e = xosfind_openout(SKIP, name, SKIP, &file);
+ break;
+ }
+ case O_RDWR:
+ {
+ e = xosfind_openup(SKIP, name, SKIP, &file);
+ break;
+ }
+ }
+ if (e)
+ {
+ file = (os_f) -1;
+ }
+ return (file);
+}
+
+extern int close(int fd)
+{
+ return ((int) xosfind_close((os_f) fd));
+}
+
+extern int write(int fd, const char *buf, int nbytes)
+{
+ /* Returns number of bytes written */
+ return (nbytes - osgbpb_write((os_f) fd, (const byte*) buf, nbytes));
+}
+
+extern int read(int fd, char *buf, int nbytes)
+{
+ /* Returns number of bytes read */
+ return (nbytes - osgbpb_read((os_f) fd, (byte*) buf, nbytes));
+}
+
+extern off_t lseek(int fd, off_t offset, int whence)
+{
+ int absolute = 0;
+
+ switch (whence)
+ {
+ case SEEK_SET:
+ {
+ absolute = (int) offset;
+ break;
+ }
+ case SEEK_CUR:
+ {
+ absolute = osargs_read_ptr((os_f) fd) + (int) offset;
+ break;
+ }
+ case SEEK_END:
+ {
+ absolute = osargs_read_ext((os_f) fd) + (int) offset;
+ break;
+ }
+ }
+
+ osargs_set_ptr((os_f) fd, absolute);
+
+ return ((off_t) osargs_read_ptr((os_f) fd));
+}
+#endif
+
+static tsize_t
+_tiffReadProc(thandle_t fd, tdata_t buf, tsize_t size)
+{
+ return ((tsize_t) read((int) fd, buf, (size_t) size));
+}
+
+static tsize_t
+_tiffWriteProc(thandle_t fd, tdata_t buf, tsize_t size)
+{
+ return ((tsize_t) write((int) fd, buf, (size_t) size));
+}
+
+static toff_t
+_tiffSeekProc(thandle_t fd, toff_t off, int whence)
+{
+ return ((toff_t) lseek((int) fd, (off_t) off, whence));
+}
+
+static int
+_tiffCloseProc(thandle_t fd)
+{
+ return (close((int) fd));
+}
+
+static toff_t
+_tiffSizeProc(thandle_t fd)
+{
+ return (lseek((int) fd, SEEK_END, SEEK_SET));
+}
+
+#ifdef HAVE_MMAP
+#error "I didn't know Acorn had that!"
+#endif
+
+/* !HAVE_MMAP */
+static int
+_tiffMapProc(thandle_t fd, tdata_t* pbase, toff_t* psize)
+{
+ (void) fd; (void) pbase; (void) psize;
+ return (0);
+}
+
+static void
+_tiffUnmapProc(thandle_t fd, tdata_t base, toff_t size)
+{
+ (void) fd; (void) base; (void) size;
+}
+
+/*
+ * Open a TIFF file descriptor for read/writing.
+ */
+TIFF*
+TIFFFdOpen(int fd, const char* name, const char* mode)
+{
+ TIFF* tif;
+
+ tif = TIFFClientOpen(name, mode,
+ (thandle_t) fd,
+ _tiffReadProc, _tiffWriteProc,
+ _tiffSeekProc, _tiffCloseProc, _tiffSizeProc,
+ _tiffMapProc, _tiffUnmapProc);
+ if (tif)
+ {
+ tif->tif_fd = fd;
+ }
+ return (tif);
+}
+
+/*
+ * Open a TIFF file for read/writing.
+ */
+TIFF*
+TIFFOpen(const char* name, const char* mode)
+{
+ static const char module[] = "TIFFOpen";
+ int m, fd;
+
+ m = _TIFFgetMode(mode, module);
+
+ if (m == -1)
+ {
+ return ((TIFF*) 0);
+ }
+
+ fd = open(name, 0, m);
+
+ if (fd < 0)
+ {
+ TIFFError(module, "%s: Cannot open", name);
+ return ((TIFF *)0);
+ }
+ return (TIFFFdOpen(fd, name, mode));
+}
+
+void*
+_TIFFmalloc(tsize_t s)
+{
+ return (malloc((size_t) s));
+}
+
+void
+_TIFFfree(tdata_t p)
+{
+ free(p);
+}
+
+void*
+_TIFFrealloc(tdata_t p, tsize_t s)
+{
+ return (realloc(p, (size_t) s));
+}
+
+void
+_TIFFmemset(tdata_t p, int v, tsize_t c)
+{
+ memset(p, v, (size_t) c);
+}
+
+void
+_TIFFmemcpy(tdata_t d, const tdata_t s, tsize_t c)
+{
+ memcpy(d, s, (size_t) c);
+}
+
+int
+_TIFFmemcmp(const tdata_t p1, const tdata_t p2, tsize_t c)
+{
+ return (memcmp(p1, p2, (size_t) c));
+}
+
+static void
+acornWarningHandler(const char* module, const char* fmt, va_list ap)
+{
+ if (module != NULL)
+ {
+ fprintf(stderr, "%s: ", module);
+ }
+ fprintf(stderr, "Warning, ");
+ vfprintf(stderr, fmt, ap);
+ fprintf(stderr, ".\n");
+}
+TIFFErrorHandler _TIFFwarningHandler = acornWarningHandler;
+
+static void
+acornErrorHandler(const char* module, const char* fmt, va_list ap)
+{
+ if (module != NULL)
+ {
+ fprintf(stderr, "%s: ", module);
+ }
+ vfprintf(stderr, fmt, ap);
+ fprintf(stderr, ".\n");
+}
+TIFFErrorHandler _TIFFerrorHandler = acornErrorHandler;
diff --git a/libtiff/tif_apple.c b/libtiff/tif_apple.c
index c58043e6..519b876f 100644
--- a/libtiff/tif_apple.c
+++ b/libtiff/tif_apple.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_apple.c,v 1.20 1995/10/12 18:29:18 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_apple.c,v 1.21 1996/01/10 19:32:54 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_atari.c b/libtiff/tif_atari.c
index 0826dca5..04966856 100644
--- a/libtiff/tif_atari.c
+++ b/libtiff/tif_atari.c
@@ -1,8 +1,8 @@
-/* "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_atari.c,v 1.4 1995/06/06 23:49:31 sam Exp $" */
+/* "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_atari.c,v 1.5 1996/01/10 19:32:54 sam Exp $" */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_aux.c b/libtiff/tif_aux.c
index 6410916a..debfd382 100644
--- a/libtiff/tif_aux.c
+++ b/libtiff/tif_aux.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_aux.c,v 1.31 1995/07/18 23:13:19 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_aux.c,v 1.32 1996/01/10 19:32:55 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_close.c b/libtiff/tif_close.c
index 9240da18..8f416876 100644
--- a/libtiff/tif_close.c
+++ b/libtiff/tif_close.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_close.c,v 1.29 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_close.c,v 1.30 1996/01/10 19:32:55 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_codec.c b/libtiff/tif_codec.c
index bd946ff1..ec62814b 100644
--- a/libtiff/tif_codec.c
+++ b/libtiff/tif_codec.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_codec.c,v 1.5 1995/10/10 22:22:44 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_codec.c,v 1.7 1996/01/10 19:32:56 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -89,11 +89,19 @@ TIFFCodec _TIFFBuiltinCODECS[] = {
};
static int
-NotConfigured(TIFF* tif, int scheme)
+_notConfigured(TIFF* tif)
{
- const TIFFCodec* c = TIFFFindCODEC(scheme);
-
+ const TIFFCodec* c = TIFFFindCODEC(tif->tif_dir.td_compression);
+
TIFFError(tif->tif_name,
"%s compression support is not configured", c->name);
return (0);
}
+
+static int
+NotConfigured(TIFF* tif, int scheme)
+{
+ tif->tif_setupdecode = _notConfigured;
+ tif->tif_setupencode = _notConfigured;
+ return (1);
+}
diff --git a/libtiff/tif_compress.c b/libtiff/tif_compress.c
index c7a96420..ce99489e 100644
--- a/libtiff/tif_compress.c
+++ b/libtiff/tif_compress.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_compress.c,v 1.49 1995/10/12 16:41:08 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_compress.c,v 1.51 1996/01/10 19:32:57 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -34,9 +34,15 @@
static int
TIFFNoEncode(TIFF* tif, char* method)
{
- const TIFFCodec *c = TIFFFindCODEC(tif->tif_dir.td_compression);
- TIFFError(tif->tif_name,
- "%s %s encoding is not implemented", c->name, method);
+ const TIFFCodec* c = TIFFFindCODEC(tif->tif_dir.td_compression);
+
+ if (c)
+ TIFFError(tif->tif_name, "%s %s encoding is not implemented",
+ c->name, method);
+ else
+ TIFFError(tif->tif_name,
+ "Compression scheme %u %s encoding is not implemented",
+ tif->tif_dir.td_compression, method);
return (-1);
}
@@ -64,9 +70,15 @@ _TIFFNoTileEncode(TIFF* tif, tidata_t pp, tsize_t cc, tsample_t s)
static int
TIFFNoDecode(TIFF* tif, char* method)
{
- const TIFFCodec *c = TIFFFindCODEC(tif->tif_dir.td_compression);
- TIFFError(tif->tif_name,
- "%s %s decoding is not implemented", c->name, method);
+ const TIFFCodec* c = TIFFFindCODEC(tif->tif_dir.td_compression);
+
+ if (c)
+ TIFFError(tif->tif_name, "%s %s decoding is not implemented",
+ c->name, method);
+ else
+ TIFFError(tif->tif_name,
+ "Compression scheme %u %s decoding is not implemented",
+ tif->tif_dir.td_compression, method);
return (-1);
}
@@ -115,12 +127,6 @@ TIFFSetCompressionScheme(TIFF* tif, int scheme)
{
const TIFFCodec *c = TIFFFindCODEC(scheme);
- if (!c) {
- TIFFError(tif->tif_name,
- "Unknown data compression algorithm %u (0x%x)",
- scheme, scheme);
- return (0);
- }
tif->tif_setupdecode = _TIFFtrue;
tif->tif_predecode = _TIFFNoPreCode;
tif->tif_decoderow = _TIFFNoRowDecode;
@@ -138,7 +144,13 @@ TIFFSetCompressionScheme(TIFF* tif, int scheme)
tif->tif_defstripsize = _TIFFDefaultStripSize;
tif->tif_deftilesize = _TIFFDefaultTileSize;
tif->tif_flags &= ~TIFF_NOBITREV;
- return ((*c->init)(tif, scheme));
+ /*
+ * Don't treat an unknown compression scheme as an error.
+ * This permits applications to open files with data that
+ * the library does not have builtin support for, but which
+ * may still be meaningful.
+ */
+ return (c ? (*c->init)(tif, scheme) : 1);
}
/*
diff --git a/libtiff/tif_dir.c b/libtiff/tif_dir.c
index f32d5147..82187349 100644
--- a/libtiff/tif_dir.c
+++ b/libtiff/tif_dir.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dir.c,v 1.151 1995/07/19 00:39:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dir.c,v 1.156 1996/01/10 20:37:08 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -371,8 +371,20 @@ _TIFFVSetField(TIFF* tif, ttag_t tag, va_list ap)
break;
#endif
default:
- TIFFError(tif->tif_name,
- "Internal error, tag value botch, tag \"%s\"",
+ /*
+ * This can happen if multiple images are open with
+ * different codecs which have private tags. The
+ * global tag information table may then have tags
+ * that are valid for one file but not the other.
+ * If the client tries to set a tag that is not valid
+ * for the image's codec then we'll arrive here. This
+ * happens, for example, when tiffcp is used to convert
+ * between compression schemes and codec-specific tags
+ * are blindly copied.
+ */
+ TIFFError("TIFFSetField",
+ "%s: Invalid %stag \"%s\" (not supported by codec)",
+ tif->tif_name, isPseudoTag(tag) ? "pseduo-" : "",
_TIFFFieldWithTag(tif, tag)->field_name);
status = 0;
break;
@@ -407,21 +419,24 @@ badvalue32:
static int
OkToChangeTag(TIFF* tif, ttag_t tag)
{
- if (tag != TIFFTAG_IMAGELENGTH &&
- (tif->tif_flags & TIFF_BEENWRITING)) {
- const TIFFFieldInfo *fip = _TIFFFindFieldInfo(tif, tag, TIFF_ANY);
+ const TIFFFieldInfo* fip = _TIFFFindFieldInfo(tif, tag, TIFF_ANY);
+ if (!fip) { /* unknown tag */
+ TIFFError("TIFFSetField", "%s: Unknown %stag %u",
+ tif->tif_name, isPseudoTag(tag) ? "pseudo-" : "", tag);
+ return (0);
+ }
+ if (tag != TIFFTAG_IMAGELENGTH && (tif->tif_flags & TIFF_BEENWRITING) &&
+ !fip->field_oktochange) {
/*
* Consult info table to see if tag can be changed
* after we've started writing. We only allow changes
* to those tags that don't/shouldn't affect the
* compression and/or format of the data.
*/
- if (fip && !fip->field_oktochange) {
- TIFFError("TIFFSetField",
- "%s: Cannot modify tag \"%s\" while writing",
- tif->tif_name, fip->field_name);
- return (0);
- }
+ TIFFError("TIFFSetField",
+ "%s: Cannot modify tag \"%s\" while writing",
+ tif->tif_name, fip->field_name);
+ return (0);
}
return (1);
}
@@ -667,8 +682,17 @@ _TIFFVGetField(TIFF* tif, ttag_t tag, va_list ap)
break;
#endif
default:
- TIFFError("_TIFFVGetField",
- "Internal error, no value returned for tag \"%s\"",
+ /*
+ * This can happen if multiple images are open with
+ * different codecs which have private tags. The
+ * global tag information table may then have tags
+ * that are valid for one file but not the other.
+ * If the client tries to get a tag that is not valid
+ * for the image's codec then we'll arrive here.
+ */
+ TIFFError("TIFFGetField",
+ "%s: Invalid %stag \"%s\" (not supported by codec)",
+ tif->tif_name, isPseudoTag(tag) ? "pseudo-" : "",
_TIFFFieldWithTag(tif, tag)->field_name);
break;
}
@@ -701,7 +725,7 @@ int
TIFFVGetField(TIFF* tif, ttag_t tag, va_list ap)
{
const TIFFFieldInfo* fip = _TIFFFindFieldInfo(tif, tag, TIFF_ANY);
- return (fip && TIFFFieldSet(tif, fip->field_bit) ?
+ return (fip && (isPseudoTag(tag) || TIFFFieldSet(tif, fip->field_bit)) ?
(*tif->tif_vgetfield)(tif, tag, ap) : 0);
}
diff --git a/libtiff/tif_dir.h b/libtiff/tif_dir.h
index cd94c71f..c2021dfa 100644
--- a/libtiff/tif_dir.h
+++ b/libtiff/tif_dir.h
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dir.h,v 1.2 1995/06/30 05:46:47 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dir.h,v 1.4 1996/01/10 19:33:21 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -167,6 +167,17 @@ typedef struct {
#define FIELD_SUBIFD 49
#define FIELD_CODEC 50 /* base of codec-private tags */
+/*
+ * Pseudo-tags don't normally need field bits since they
+ * are not written to an output file (by definition).
+ * The library also has express logic to always query a
+ * codec for a pseudo-tag so allocating a field bit for
+ * one is a waste. If codec wants to promote the notion
+ * of a pseudo-tag being ``set'' or ``unset'' then it can
+ * do using internal state flags without polluting the
+ * field bit space defined for real tags.
+ */
+#define FIELD_PSEUDO 0
#define FIELD_LAST (32*FIELD_SETLONGS-1)
diff --git a/libtiff/tif_dirinfo.c b/libtiff/tif_dirinfo.c
index 013daa58..ac221244 100644
--- a/libtiff/tif_dirinfo.c
+++ b/libtiff/tif_dirinfo.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirinfo.c,v 1.36 1995/06/30 05:46:47 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirinfo.c,v 1.37 1996/01/10 19:32:58 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_dirread.c b/libtiff/tif_dirread.c
index a88568ef..7df41f81 100644
--- a/libtiff/tif_dirread.c
+++ b/libtiff/tif_dirread.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirread.c,v 1.68 1995/06/30 05:46:47 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirread.c,v 1.70 1996/01/10 19:32:59 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -538,7 +538,8 @@ TIFFReadDirectory(TIFF* tif)
* side effect, however, is that the RowsPerStrip tag
* value may be changed.
*/
- if (td->td_nstrips == 1 && td->td_compression == COMPRESSION_NONE &&
+ if ((tif->tif_flags & TIFF_STRIPCHOP) &&
+ td->td_nstrips == 1 && td->td_compression == COMPRESSION_NONE &&
td->td_tilewidth == td->td_imagewidth)
ChopUpSingleUncompressedStrip(tif);
#endif
diff --git a/libtiff/tif_dirwrite.c b/libtiff/tif_dirwrite.c
index 24bcbc2b..a2bc7da3 100644
--- a/libtiff/tif_dirwrite.c
+++ b/libtiff/tif_dirwrite.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirwrite.c,v 1.52 1995/06/30 05:46:47 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirwrite.c,v 1.54 1996/01/10 19:33:00 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -931,7 +931,7 @@ TIFFLinkDirectory(TIFF* tif)
/*
* First directory, overwrite offset in header.
*/
- tif->tif_header.tiff_diroff = diroff;
+ tif->tif_header.tiff_diroff = (uint32) tif->tif_diroff;
#define HDROFF(f) ((toff_t) &(((TIFFHeader*) 0)->f))
(void) TIFFSeekFile(tif, HDROFF(tiff_diroff), SEEK_SET);
if (!WriteOK(tif, &diroff, sizeof (diroff))) {
diff --git a/libtiff/tif_dumpmode.c b/libtiff/tif_dumpmode.c
index 9007977c..08214652 100644
--- a/libtiff/tif_dumpmode.c
+++ b/libtiff/tif_dumpmode.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dumpmode.c,v 1.39 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_dumpmode.c,v 1.40 1996/01/10 19:33:00 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_error.c b/libtiff/tif_error.c
index 67bf557d..35eb5f76 100644
--- a/libtiff/tif_error.c
+++ b/libtiff/tif_error.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_error.c,v 1.20 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_error.c,v 1.21 1996/01/10 19:33:01 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_fax3.c b/libtiff/tif_fax3.c
index 0533eb77..ea32a3bc 100644
--- a/libtiff/tif_fax3.c
+++ b/libtiff/tif_fax3.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_fax3.c,v 1.129 1995/09/30 18:36:43 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_fax3.c,v 1.133 1996/01/10 19:33:02 sam Exp $ */
/*
- * Copyright (c) 1990-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1990-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -63,6 +63,9 @@ typedef struct {
uint32 badfaxrun; /* BadFaxRun tag */
uint32 badfaxlines; /* BadFaxLines tag */
uint32 groupoptions; /* Group 3/4 options tag */
+ uint32 recvparams; /* encoded Class 2 session params */
+ char* subaddress; /* subaddress string */
+ uint32 recvtime; /* time spent receiving (secs) */
TIFFVGetMethod vgetparent; /* super-class method */
TIFFVSetMethod vsetparent; /* super-class method */
} Fax3BaseState;
@@ -1060,20 +1063,26 @@ Fax3Cleanup(TIFF* tif)
if (sp->refline)
_TIFFfree(sp->refline);
}
+ if (Fax3State(tif)->subaddress)
+ _TIFFfree(Fax3State(tif)->subaddress);
_TIFFfree(tif->tif_data);
tif->tif_data = NULL;
}
}
-#define FIELD_FAXMODE (FIELD_CODEC+0)
-#define FIELD_OPTIONS (FIELD_CODEC+1)
-#define FIELD_BADFAXLINES (FIELD_CODEC+2)
-#define FIELD_CLEANFAXDATA (FIELD_CODEC+3)
-#define FIELD_BADFAXRUN (FIELD_CODEC+4)
+#define FIELD_OPTIONS (FIELD_CODEC+0)
+#define FIELD_BADFAXLINES (FIELD_CODEC+1)
+#define FIELD_CLEANFAXDATA (FIELD_CODEC+2)
+#define FIELD_BADFAXRUN (FIELD_CODEC+3)
+#define FIELD_RECVPARAMS (FIELD_CODEC+4)
+#define FIELD_SUBADDRESS (FIELD_CODEC+5)
+#define FIELD_RECVTIME (FIELD_CODEC+6)
static const TIFFFieldInfo fax3FieldInfo[] = {
- { TIFFTAG_FAXMODE, 0, 0, TIFF_ANY, FIELD_FAXMODE,
- FALSE, FALSE, "" },
+ { TIFFTAG_FAXMODE, 0, 0, TIFF_ANY, FIELD_PSEUDO,
+ FALSE, FALSE, "FaxMode" },
+ { TIFFTAG_FAXFILLFUNC, 0, 0, TIFF_ANY, FIELD_PSEUDO,
+ FALSE, FALSE, "FaxFillFunc" },
{ TIFFTAG_GROUP3OPTIONS, 1, 1, TIFF_LONG, FIELD_OPTIONS,
FALSE, FALSE, "Group3Options" },
{ TIFFTAG_BADFAXLINES, 1, 1, TIFF_LONG, FIELD_BADFAXLINES,
@@ -1086,10 +1095,18 @@ static const TIFFFieldInfo fax3FieldInfo[] = {
TRUE, FALSE, "ConsecutiveBadFaxLines" },
{ TIFFTAG_CONSECUTIVEBADFAXLINES,1,1, TIFF_SHORT, FIELD_BADFAXRUN,
TRUE, FALSE, "ConsecutiveBadFaxLines" },
+ { TIFFTAG_FAXRECVPARAMS, 1, 1, TIFF_LONG, FIELD_RECVPARAMS,
+ TRUE, FALSE, "FaxRecvParams" },
+ { TIFFTAG_FAXSUBADDRESS, -1,-1, TIFF_ASCII, FIELD_SUBADDRESS,
+ TRUE, FALSE, "FaxSubAddress" },
+ { TIFFTAG_FAXRECVTIME, 1, 1, TIFF_LONG, FIELD_RECVTIME,
+ TRUE, FALSE, "FaxRecvTime" },
};
static const TIFFFieldInfo fax4FieldInfo[] = {
- { TIFFTAG_FAXMODE, 0, 0, TIFF_ANY, FIELD_FAXMODE,
- FALSE, FALSE, "" },
+ { TIFFTAG_FAXMODE, 0, 0, TIFF_ANY, FIELD_PSEUDO,
+ FALSE, FALSE, "FaxMode" },
+ { TIFFTAG_FAXFILLFUNC, 0, 0, TIFF_ANY, FIELD_PSEUDO,
+ FALSE, FALSE, "FaxFillFunc" },
{ TIFFTAG_GROUP4OPTIONS, 1, 1, TIFF_LONG, FIELD_OPTIONS,
FALSE, FALSE, "Group4Options" },
{ TIFFTAG_BADFAXLINES, 1, 1, TIFF_LONG, FIELD_BADFAXLINES,
@@ -1102,6 +1119,12 @@ static const TIFFFieldInfo fax4FieldInfo[] = {
TRUE, FALSE, "ConsecutiveBadFaxLines" },
{ TIFFTAG_CONSECUTIVEBADFAXLINES,1,1, TIFF_SHORT, FIELD_BADFAXRUN,
TRUE, FALSE, "ConsecutiveBadFaxLines" },
+ { TIFFTAG_FAXRECVPARAMS, 1, 1, TIFF_LONG, FIELD_RECVPARAMS,
+ TRUE, FALSE, "FaxRecvParams" },
+ { TIFFTAG_FAXSUBADDRESS, -1,-1, TIFF_ASCII, FIELD_SUBADDRESS,
+ TRUE, FALSE, "FaxSubAddress" },
+ { TIFFTAG_FAXRECVTIME, 1, 1, TIFF_LONG, FIELD_RECVTIME,
+ TRUE, FALSE, "FaxRecvTime" },
};
#define N(a) (sizeof (a) / sizeof (a[0]))
@@ -1131,6 +1154,15 @@ Fax3VSetField(TIFF* tif, ttag_t tag, va_list ap)
case TIFFTAG_CONSECUTIVEBADFAXLINES:
sp->badfaxrun = va_arg(ap, uint32);
break;
+ case TIFFTAG_FAXRECVPARAMS:
+ sp->recvparams = va_arg(ap, uint32);
+ break;
+ case TIFFTAG_FAXSUBADDRESS:
+ _TIFFsetString(&sp->subaddress, va_arg(ap, char*));
+ break;
+ case TIFFTAG_FAXRECVTIME:
+ sp->recvtime = va_arg(ap, uint32);
+ break;
default:
return (*sp->vsetparent)(tif, tag, ap);
}
@@ -1165,6 +1197,15 @@ Fax3VGetField(TIFF* tif, ttag_t tag, va_list ap)
case TIFFTAG_CONSECUTIVEBADFAXLINES:
*va_arg(ap, uint32*) = sp->badfaxrun;
break;
+ case TIFFTAG_FAXRECVPARAMS:
+ *va_arg(ap, uint32*) = sp->recvparams;
+ break;
+ case TIFFTAG_FAXSUBADDRESS:
+ *va_arg(ap, char**) = sp->subaddress;
+ break;
+ case TIFFTAG_FAXRECVTIME:
+ *va_arg(ap, uint32*) = sp->recvtime;
+ break;
default:
return (*sp->vgetparent)(tif, tag, ap);
}
@@ -1217,6 +1258,14 @@ Fax3PrintDir(TIFF* tif, FILE* fd, long flags)
if (TIFFFieldSet(tif,FIELD_BADFAXRUN))
fprintf(fd, " Consecutive Bad Fax Lines: %lu\n",
(u_long) sp->badfaxrun);
+ if (TIFFFieldSet(tif,FIELD_RECVPARAMS))
+ fprintf(fd, " Fax Receive Parameters: %08lx\n",
+ (u_long) sp->recvparams);
+ if (TIFFFieldSet(tif,FIELD_SUBADDRESS))
+ fprintf(fd, " Fax SubAddress: %s\n", sp->subaddress);
+ if (TIFFFieldSet(tif,FIELD_RECVTIME))
+ fprintf(fd, " Fax Receive Time: %lu secs\n",
+ (u_long) sp->recvtime);
}
int
@@ -1256,6 +1305,8 @@ TIFFInitCCITTFax3(TIFF* tif, int scheme)
tif->tif_vsetfield = Fax3VSetField; /* hook for codec tags */
tif->tif_printdir = Fax3PrintDir; /* hook for codec tags */
sp->groupoptions = 0;
+ sp->recvparams = 0;
+ sp->subaddress = NULL;
TIFFSetField(tif, TIFFTAG_FAXMODE, FAXMODE_CLASSF);
if (tif->tif_mode == O_RDONLY) {
diff --git a/libtiff/tif_fax3.h b/libtiff/tif_fax3.h
index f09cdbec..d4ed4a21 100644
--- a/libtiff/tif_fax3.h
+++ b/libtiff/tif_fax3.h
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_fax3.h,v 1.26 1995/07/17 01:27:30 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_fax3.h,v 1.27 1996/01/10 19:33:22 sam Exp $ */
/*
- * Copyright (c) 1990-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1990-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_flush.c b/libtiff/tif_flush.c
index a52419f8..5cf4c67f 100644
--- a/libtiff/tif_flush.c
+++ b/libtiff/tif_flush.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_flush.c,v 1.21 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_flush.c,v 1.22 1996/01/10 19:33:03 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_getimage.c b/libtiff/tif_getimage.c
index 57e6b84c..92c1d1ba 100644
--- a/libtiff/tif_getimage.c
+++ b/libtiff/tif_getimage.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_getimage.c,v 1.38 1995/07/17 01:27:18 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_getimage.c,v 1.39 1996/01/10 19:33:04 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_jpeg.c b/libtiff/tif_jpeg.c
index f88a13a3..c415fa64 100644
--- a/libtiff/tif_jpeg.c
+++ b/libtiff/tif_jpeg.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_jpeg.c,v 1.23 1995/06/30 15:29:02 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_jpeg.c,v 1.25 1996/01/10 19:33:04 sam Exp $ */
/*
- * Copyright (c) 1994-1995 Sam Leffler
- * Copyright (c) 1994-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1994-1996 Sam Leffler
+ * Copyright (c) 1994-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -114,18 +114,15 @@ static int JPEGEncode(TIFF*, tidata_t, tsize_t, tsample_t);
static int JPEGEncodeRaw(TIFF*, tidata_t, tsize_t, tsample_t);
#define FIELD_JPEGTABLES (FIELD_CODEC+0)
-#define FIELD_JPEGQUALITY (FIELD_CODEC+1)
-#define FIELD_JPEGCOLORMODE (FIELD_CODEC+2)
-#define FIELD_JPEGTABLESMODE (FIELD_CODEC+3)
static const TIFFFieldInfo jpegFieldInfo[] = {
{ TIFFTAG_JPEGTABLES, -1,-1, TIFF_UNDEFINED, FIELD_JPEGTABLES,
FALSE, TRUE, "JPEGTables" },
- { TIFFTAG_JPEGQUALITY, 0, 0, TIFF_ANY, FIELD_JPEGQUALITY,
+ { TIFFTAG_JPEGQUALITY, 0, 0, TIFF_ANY, FIELD_PSEUDO,
TRUE, FALSE, "" },
- { TIFFTAG_JPEGCOLORMODE, 0, 0, TIFF_ANY, FIELD_JPEGCOLORMODE,
+ { TIFFTAG_JPEGCOLORMODE, 0, 0, TIFF_ANY, FIELD_PSEUDO,
FALSE, FALSE, "" },
- { TIFFTAG_JPEGTABLESMODE, 0, 0, TIFF_ANY, FIELD_JPEGTABLESMODE,
+ { TIFFTAG_JPEGTABLESMODE, 0, 0, TIFF_ANY, FIELD_PSEUDO,
FALSE, FALSE, "" },
};
#define N(a) (sizeof (a) / sizeof (a[0]))
diff --git a/libtiff/tif_lzw.c b/libtiff/tif_lzw.c
index 23e32cdd..d5eada58 100644
--- a/libtiff/tif_lzw.c
+++ b/libtiff/tif_lzw.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_lzw.c,v 1.69 1995/07/19 00:39:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_lzw.c,v 1.70 1996/01/10 19:33:05 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_msdos.c b/libtiff/tif_msdos.c
index faa99231..5a44c8ae 100644
--- a/libtiff/tif_msdos.c
+++ b/libtiff/tif_msdos.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_msdos.c,v 1.13 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_msdos.c,v 1.14 1996/01/10 19:33:06 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_next.c b/libtiff/tif_next.c
index 9f0732d9..eb191c11 100644
--- a/libtiff/tif_next.c
+++ b/libtiff/tif_next.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_next.c,v 1.26 1995/06/30 15:29:02 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_next.c,v 1.27 1996/01/10 19:33:07 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_open.c b/libtiff/tif_open.c
index 80788556..6ae2c130 100644
--- a/libtiff/tif_open.c
+++ b/libtiff/tif_open.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_open.c,v 1.59 1995/07/20 16:38:53 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_open.c,v 1.63 1996/01/10 19:33:07 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -76,27 +76,13 @@ static const int litTypeshift[13] = {
};
/*
- * Initialize the bit fill order, the
- * shift & mask tables, and the byte
- * swapping state according to the file
+ * Initialize the shift & mask tables, and the
+ * byte swapping state according to the file
* contents and the machine architecture.
*/
static void
-TIFFInitOrder(register TIFF* tif, int magic, int bigendian)
+TIFFInitOrder(TIFF* tif, int magic, int bigendian)
{
-#ifdef notdef
- /*
- * NB: too many applications assume that data is returned
- * by the library in MSB2LSB bit order to change the
- * default bit order to reflect the native cpu. This
- * may change in the future in which case applications
- * will need to check the value of the FillOrder tag.
- */
- tif->tif_flags = (tif->tif_flags &~ TIFF_FILLORDER) | HOST_FILLORDER;
-#else
- tif->tif_flags = (tif->tif_flags &~ TIFF_FILLORDER) | FILLORDER_MSB2LSB;
-#endif
-
tif->tif_typemask = typemask;
if (magic == TIFF_BIGENDIAN) {
tif->tif_typeshift = bigTypeshift;
@@ -149,6 +135,7 @@ TIFFClientOpen(
static const char module[] = "TIFFClientOpen";
TIFF *tif;
int m, bigendian;
+ const char* cp;
m = _TIFFgetMode(mode, module);
if (m == -1)
@@ -174,28 +161,106 @@ TIFFClientOpen(
tif->tif_sizeproc = sizeproc;
tif->tif_mapproc = mapproc;
tif->tif_unmapproc = unmapproc;
+ /*
+ * Default is to return data MSB2LSB and enable the
+ * use of memory-mapped files and strip chopping when
+ * a file is opened read-only.
+ */
+ tif->tif_flags = FILLORDER_MSB2LSB;
+ if (m == O_RDONLY)
+ tif->tif_flags |= TIFF_MAPPED|TIFF_STRIPCHOP;
{ union { int32 i; char c[4]; } u; u.i = 1; bigendian = u.c[0] == 0; }
-#ifdef ENDIANHACK_SUPPORT
/*
- * Numerous vendors, typically on the PC, do not correctly
- * support TIFF; they only support the Intel little-endian
- * byte order. If this hack is enabled, then applications
- * can open a file with a specific byte-order by specifying
- * either "wl" (for litt-endian byte order) or "wb" for
- * (big-endian byte order). This support is not configured
- * by default because it supports the violation of the TIFF
- * spec that says that readers *MUST* support both byte orders.
+ * Process library-specific flags in the open mode string.
+ * The following flags may be used to control intrinsic library
+ * behaviour that may or may not be desirable (usually for
+ * compatibility with some application that claims to support
+ * TIFF but only supports some braindead idea of what the
+ * vendor thinks TIFF is):
+ *
+ * 'l' use little-endian byte order for creating a file
+ * 'b' use big-endian byte order for creating a file
+ * 'L' read/write information using LSB2MSB bit order
+ * 'B' read/write information using MSB2LSB bit order
+ * 'H' read/write information using host bit order
+ * 'M' enable use of memory-mapped files when supported
+ * 'm' disable use of memory-mapped files
+ * 'C' enable strip chopping support when reading
+ * 'c' disable strip chopping support
*
- * It is strongly recommended that you not use this feature
- * except to deal with busted apps that write invalid TIFF.
- * And even in those cases you should bang on the vendors to
- * fix their software.
+ * The use of the 'l' and 'b' flags is strongly discouraged.
+ * These flags are provided solely because numerous vendors,
+ * typically on the PC, do not correctly support TIFF; they
+ * only support the Intel little-endian byte order. This
+ * support is not configured by default because it supports
+ * the violation of the TIFF spec that says that readers *MUST*
+ * support both byte orders. It is strongly recommended that
+ * you not use this feature except to deal with busted apps
+ * that write invalid TIFF. And even in those cases you should
+ * bang on the vendors to fix their software.
+ *
+ * The 'L', 'B', and 'H' flags are intended for applications
+ * that can optimize operations on data by using a particular
+ * bit order. By default the library returns data in MSB2LSB
+ * bit order for compatibiltiy with older versions of this
+ * library. Returning data in the bit order of the native cpu
+ * makes the most sense but also requires applications to check
+ * the value of the FillOrder tag; something they probabyl do
+ * not do right now.
+ *
+ * The 'M' and 'm' flags are provided because some virtual memory
+ * systems exhibit poor behaviour when large images are mapped.
+ * These options permit clients to control the use of memory-mapped
+ * files on a per-file basis.
+ *
+ * The 'C' and 'c' flags are provided because the library support
+ * for chopping up large strips into multiple smaller strips is not
+ * application-transparent and as such can cause problems. The 'c'
+ * option permits applications that only want to look at the tags,
+ * for example, to get the unadulterated TIFF tag information.
*/
- if ((m&O_CREAT) &&
- ((bigendian && mode[1] == 'l') || (!bigendian && mode[1] == 'b')))
- tif->tif_flags |= TIFF_SWAB;
+ for (cp = mode; *cp; cp++)
+ switch (*cp) {
+ case 'b':
+ if ((m&O_CREAT) && !bigendian)
+ tif->tif_flags |= TIFF_SWAB;
+ break;
+ case 'l':
+ if ((m&O_CREAT) && bigendian)
+ tif->tif_flags |= TIFF_SWAB;
+ break;
+ case 'B':
+ tif->tif_flags = (tif->tif_flags &~ TIFF_FILLORDER) |
+ FILLORDER_MSB2LSB;
+ break;
+ case 'L':
+ tif->tif_flags = (tif->tif_flags &~ TIFF_FILLORDER) |
+ FILLORDER_LSB2MSB;
+ break;
+ case 'H':
+ tif->tif_flags = (tif->tif_flags &~ TIFF_FILLORDER) |
+ HOST_FILLORDER;
+ break;
+ case 'M':
+ if (m == O_RDONLY)
+ tif->tif_flags |= TIFF_MAPPED;
+ break;
+ case 'm':
+ if (m == O_RDONLY)
+ tif->tif_flags &= ~TIFF_MAPPED;
+ break;
+#ifdef STRIPCHOP_SUPPORT
+ case 'C':
+ if (m == O_RDONLY)
+ tif->tif_flags |= TIFF_STRIPCHOP;
+ break;
+ case 'c':
+ if (m == O_RDONLY)
+ tif->tif_flags &= ~TIFF_STRIPCHOP;
+ break;
#endif
+ }
/*
* Read in TIFF header.
*/
@@ -211,6 +276,8 @@ TIFFClientOpen(
? (bigendian ? TIFF_LITTLEENDIAN : TIFF_BIGENDIAN)
: (bigendian ? TIFF_BIGENDIAN : TIFF_LITTLEENDIAN);
tif->tif_header.tiff_version = TIFF_VERSION;
+ if (tif->tif_flags & TIFF_SWAB)
+ TIFFSwabShort(&tif->tif_header.tiff_version);
tif->tif_header.tiff_diroff = 0; /* filled in later */
if (!WriteOK(tif, &tif->tif_header, sizeof (TIFFHeader))) {
TIFFError(name, "Error writing TIFF header");
@@ -267,8 +334,14 @@ TIFFClientOpen(
switch (mode[0]) {
case 'r':
tif->tif_nextdiroff = tif->tif_header.tiff_diroff;
- if (TIFFMapFileContents(tif, (tdata_t*) &tif->tif_base, &tif->tif_size))
- tif->tif_flags |= TIFF_MAPPED;
+ /*
+ * Try to use a memory-mapped file if the client
+ * has not explicitly suppressed usage with the
+ * 'm' flag in the open mode (see above).
+ */
+ if ((tif->tif_flags & TIFF_MAPPED) &&
+ !TIFFMapFileContents(tif, (tdata_t*) &tif->tif_base, &tif->tif_size))
+ tif->tif_flags &= ~TIFF_MAPPED;
if (TIFFReadDirectory(tif)) {
tif->tif_rawcc = -1;
tif->tif_flags |= TIFF_BUFFERSETUP;
diff --git a/libtiff/tif_packbits.c b/libtiff/tif_packbits.c
index 5be2071f..7a2e4452 100644
--- a/libtiff/tif_packbits.c
+++ b/libtiff/tif_packbits.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_packbits.c,v 1.48 1995/09/06 00:43:11 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_packbits.c,v 1.49 1996/01/10 19:33:08 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_predict.c b/libtiff/tif_predict.c
index 3dcfbb53..62a38179 100644
--- a/libtiff/tif_predict.c
+++ b/libtiff/tif_predict.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_predict.c,v 1.3 1995/07/01 00:12:45 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_predict.c,v 1.4 1996/01/10 19:33:09 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_predict.h b/libtiff/tif_predict.h
index b7be1d6d..56a0ecdb 100644
--- a/libtiff/tif_predict.h
+++ b/libtiff/tif_predict.h
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_predict.h,v 1.1 1995/06/29 17:20:19 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_predict.h,v 1.2 1996/01/10 19:33:22 sam Exp $ */
/*
- * Copyright (c) 1995 Sam Leffler
- * Copyright (c) 1995 Silicon Graphics, Inc.
+ * Copyright (c) 1995-1996 Sam Leffler
+ * Copyright (c) 1995-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_print.c b/libtiff/tif_print.c
index 6f126015..a48d952e 100644
--- a/libtiff/tif_print.c
+++ b/libtiff/tif_print.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_print.c,v 1.65 1995/10/10 00:12:55 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_print.c,v 1.66 1996/01/10 19:33:10 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_read.c b/libtiff/tif_read.c
index ca6bf899..ce78af1c 100644
--- a/libtiff/tif_read.c
+++ b/libtiff/tif_read.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_read.c,v 1.69 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_read.c,v 1.70 1996/01/10 19:33:11 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_strip.c b/libtiff/tif_strip.c
index 41879ce0..4897c2b6 100644
--- a/libtiff/tif_strip.c
+++ b/libtiff/tif_strip.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_strip.c,v 1.24 1995/08/03 20:54:54 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_strip.c,v 1.25 1996/01/10 19:33:11 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_swab.c b/libtiff/tif_swab.c
index c9a83197..5afb71d6 100644
--- a/libtiff/tif_swab.c
+++ b/libtiff/tif_swab.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_swab.c,v 1.21 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_swab.c,v 1.22 1996/01/10 19:33:12 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_thunder.c b/libtiff/tif_thunder.c
index 2c6f76b9..fbc93c26 100644
--- a/libtiff/tif_thunder.c
+++ b/libtiff/tif_thunder.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_thunder.c,v 1.28 1995/06/30 15:29:02 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_thunder.c,v 1.29 1996/01/10 19:33:13 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_tile.c b/libtiff/tif_tile.c
index b7e0a405..64b89a84 100644
--- a/libtiff/tif_tile.c
+++ b/libtiff/tif_tile.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_tile.c,v 1.26 1995/10/11 23:47:23 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_tile.c,v 1.27 1996/01/10 19:33:14 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_unix.c b/libtiff/tif_unix.c
index 5c4a9010..ae0f6bb8 100644
--- a/libtiff/tif_unix.c
+++ b/libtiff/tif_unix.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_unix.c,v 1.15 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_unix.c,v 1.16 1996/01/10 19:33:14 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_version.c b/libtiff/tif_version.c
index 7ef0b764..7ff3af08 100644
--- a/libtiff/tif_version.c
+++ b/libtiff/tif_version.c
@@ -1,7 +1,7 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_version.c,v 1.15 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_version.c,v 1.16 1996/01/10 19:33:15 sam Exp $ */
/*
- * Copyright (c) 1992-1995 Sam Leffler
- * Copyright (c) 1992-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1992-1996 Sam Leffler
+ * Copyright (c) 1992-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_vms.c b/libtiff/tif_vms.c
index 79ff8bee..24f90fd2 100644
--- a/libtiff/tif_vms.c
+++ b/libtiff/tif_vms.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_vms.c,v 1.19 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_vms.c,v 1.20 1996/01/10 19:33:16 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_warning.c b/libtiff/tif_warning.c
index 0fb055bd..7ec97cbe 100644
--- a/libtiff/tif_warning.c
+++ b/libtiff/tif_warning.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_warning.c,v 1.20 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_warning.c,v 1.21 1996/01/10 19:33:17 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_win3.c b/libtiff/tif_win3.c
index fe139079..16e24781 100644
--- a/libtiff/tif_win3.c
+++ b/libtiff/tif_win3.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_win3.c,v 1.5 1995/06/06 23:49:31 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_win3.c,v 1.6 1996/01/10 19:33:17 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_win32.c b/libtiff/tif_win32.c
index 3811fcb6..ea5e6996 100644
--- a/libtiff/tif_win32.c
+++ b/libtiff/tif_win32.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_win32.c,v 1.2 1995/10/16 19:15:00 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_win32.c,v 1.3 1996/01/10 19:33:18 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_write.c b/libtiff/tif_write.c
index 3fee6f75..c5b64d22 100644
--- a/libtiff/tif_write.c
+++ b/libtiff/tif_write.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_write.c,v 1.71 1995/09/30 18:36:18 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_write.c,v 1.72 1996/01/10 19:33:19 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tif_zip.c b/libtiff/tif_zip.c
index 42f7b300..3da52284 100644
--- a/libtiff/tif_zip.c
+++ b/libtiff/tif_zip.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_zip.c,v 1.4 1995/07/17 14:38:12 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tif_zip.c,v 1.5 1996/01/10 19:33:20 sam Exp $ */
/*
- * Copyright (c) 1995 Sam Leffler
- * Copyright (c) 1995 Silicon Graphics, Inc.
+ * Copyright (c) 1995-1996 Sam Leffler
+ * Copyright (c) 1995-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tiff.h b/libtiff/tiff.h
index 6a5e134c..6dc89bb4 100644
--- a/libtiff/tiff.h
+++ b/libtiff/tiff.h
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiff.h,v 1.60 1995/10/12 16:25:42 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiff.h,v 1.64 1996/01/10 19:33:23 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -299,8 +299,14 @@ typedef enum {
#define TIFFTAG_PIXAR_IMAGEFULLLENGTH 33301 /* full image size in y */
/* tag 33432 is listed in the 6.0 spec w/ unknown ownership */
#define TIFFTAG_COPYRIGHT 33432 /* copyright string */
+/* tags 34232-34236 are private tags registered to Texas Instruments */
+#define TIFFTAG_FRAMECOUNT 34232 /* Sequence Frame Count */
/* tag 34750 is a private tag registered to Pixel Magic */
#define TIFFTAG_JBIGOPTIONS 34750 /* JBIG options */
+/* tags 34908-34914 are private tags registered to SGI */
+#define TIFFTAG_FAXRECVPARAMS 34908 /* encoded Class 2 ses. parms */
+#define TIFFTAG_FAXSUBADDRESS 34909 /* received SubAddr string */
+#define TIFFTAG_FAXRECVTIME 34910 /* receive time (secs) */
/*
* The following are ``pseudo tags'' that can be
@@ -330,4 +336,11 @@ typedef enum {
#define JPEGTABLESMODE_HUFF 0x0002 /* include Huffman tbls */
/* Note: default is JPEGTABLESMODE_QUANT | JPEGTABLESMODE_HUFF */
#define TIFFTAG_FAXFILLFUNC 65540 /* G3/G4 fill function */
+#define TIFFTAG_PIXARLOGDATAFMT 65549 /* PixarLogCodec I/O data sz */
+#define PIXARLOGDATAFMT_8BIT 0 /* regular u_char samples */
+#define PIXARLOGDATAFMT_8BITABGR 1 /* ABGR-order u_chars */
+#define PIXARLOGDATAFMT_10BITLOG 2 /* 10-bit log-encoded (raw) */
+#define PIXARLOGDATAFMT_12BITPICIO 3 /* as per PICIO (1.0==2048) */
+#define PIXARLOGDATAFMT_16BIT 4 /* signed short samples */
+#define PIXARLOGDATAFMT_FLOAT 5 /* IEEE float samples */
#endif /* _TIFF_ */
diff --git a/libtiff/tiffcomp.h b/libtiff/tiffcomp.h
index 700bcc1b..bbdd9b20 100644
--- a/libtiff/tiffcomp.h
+++ b/libtiff/tiffcomp.h
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffcomp.h,v 1.46 1995/10/12 18:26:54 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffcomp.h,v 1.47 1996/01/10 19:33:24 sam Exp $ */
/*
- * Copyright (c) 1990-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1990-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tiffconf.h b/libtiff/tiffconf.h
index c87ee128..598bf8b2 100644
--- a/libtiff/tiffconf.h
+++ b/libtiff/tiffconf.h
@@ -1,7 +1,7 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffconf.h,v 1.11 1995/06/30 15:29:02 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffconf.h,v 1.12 1996/01/10 19:33:24 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tiffio.h b/libtiff/tiffio.h
index de612ff7..74051286 100644
--- a/libtiff/tiffio.h
+++ b/libtiff/tiffio.h
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffio.h,v 1.91 1995/10/16 19:14:51 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffio.h,v 1.92 1996/01/10 19:33:25 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/libtiff/tiffiop.h b/libtiff/tiffiop.h
index 6b9c90aa..967e7954 100644
--- a/libtiff/tiffiop.h
+++ b/libtiff/tiffiop.h
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffiop.h,v 1.75 1995/10/12 18:45:02 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffiop.h,v 1.79 1996/01/10 19:33:26 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -86,6 +86,7 @@ struct tiff {
#define TIFF_POSTENCODE 0x1000 /* need call to postencode routine */
#define TIFF_INSUBIFD 0x2000 /* currently writing a subifd */
#define TIFF_UPSAMPLED 0x4000 /* library is doing data up-sampling */
+#define TIFF_STRIPCHOP 0x8000 /* enable strip chopping support */
toff_t tif_diroff; /* file offset of current directory */
toff_t tif_nextdiroff; /* file offset of following directory */
TIFFDirectory tif_dir; /* internal rep of current directory */
@@ -133,7 +134,7 @@ struct tiff {
tsize_t tif_rawcc; /* bytes unread from raw buffer */
/* memory-mapped file support */
tidata_t tif_base; /* base of mapped file */
-#ifdef WIN32
+#ifdef __WIN32__
void* pv_map_handle; /* WIN32 file mapping handle;
* must be contiguous with tif_base
* since map & unmap only get tif_base
@@ -160,6 +161,8 @@ struct tiff {
TIFFPrintMethod tif_printdir; /* directory print routine */
};
+#define isPseudoTag(t) (t > 0xffff) /* is tag value normal or pseudo */
+
#define isTiled(tif) (((tif)->tif_flags & TIFF_ISTILED) != 0)
#define isMapped(tif) (((tif)->tif_flags & TIFF_MAPPED) != 0)
#define isFillOrder(tif, o) (((tif)->tif_flags & (o)) != 0)
@@ -176,7 +179,7 @@ struct tiff {
((*(tif)->tif_sizeproc)((tif)->tif_clientdata))
#define TIFFMapFileContents(tif, paddr, psize) \
((*(tif)->tif_mapproc)((tif)->tif_clientdata,paddr,psize))
-#ifdef WIN32
+#ifdef __WIN32__
#define TIFFUnmapFileContents(tif, addr, dummy) \
((*(tif)->tif_unmapproc)((tif)->tif_clientdata,addr,\
(toff_t)(tif)->pv_map_handle))
diff --git a/man/TIFFOpen.3t b/man/TIFFOpen.3t
index 6446ff03..d33394a8 100644
--- a/man/TIFFOpen.3t
+++ b/man/TIFFOpen.3t
@@ -1,4 +1,4 @@
-.\" $Header: /usr/people/sam/tiff/man/RCS/TIFFOpen.3t,v 1.13 1995/10/11 19:45:29 sam Exp $
+.\" $Header: /usr/people/sam/tiff/man/RCS/TIFFOpen.3t,v 1.14 1996/01/09 22:45:06 sam Exp $
.\"
.\" Copyright (c) 1988-1995 Sam Leffler
.\" Copyright (c) 1991-1995 Silicon Graphics, Inc.
@@ -23,7 +23,7 @@
.\" OF THIS SOFTWARE.
.\"
.if n .po 0
-.TH TIFFOpen 3T "February 14, 1992"
+.TH TIFFOpen 3T "January 9, 1996"
.SH NAME
TIFFOpen, TIFFFdOpen, TIFFClientOpen \- open a
.SM TIFF
@@ -59,7 +59,8 @@ If the open operation fails, then zero is returned.
The
.I mode
parameter specifies if the file is to be opened for reading (``r''),
-writing (``w''), or appending (``a'').
+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
@@ -93,12 +94,6 @@ To alter these values, or to define values for additional fields,
.IR TIFFSetField (3T)
must be used.
.PP
-It is not possible to append data to a file that has a
-byte ordering opposite to the native byte ordering of a machine.
-That is, for example, the library will not allow
-a file with little-endian byte ordering to be appended to
-on a machine that has a native big-endian byte ordering.
-.PP
.IR TIFFFdOpen
is like
.IR TIFFOpen
@@ -139,6 +134,94 @@ The
parameter is an opaque ``handle'' passed to the client-specified
routines passed as parameters to
.IR TIFFClientOpen .
+.SH 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.
+.TP
+.B l
+When creating a new file force information be written with
+Little-Endian byte order (but see below).
+By default the library will create new files using the native
+.SM CPU
+byte order.
+.TP
+.B b
+When creating a new file force information be written with
+Big-Endian byte order (but see below).
+By default the library will create new files using the native
+.SM CPU
+byte order.
+.TP
+.B L
+Force image data that is read or written to be treated with
+bits filled from Least Significant Bit (\s-1LSB\s+1) to
+Most Significant Bit (\s-1MSB\s+1).
+Note that this is the opposite to the way the library has
+worked from its inception.
+.TP
+.B B
+Force image data that is read or written to be treated with
+bits filled from Most Significant Bit (\s-1MSB\s+1) to
+Least Significant Bit (\s-1LSB\s+1); this is the default.
+.TP
+.B H
+Force image data that is read or written to be treated with
+bits filled in the same order as the native
+.SM CPU.
+.TP
+.B M
+Enable the use of memory-mapped files for images opened read-only.
+If the underlying system does not support memory-mapped files
+or if the specific image being opened cannot be memory-mapped
+then the library will fallback to using the normal system interface
+for reading information.
+By default the library will attempt to use memory-mapped files.
+.TP
+.B m
+Disable the use of memory-mapped files.
+.TP
+.B C
+Enable the use of ``strip chopping'' when reading images
+that are comprised of a single strip or tile of uncompressed data.
+Strip chopping is a mechanism by which the library will automatically
+convert the single-strip [-tile] image to multiple strips [tiles],
+each of which has about 8 Kilobytes of data.
+This facility can be useful in reducing the amount of memory used
+to read an image because the library normally reads each strip [tile]
+in its entirety.
+Strip chopping does however alter the apparent contents of the
+image because when an image is divided into multiple strips it
+looks as though the underlying file contains multiple separate
+strips [tiles].
+Finally, note that strip chopping is an optional compile-time
+feature of the library; just because its use is enabled by an
+application does not mean that it may be present in the library.
+.TP
+.B c
+Disable the use of strip chopping when reading images.
+.SH "BYTE ORDER"
+The
+.SM TIFF
+specification (\fBall versions\fP) states that compliant readers
+.IR "must be capable of reading images written in either byte order" .
+Nonetheless some software that claims to support the reading of
+.SM TIFF
+images is incapable of reading images in anything but the native
+.SM 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
+.SM 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''.
.SH "RETURN VALUES"
Upon successful completion
.IR TIFFOpen ,
diff --git a/man/libtiff.3t b/man/libtiff.3t
index 97adbb4f..085729eb 100644
--- a/man/libtiff.3t
+++ b/man/libtiff.3t
@@ -1,4 +1,4 @@
-.\" $Header: /usr/people/sam/tiff/man/RCS/libtiff.3t,v 1.21 1995/10/12 00:44:17 sam Exp $
+.\" $Header: /usr/people/sam/tiff/man/RCS/libtiff.3t,v 1.22 1996/01/09 22:47:08 sam Exp $
.\"
.\" Copyright (c) 1988-1995 Sam Leffler
.\" Copyright (c) 1991-1995 Silicon Graphics, Inc.
@@ -261,6 +261,9 @@ DateTime 306 R/W
DocumentName 269 R/W
DotRange 336 R/W
ExtraSamples 338 R/W lots
+FaxRecvParams 34908 R/W
+FaxSubAddress 34909 R/W
+FaxRecvTime 34910 R/W
FillOrder 266 R/W control bit order
FreeByteCounts 289 parsed but ignored
FreeOffsets 288 parsed but ignored
diff --git a/man/tiffcp.1 b/man/tiffcp.1
index 2dee5d9f..e928c866 100644
--- a/man/tiffcp.1
+++ b/man/tiffcp.1
@@ -1,4 +1,4 @@
-.\" $Header: /usr/people/sam/tiff/man/RCS/tiffcp.1,v 1.22 1995/10/11 19:42:05 sam Exp $
+.\" $Header: /usr/people/sam/tiff/man/RCS/tiffcp.1,v 1.23 1996/01/10 00:01:03 sam Exp $
.\"
.\" Copyright (c) 1988-1995 Sam Leffler
.\" Copyright (c) 1991-1995 Silicon Graphics, Inc.
@@ -23,7 +23,7 @@
.\" OF THIS SOFTWARE.
.\"
.if n .po 0
-.TH TIFFCP 1 "October 15, 1995"
+.TH TIFFCP 1 "January 9, 1996"
.SH NAME
tiffcp \- copy (and possibly convert) a
.SM TIFF
@@ -60,6 +60,14 @@ in a file, but it is explicitly intended to not alter or convert
the image data content in any way.
.SH OPTIONS
.TP
+.B \-B
+Force output to be written with Big-Endian byte order.
+This option only has an effect when the output file is created or
+overwritten and not when it is appended to.
+.B \-C
+Suppress the use of ``strip chopping'' when reading images
+that have a single strip/tile of uncompressed data.
+.TP
.B \-c
Specify the compression to use for data written to the output file:
.B none
@@ -137,6 +145,12 @@ Specify the length of a tile (in pixels).
.I tiffcp
attempts to set the tile dimensions so
that no more than 8 kilobytes of data appear in a tile.
+.B \-L
+Force output to be written with Little-Endian byte order.
+This option only has an effect when the output file is created or
+overwritten and not when it is appended to.
+.B \-M
+Suppress the use of memory-mapped files when reading images.
.TP
.B \-p
Specify the planar configuration to use in writing image data
diff --git a/port/Makefile.in b/port/Makefile.in
index c69820eb..47882670 100644
--- a/port/Makefile.in
+++ b/port/Makefile.in
@@ -1,12 +1,12 @@
#! smake
-# $Header: /usr/people/sam/tiff/port/RCS/Makefile.in,v 1.3 1995/10/10 00:38:52 sam Exp $
+# $Header: /usr/people/sam/tiff/port/RCS/Makefile.in,v 1.4 1996/01/10 19:36:05 sam Exp $
#
# @WARNING@
#
# Tag Image File Format Library
#
-# Copyright (c) 1995 Sam Leffler
-# Copyright (c) 1995 Silicon Graphics, Inc.
+# Copyright (c) 1995-1996 Sam Leffler
+# Copyright (c) 1995-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/port/install.sh.in b/port/install.sh.in
index 95f4cf9e..c4c52153 100644
--- a/port/install.sh.in
+++ b/port/install.sh.in
@@ -1,12 +1,12 @@
#! @SCRIPT_SH@
-# $Header: /usr/people/sam/tiff/port/RCS/install.sh.in,v 1.18 1995/04/17 23:52:02 sam Exp $
+# $Header: /usr/people/sam/tiff/port/RCS/install.sh.in,v 1.19 1996/01/10 19:36:09 sam Exp $
#
# @WARNING@
#
# HylaFAX Facsimile Software
#
-# Copyright (c) 1990-1995 Sam Leffler
-# Copyright (c) 1991-1995 Silicon Graphics, Inc.
+# Copyright (c) 1990-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
# HylaFAX is a trademark of Silicon Graphics
#
# Permission to use, copy, modify, distribute, and sell this software and
diff --git a/tools/Makefile.in b/tools/Makefile.in
index e0e8b6d9..05726871 100644
--- a/tools/Makefile.in
+++ b/tools/Makefile.in
@@ -1,11 +1,11 @@
-# $Header: /usr/people/sam/tiff/tools/RCS/Makefile.in,v 1.15 1995/10/10 01:45:08 sam Exp $
+# $Header: /usr/people/sam/tiff/tools/RCS/Makefile.in,v 1.16 1996/01/10 19:35:25 sam Exp $
#
# @WARNING@
#
# TIFF Library Tools
#
-# Copyright (c) 1988-1995 Sam Leffler
-# Copyright (c) 1991-1995 Silicon Graphics, Inc.
+# Copyright (c) 1988-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/Makefile.lcc b/tools/Makefile.lcc
index ad7e4a68..0e78b453 100644
--- a/tools/Makefile.lcc
+++ b/tools/Makefile.lcc
@@ -1,9 +1,9 @@
-# $Header: /usr/people/sam/tiff/tools/RCS/Makefile.lcc,v 1.3 1994/12/15 23:51:55 sam Exp $
+# $Header: /usr/people/sam/tiff/tools/RCS/Makefile.lcc,v 1.4 1996/01/10 19:35:26 sam Exp $
#
# TIFF Library Tools
#
-# Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994 Sam Leffler
-# Copyright (c) 1991, 1992, 1993, 1994 Silicon Graphics, Inc.
+# Copyright (c) 1988-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
#
# Permission to use, copy, modify, distribute, and sell this software and
# its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/fax2ps.c b/tools/fax2ps.c
index 13482949..edf6cbb6 100644
--- a/tools/fax2ps.c
+++ b/tools/fax2ps.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/fax2ps.c,v 1.6 1995/10/16 22:32:45 sam Exp $" */
+/* $Header: /usr/people/sam/tiff/tools/RCS/fax2ps.c,v 1.9 1996/01/10 19:35:26 sam Exp $" */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -169,7 +169,7 @@ printTIF(TIFF* tif, int pageNumber)
}
printf("%%%%Page: \"%d\" %d\n", pageNumber, pageNumber);
- printf("gsave\n");
+ printf("/$pageTop save def gsave\n");
if (scaleToPage) {
float yscale = pageHeight / (h/yres);
float xscale = pageWidth / (w/xres);
@@ -192,7 +192,7 @@ printTIF(TIFF* tif, int pageNumber)
for (s = 0; s < ns; s++)
(void) TIFFReadEncodedStrip(tif, s, (tdata_t) NULL, (tsize_t) -1);
printf("p\n");
- printf("grestore\n");
+ printf("grestore $pageTop restore\n");
totalPages++;
}
@@ -283,7 +283,6 @@ pcompar(const void* va, const void* vb)
return (*pa - *pb);
}
-extern double atof();
static void usage(int code);
int
diff --git a/tools/fax2tiff.c b/tools/fax2tiff.c
index 1642b9df..9ceb5278 100644
--- a/tools/fax2tiff.c
+++ b/tools/fax2tiff.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/fax2tiff.c,v 1.39 1995/10/12 16:40:06 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/fax2tiff.c,v 1.40 1996/01/10 19:35:27 sam Exp $ */
/*
- * Copyright (c) 1990-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1990-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/gif2tiff.c b/tools/gif2tiff.c
index ddd0847d..1bd5d885 100644
--- a/tools/gif2tiff.c
+++ b/tools/gif2tiff.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/gif2tiff.c,v 1.25 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/gif2tiff.c,v 1.26 1996/01/10 19:35:28 sam Exp $ */
/*
- * Copyright (c) 1990-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1990-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/pal2rgb.c b/tools/pal2rgb.c
index ed6cce4e..e26d7318 100644
--- a/tools/pal2rgb.c
+++ b/tools/pal2rgb.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/pal2rgb.c,v 1.28 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/pal2rgb.c,v 1.29 1996/01/10 19:35:29 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/ppm2tiff.c b/tools/ppm2tiff.c
index ad493f6a..c57a4f6a 100644
--- a/tools/ppm2tiff.c
+++ b/tools/ppm2tiff.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/ppm2tiff.c,v 1.23 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/ppm2tiff.c,v 1.24 1996/01/10 19:35:29 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/ras2tiff.c b/tools/ras2tiff.c
index 009b4f1f..a82e9101 100644
--- a/tools/ras2tiff.c
+++ b/tools/ras2tiff.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/ras2tiff.c,v 1.27 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/ras2tiff.c,v 1.29 1996/01/10 19:35:30 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -184,7 +184,7 @@ main(int argc, char* argv[])
break;
}
if (h.ras_type == RT_STANDARD && h.ras_depth == 24) {
- tsize_t cc = linebytes;
+ tsize_t cc = h.ras_width;
unsigned char* cp = buf;
#define SWAP(a,b) { unsigned char t = (a); (a) = (b); (b) = t; }
do {
diff --git a/tools/rgb2ycbcr.c b/tools/rgb2ycbcr.c
index 37e3c803..f034dc44 100644
--- a/tools/rgb2ycbcr.c
+++ b/tools/rgb2ycbcr.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/rgb2ycbcr.c,v 1.26 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/rgb2ycbcr.c,v 1.27 1996/01/10 19:35:31 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/sgi2tiff.c b/tools/sgi2tiff.c
index 240eae2d..01d3d7c6 100644
--- a/tools/sgi2tiff.c
+++ b/tools/sgi2tiff.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/sgi2tiff.c,v 1.25 1995/10/12 17:57:38 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/sgi2tiff.c,v 1.26 1996/01/10 19:35:31 sam Exp $ */
/*
- * Copyright (c) 1991-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1991-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/sgigt.c b/tools/sgigt.c
index 161c5cc4..4e5ed0e7 100644
--- a/tools/sgigt.c
+++ b/tools/sgigt.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/sgigt.c,v 1.65 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/sgigt.c,v 1.66 1996/01/10 19:35:32 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/sgisv.c b/tools/sgisv.c
index ad48038d..3b14ff11 100644
--- a/tools/sgisv.c
+++ b/tools/sgisv.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/sgisv.c,v 1.24 1995/10/10 23:53:58 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/sgisv.c,v 1.25 1996/01/10 19:35:33 sam Exp $ */
/*
- * Copyright (c) 1990-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1990-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/thumbnail.c b/tools/thumbnail.c
index 31b72295..a5f72cdb 100644
--- a/tools/thumbnail.c
+++ b/tools/thumbnail.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/thumbnail.c,v 1.10 1995/10/12 16:40:49 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/thumbnail.c,v 1.11 1996/01/10 19:35:33 sam Exp $ */
/*
- * Copyright (c) 1994-1995 Sam Leffler
- * Copyright (c) 1994-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1994-1996 Sam Leffler
+ * Copyright (c) 1994-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/tiff2bw.c b/tools/tiff2bw.c
index 04871360..c0f0945c 100644
--- a/tools/tiff2bw.c
+++ b/tools/tiff2bw.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/tiff2bw.c,v 1.20 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/tiff2bw.c,v 1.21 1996/01/10 19:35:34 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/tiff2ps.c b/tools/tiff2ps.c
index 9d41c87c..d3e27558 100644
--- a/tools/tiff2ps.c
+++ b/tools/tiff2ps.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/tiff2ps.c,v 1.47 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/tiff2ps.c,v 1.48 1996/01/10 19:35:35 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/tiffcmp.c b/tools/tiffcmp.c
index e1130e24..570611ab 100644
--- a/tools/tiffcmp.c
+++ b/tools/tiffcmp.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/tiffcmp.c,v 1.28 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/tiffcmp.c,v 1.29 1996/01/10 19:35:36 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/tiffcp.c b/tools/tiffcp.c
index 0222c37c..c87cc46c 100644
--- a/tools/tiffcp.c
+++ b/tools/tiffcp.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/tiffcp.c,v 1.45 1995/10/12 16:40:49 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/tiffcp.c,v 1.48 1996/01/10 19:35:36 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -74,15 +74,18 @@ main(int argc, char* argv[])
uint32 diroff = 0;
TIFF* in;
TIFF* out;
- const char* mode = "w";
+ char mode[10];
+ char* mp = mode;
int c;
extern int optind;
extern char* optarg;
- while ((c = getopt(argc, argv, "c:f:l:o:p:r:w:aist")) != -1)
+ *mp++ = 'w';
+ *mp = '\0';
+ while ((c = getopt(argc, argv, "c:f:l:o:p:r:w:aistBLMC")) != -1)
switch (c) {
case 'a': /* append to output */
- mode = "a";
+ mode[0] = 'a';
break;
case 'c': /* compression scheme */
if (!processCompressOptions(optarg))
@@ -127,6 +130,18 @@ main(int argc, char* argv[])
outtiled = TRUE;
deftilewidth = atoi(optarg);
break;
+ case 'B':
+ *mp++ = 'b'; *mp = '\0';
+ break;
+ case 'L':
+ *mp++ = 'l'; *mp = '\0';
+ break;
+ case 'M':
+ *mp++ = 'm'; *mp = '\0';
+ break;
+ case 'C':
+ *mp++ = 'c'; *mp = '\0';
+ break;
case '?':
usage();
/*NOTREACHED*/
@@ -136,8 +151,9 @@ main(int argc, char* argv[])
out = TIFFOpen(argv[argc-1], mode);
if (out == NULL)
return (-2);
+ mode[0] = 'r';
for (; optind < argc-1 ; optind++) {
- in = TIFFOpen(argv[optind], "r");
+ in = TIFFOpen(argv[optind], mode);
if (in == NULL)
return (-3);
if (diroff != 0 && !TIFFSetSubDirectory(in, diroff)) {
@@ -302,6 +318,57 @@ CheckAndCorrectColormap(TIFF* tif, int n, uint16* r, uint16* g, uint16* b)
#define CopyField4(tag, v1, v2, v3, v4) \
if (TIFFGetField(in, tag, &v1, &v2, &v3, &v4)) TIFFSetField(out, tag, v1, v2, v3, v4)
+static void
+cpTag(TIFF* in, TIFF* out, uint16 tag, uint16 count, TIFFDataType type)
+{
+ switch (type) {
+ case TIFF_SHORT:
+ if (count == 1) {
+ uint16 shortv;
+ CopyField(tag, shortv);
+ } else if (count == 2) {
+ uint16 shortv1, shortv2;
+ CopyField2(tag, shortv1, shortv2);
+ } else if (count == 4) {
+ uint16 *tr, *tg, *tb, *ta;
+ CopyField4(tag, tr, tg, tb, ta);
+ } else if (count == (uint16) -1) {
+ uint16 shortv1;
+ uint16* shortav;
+ CopyField2(tag, shortv1, shortav);
+ }
+ break;
+ case TIFF_LONG:
+ { uint32 longv;
+ CopyField(tag, longv);
+ }
+ break;
+ case TIFF_RATIONAL:
+ if (count == 1) {
+ float floatv;
+ CopyField(tag, floatv);
+ } else if (count == (uint16) -1) {
+ float* floatav;
+ CopyField(tag, floatav);
+ }
+ break;
+ case TIFF_ASCII:
+ { char* stringv;
+ CopyField(tag, stringv);
+ }
+ break;
+ case TIFF_DOUBLE:
+ if (count == 1) {
+ double doublev;
+ CopyField(tag, doublev);
+ } else if (count == (uint16) -1) {
+ double* doubleav;
+ CopyField(tag, doubleav);
+ }
+ break;
+ }
+}
+
static struct cpTag {
uint16 tag;
uint16 count;
@@ -321,7 +388,6 @@ static struct cpTag {
{ TIFFTAG_PAGENAME, 1, TIFF_ASCII },
{ TIFFTAG_XPOSITION, 1, TIFF_RATIONAL },
{ TIFFTAG_YPOSITION, 1, TIFF_RATIONAL },
- { TIFFTAG_GROUP4OPTIONS, 1, TIFF_LONG },
{ TIFFTAG_RESOLUTIONUNIT, 1, TIFF_SHORT },
{ TIFFTAG_PAGENUMBER, 2, TIFF_SHORT },
{ TIFFTAG_SOFTWARE, 1, TIFF_ASCII },
@@ -331,9 +397,6 @@ static struct cpTag {
{ TIFFTAG_WHITEPOINT, 1, TIFF_RATIONAL },
{ TIFFTAG_PRIMARYCHROMATICITIES,(uint16) -1,TIFF_RATIONAL },
{ TIFFTAG_HALFTONEHINTS, 2, TIFF_SHORT },
- { TIFFTAG_BADFAXLINES, 1, TIFF_LONG },
- { TIFFTAG_CLEANFAXDATA, 1, TIFF_SHORT },
- { TIFFTAG_CONSECUTIVEBADFAXLINES,1, TIFF_LONG },
{ TIFFTAG_INKSET, 1, TIFF_SHORT },
{ TIFFTAG_INKNAMES, 1, TIFF_ASCII },
{ TIFFTAG_DOTRANGE, 2, TIFF_SHORT },
@@ -349,56 +412,7 @@ static struct cpTag {
};
#define NTAGS (sizeof (tags) / sizeof (tags[0]))
-static void
-cpOtherTags(TIFF* in, TIFF* out)
-{
- struct cpTag *p;
-
- for (p = tags; p < &tags[NTAGS]; p++)
- switch (p->type) {
- case TIFF_SHORT:
- if (p->count == 1) {
- uint16 shortv;
- CopyField(p->tag, shortv);
- } else if (p->count == 2) {
- uint16 shortv1, shortv2;
- CopyField2(p->tag, shortv1, shortv2);
- } else if (p->count == (uint16) -1) {
- uint16 shortv1;
- uint16* shortav;
- CopyField2(p->tag, shortv1, shortav);
- }
- break;
- case TIFF_LONG:
- { uint32 longv;
- CopyField(p->tag, longv);
- }
- break;
- case TIFF_RATIONAL:
- if (p->count == 1) {
- float floatv;
- CopyField(p->tag, floatv);
- } else if (p->count == (uint16) -1) {
- float* floatav;
- CopyField(p->tag, floatav);
- }
- break;
- case TIFF_ASCII:
- { char* stringv;
- CopyField(p->tag, stringv);
- }
- break;
- case TIFF_DOUBLE:
- if (p->count == 1) {
- double doublev;
- CopyField(p->tag, doublev);
- } else if (p->count == (uint16) -1) {
- double* doubleav;
- CopyField(p->tag, doubleav);
- }
- break;
- }
-}
+#define CopyTag(tag, count, type) cpTag(in, out, tag, count, type)
typedef int (*copyFunc)
(TIFF* in, TIFF* out, uint32 l, uint32 w, uint16 samplesperpixel);
@@ -407,9 +421,10 @@ static copyFunc pickCopyFunc(TIFF*, TIFF*, uint16, uint16);
static int
tiffcp(TIFF* in, TIFF* out)
{
- uint16 bitspersample, samplesperpixel, shortv;
+ uint16 bitspersample, samplesperpixel;
copyFunc cf;
uint32 w, l;
+ struct cpTag* p;
CopyField(TIFFTAG_IMAGEWIDTH, w);
CopyField(TIFFTAG_IMAGELENGTH, l);
@@ -421,11 +436,11 @@ tiffcp(TIFF* in, TIFF* out)
if (compression == COMPRESSION_JPEG && jpegcolormode == JPEGCOLORMODE_RGB)
TIFFSetField(out, TIFFTAG_PHOTOMETRIC, PHOTOMETRIC_YCBCR);
else
- CopyField(TIFFTAG_PHOTOMETRIC, shortv);
+ CopyTag(TIFFTAG_PHOTOMETRIC, 1, TIFF_SHORT);
if (fillorder != 0)
TIFFSetField(out, TIFFTAG_FILLORDER, fillorder);
else
- CopyField(TIFFTAG_FILLORDER, shortv);
+ CopyTag(TIFFTAG_FILLORDER, 1, TIFF_SHORT);
CopyField(TIFFTAG_SAMPLESPERPIXEL, samplesperpixel);
/*
* Choose tiles/strip for the output image according to
@@ -463,20 +478,9 @@ tiffcp(TIFF* in, TIFF* out)
TIFFSetField(out, TIFFTAG_PLANARCONFIG, config);
else
CopyField(TIFFTAG_PLANARCONFIG, config);
- if (g3opts != (uint32) -1)
- TIFFSetField(out, TIFFTAG_GROUP3OPTIONS, g3opts);
- else
- CopyField(TIFFTAG_GROUP3OPTIONS, g3opts);
- if (samplesperpixel <= 4) {
- uint16 *tr, *tg, *tb, *ta;
- CopyField4(TIFFTAG_TRANSFERFUNCTION, tr, tg, tb, ta);
- }
- { uint16 *red, *green, *blue;
- if (TIFFGetField(in, TIFFTAG_COLORMAP, &red, &green, &blue)) {
- CheckAndCorrectColormap(in, 1<<bitspersample, red, green, blue);
- TIFFSetField(out, TIFFTAG_COLORMAP, red, green, blue);
- }
- }
+ if (samplesperpixel <= 4)
+ CopyTag(TIFFTAG_TRANSFERFUNCTION, 4, TIFF_SHORT);
+ CopyTag(TIFFTAG_COLORMAP, 4, TIFF_SHORT);
/* SMinSampleValue & SMaxSampleValue */
switch (compression) {
case COMPRESSION_JPEG:
@@ -490,8 +494,26 @@ tiffcp(TIFF* in, TIFF* out)
else
CopyField(TIFFTAG_PREDICTOR, predictor);
break;
+ case COMPRESSION_CCITTFAX3:
+ case COMPRESSION_CCITTFAX4:
+ if (compression == COMPRESSION_CCITTFAX3) {
+ if (g3opts != (uint32) -1)
+ TIFFSetField(out, TIFFTAG_GROUP3OPTIONS,
+ g3opts);
+ else
+ CopyField(TIFFTAG_GROUP3OPTIONS, g3opts);
+ } else
+ CopyTag(TIFFTAG_GROUP4OPTIONS, 1, TIFF_LONG);
+ CopyTag(TIFFTAG_BADFAXLINES, 1, TIFF_LONG);
+ CopyTag(TIFFTAG_CLEANFAXDATA, 1, TIFF_LONG);
+ CopyTag(TIFFTAG_CONSECUTIVEBADFAXLINES, 1, TIFF_LONG);
+ CopyTag(TIFFTAG_FAXRECVPARAMS, 1, TIFF_LONG);
+ CopyTag(TIFFTAG_FAXRECVTIME, 1, TIFF_LONG);
+ CopyTag(TIFFTAG_FAXSUBADDRESS, 1, TIFF_ASCII);
+ break;
}
- cpOtherTags(in, out);
+ for (p = tags; p < &tags[NTAGS]; p++)
+ CopyTag(p->tag, p->count, p->type);
cf = pickCopyFunc(in, out, bitspersample, samplesperpixel);
return (cf ? (*cf)(in, out, l, w, samplesperpixel) : FALSE);
diff --git a/tools/tiffdither.c b/tools/tiffdither.c
index 1a478b97..cf1e671f 100644
--- a/tools/tiffdither.c
+++ b/tools/tiffdither.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/tiffdither.c,v 1.25 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/tiffdither.c,v 1.26 1996/01/10 19:35:37 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/tiffdump.c b/tools/tiffdump.c
index 4e0d1312..c74f37a1 100644
--- a/tools/tiffdump.c
+++ b/tools/tiffdump.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/tiffdump.c,v 1.46 1995/10/10 23:24:44 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/tiffdump.c,v 1.48 1996/01/10 19:35:38 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
@@ -42,7 +42,10 @@
#undef open
int open(const char*, int, int);
typedef unsigned int off_t;
-#else /* !VMS && !_WINDOWS */
+#else /* !VMS && !_WINDOWS && !applec */
+#ifdef unix
+#include <sys/types.h>
+#endif
#include <unistd.h>
#include <fcntl.h>
#endif
diff --git a/tools/tiffinfo.c b/tools/tiffinfo.c
index 05b8462c..fc53887f 100644
--- a/tools/tiffinfo.c
+++ b/tools/tiffinfo.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/tiffinfo.c,v 1.25 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/tiffinfo.c,v 1.26 1996/01/10 19:35:39 sam Exp $ */
/*
- * Copyright (c) 1988-1995 Sam Leffler
- * Copyright (c) 1991-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1988-1996 Sam Leffler
+ * Copyright (c) 1991-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided
diff --git a/tools/tiffsplit.c b/tools/tiffsplit.c
index 88821715..48baf8ec 100644
--- a/tools/tiffsplit.c
+++ b/tools/tiffsplit.c
@@ -1,8 +1,8 @@
-/* $Header: /usr/people/sam/tiff/tools/RCS/tiffsplit.c,v 1.12 1995/10/10 00:35:22 sam Exp $ */
+/* $Header: /usr/people/sam/tiff/tools/RCS/tiffsplit.c,v 1.13 1996/01/10 19:35:40 sam Exp $ */
/*
- * Copyright (c) 1992-1995 Sam Leffler
- * Copyright (c) 1992-1995 Silicon Graphics, Inc.
+ * Copyright (c) 1992-1996 Sam Leffler
+ * Copyright (c) 1992-1996 Silicon Graphics, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and
* its documentation for any purpose is hereby granted without fee, provided