Imported from libpng-1.0.7beta11.tar
diff --git a/png.h b/png.h
index 4799709..09af919 100644
--- a/png.h
+++ b/png.h
@@ -1,7 +1,7 @@
/* png.h - header file for PNG reference library
*
- * libpng version 1.0.6j - May 4, 2000
+ * libpng version 1.0.7beta11 - May 6, 2000
* Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.
* Copyright (c) 1996, 1997 Andreas Dilger
* Copyright (c) 1998, 1999, 2000 Glenn Randers-Pehrson
@@ -9,7 +9,7 @@
* Authors and maintainers:
* libpng versions 0.71, May 1995, through 0.88, January 1996: Guy Schalnat
* libpng versions 0.89c, June 1996, through 0.96, May 1997: Andreas Dilger
- * libpng versions 0.97, January 1998, through 1.0.6j - May 4, 2000: Glenn
+ * libpng versions 0.97, January 1998, through 1.0.7beta11 - May 6, 2000: Glenn
* See also "Contributing Authors", below.
*
* Note about libpng version numbers:
@@ -20,40 +20,43 @@
* The following table summarizes matters since version 0.89c, which was
* the first widely used release:
*
- * source png.h png.h shared-lib
- * version string int version
- * ------- ------ ----- ----------
- * 0.89c "1.0 beta 3" 0.89 89 1.0.89
- * 0.90 "1.0 beta 4" 0.90 90 0.90 [should have been 2.0.90]
- * 0.95 "1.0 beta 5" 0.95 95 0.95 [should have been 2.0.95]
- * 0.96 "1.0 beta 6" 0.96 96 0.96 [should have been 2.0.96]
- * 0.97b "1.00.97 beta 7" 1.00.97 97 1.0.1 [should have been 2.0.97]
- * 0.97c 0.97 97 2.0.97
- * 0.98 0.98 98 2.0.98
- * 0.99 0.99 98 2.0.99
- * 0.99a-m 0.99 99 2.0.99
- * 1.00 1.00 100 2.1.0 [100 should be 10000]
- * 1.0.0 1.0.0 100 2.1.0 [100 should be 10000]
- * 1.0.1 1.0.1 10001 2.1.0
- * 1.0.1a-e 1.0.1a-e 10002 2.1.0.1a-e
- * 1.0.2 1.0.2 10002 2.1.0.2
- * 1.0.2a-b 1.0.2a-b 10003 2.1.0.2a-b
- * 1.0.3 1.0.3 10003 2.1.0.3
- * 1.0.3a-d 1.0.3a-d 10004 2.1.0.3a-d
- * 1.0.4 1.0.4 10004 2.1.0.4
- * 1.0.4a-f 1.0.4a-f 10005 2.1.0.4a-f
- * 1.0.5 (+ 2 patches) 1.0.5 10005 2.1.0.5
- * 1.0.5a-d 1.0.5a-d 10006 2.1.0.5a-d
- * 1.0.5e-r 1.0.5e-r 10100 2.1.0.5e-r (not source compatible)
- * 1.0.5s-v 1.0.5s-v 10006 2.1.0.5s-v (not binary compatible)
- * 1.0.6 (+ 3 patches) 1.0.6 10006 2.1.0.6 (still binary incompat)
- * 1.0.6d-f 1.0.6d-f 10007 2.1.0.6d-f (still binary incompat)
- * 1.0.6g 1.0.6g 10007 2.1.0.6g
- * 1.0.6h 1.0.6h 10007 10.6h (testing xy.z so-numbering)
- * 1.0.6i 1.0.6i 10007 10.6i (can be compatible w/ 1.0.0)
- * 1.0.6j 1.0.6j 10007 2.1.0.6j (compatible with 1.0.0)
- * 1.0.6 (+ 4 patches) 1.0.6 10006 2.1.0.6ad (compatible with 1.0.0)
- * 1.0.7 1.0.7 10007 2.1.0.7 (still compatible)
+ * source png.h png.h shared-lib
+ * version string int version
+ * ------- ------ ----- ----------
+ * 0.89c "1.0 beta 3" 0.89 89 1.0.89
+ * 0.90 "1.0 beta 4" 0.90 90 0.90 [should have been 2.0.90]
+ * 0.95 "1.0 beta 5" 0.95 95 0.95 [should have been 2.0.95]
+ * 0.96 "1.0 beta 6" 0.96 96 0.96 [should have been 2.0.96]
+ * 0.97b "1.00.97 beta 7" 1.00.97 97 1.0.1 [should have been 2.0.97]
+ * 0.97c 0.97 97 2.0.97
+ * 0.98 0.98 98 2.0.98
+ * 0.99 0.99 98 2.0.99
+ * 0.99a-m 0.99 99 2.0.99
+ * 1.00 1.00 100 2.1.0 [100 should be 10000]
+ * 1.0.0 (from here on, the 100 2.1.0 [100 should be 10000]
+ * 1.0.1 png.h string is 10001 2.1.0
+ * 1.0.1a-e identical to the 10002 from here on, the shared library
+ * 1.0.2 source version) 10002 is 2.V where V is the source code
+ * 1.0.2a-b 10003 version, except as noted.
+ * 1.0.3 10003
+ * 1.0.3a-d 10004
+ * 1.0.4 10004
+ * 1.0.4a-f 10005
+ * 1.0.5 (+ 2 patches) 10005
+ * 1.0.5a-d 10006
+ * 1.0.5e-r 10100 (not source compatible)
+ * 1.0.5s-v 10006 (not binary compatible)
+ * 1.0.6 (+ 3 patches) 10006 (still binary incompatible)
+ * 1.0.6d-f 10007 (still binary incompatible)
+ * 1.0.6g 10007
+ * 1.0.6h 10007 10.6h (testing xy.z so-numbering)
+ * 1.0.6i 10007 10.6i
+ * 1.0.6j 10007 2.1.0.6j (incompatible with 1.0.0)
+ * 1.0.7beta11 10007 2.1.0.7beta11 (still compatible)
+ * planned:
+ * 1.0.7prep00 10007 2.1.0.7prep00 (still compatible)
+ * 1.0.6ptch04 (w/4 patches) 10006 2.1.0.6 (binary compatible)
+ * 1.0.7 10007 (still compatible)
*
* Henceforth the source version will match the shared-library major
* and minor numbers; the shared-library major version number will be
@@ -61,7 +64,9 @@
* PNG_PNGLIB_VER macro, which is not used within libpng but is available
* for applications, is an unsigned integer of the form xyyzz corresponding
* to the source version x.y.z (leading zeros in y and z). Beta versions
- * are given the previous public release number plus a letter or two.
+ * were given the previous public release number plus a letter, until
+ * version 1.0.6j; from then on they were given the upcoming public
+ * release number plus "-beta-nn" or "-pre-nn".
*
* Binary incompatibility exists only when applications make direct access
* to the info_ptr or png_ptr members through png.h, and the compiled
@@ -82,7 +87,7 @@
* Copyright (c) 1996, 1997 Andreas Dilger
* (libpng versions 0.89c, June 1996, through 0.96, May 1997)
* Copyright (c) 1998, 1999, 2000 Glenn Randers-Pehrson
- * (libpng versions 0.97, January 1998, through 1.0.6j, May 4, 2000)
+ * (libpng versions 0.97, January 1998, through 1.0.7beta11, May 6, 2000)
*
* For the purposes of this copyright and license, "Contributing Authors"
* is defined as the following set of individuals:
@@ -157,13 +162,13 @@
* Y2K compliance in libpng:
* =========================
*
- * May 4, 2000
+ * May 6, 2000
*
* Since the PNG Development group is an ad-hoc body, we can't make
* an official declaration.
*
* This is your unofficial assurance that libpng from version 0.71 and
- * upward through 1.0.6j are Y2K compliant. It is my belief that earlier
+ * upward through 1.0.7beta11 are Y2K compliant. It is my belief that earlier
* versions were also Y2K compliant.
*
* Libpng only has three year fields. One is a 2-byte unsigned integer
@@ -241,7 +246,7 @@
*/
/* Version information for png.h - this should match the version in png.c */
-#define PNG_LIBPNG_VER_STRING "1.0.6j"
+#define PNG_LIBPNG_VER_STRING "1.0.7beta11"
/* Careful here. At one time, Guy wanted to use 082, but that would be octal.
* We must not include leading zeros.
@@ -258,7 +263,8 @@
* the version above.
*/
#ifdef PNG_USE_GLOBAL_ARRAYS
-PNG_EXPORT_VAR (char) png_libpng_ver[12]; /* need room for 99.99.99aa */
+PNG_EXPORT_VAR (char) png_libpng_ver[12]; /* need room for 99.99.99-patch-aa0*/
+ /* Note to maintainer: increase to 18 at the next opportunity */
#else
#define png_libpng_ver png_get_header_ver(NULL)
#endif
@@ -367,11 +373,13 @@
png_charp text; /* comment, may be an empty string (ie "")
or a NULL pointer */
png_size_t text_length; /* length of the text string */
+#ifdef PNG_iTXt_SUPPORTED
png_size_t itxt_length; /* length of the itxt string */
png_charp lang; /* language code, 0-79 characters
or a NULL pointer */
png_charp lang_key; /* keyword translated UTF-8 string, 0 or more
chars or a NULL pointer */
+#endif
} png_text;
typedef png_text FAR * png_textp;
typedef png_text FAR * FAR * png_textpp;
@@ -814,31 +822,33 @@
typedef struct png_struct_def png_struct;
typedef png_struct FAR * png_structp;
-typedef void (*png_error_ptr) PNGARG((png_structp, png_const_charp));
-typedef void (*png_rw_ptr) PNGARG((png_structp, png_bytep, png_size_t));
-typedef void (*png_flush_ptr) PNGARG((png_structp));
-typedef void (*png_read_status_ptr) PNGARG((png_structp, png_uint_32, int));
-typedef void (*png_write_status_ptr) PNGARG((png_structp, png_uint_32, int));
+typedef void (PNGAPI *png_error_ptr) PNGARG((png_structp, png_const_charp));
+typedef void (PNGAPI *png_rw_ptr) PNGARG((png_structp, png_bytep, png_size_t));
+typedef void (PNGAPI *png_flush_ptr) PNGARG((png_structp));
+typedef void (PNGAPI *png_read_status_ptr) PNGARG((png_structp, png_uint_32,
+ int));
+typedef void (PNGAPI *png_write_status_ptr) PNGARG((png_structp, png_uint_32,
+ int));
#ifdef PNG_PROGRESSIVE_READ_SUPPORTED
-typedef void (*png_progressive_info_ptr) PNGARG((png_structp, png_infop));
-typedef void (*png_progressive_end_ptr) PNGARG((png_structp, png_infop));
-typedef void (*png_progressive_row_ptr) PNGARG((png_structp, png_bytep,
+typedef void (PNGAPI *png_progressive_info_ptr) PNGARG((png_structp, png_infop));
+typedef void (PNGAPI *png_progressive_end_ptr) PNGARG((png_structp, png_infop));
+typedef void (PNGAPI *png_progressive_row_ptr) PNGARG((png_structp, png_bytep,
png_uint_32, int));
#endif
#if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) || \
defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED) || \
defined(PNG_LEGACY_SUPPORTED)
-typedef void (*png_user_transform_ptr) PNGARG((png_structp,
+typedef void (PNGAPI *png_user_transform_ptr) PNGARG((png_structp,
png_row_infop, png_bytep));
#endif
#if defined(PNG_READ_USER_CHUNKS_SUPPORTED)
-typedef int (*png_user_chunk_ptr) PNGARG((png_structp, png_unknown_chunkp));
+typedef int (PNGAPI *png_user_chunk_ptr) PNGARG((png_structp, png_unknown_chunkp));
#endif
#if defined(PNG_READ_UNKNOWN_CHUNKS_SUPPORTED)
-typedef void (*png_unknown_chunk_ptr) PNGARG((png_structp));
+typedef void (PNGAPI *png_unknown_chunk_ptr) PNGARG((png_structp));
#endif
/* Transform masks for the high-level interface */
@@ -1101,9 +1111,9 @@
};
/* This prevents a compiler error in png_get_copyright() in png.c if png.c
-and png.h are both at * version 1.0.6j
+and png.h are both at * version 1.0.7beta11
*/
-typedef png_structp version_1_0_6j;
+typedef png_structp version_1_0_7beta11;
typedef png_struct FAR * FAR * png_structpp;
@@ -2103,7 +2113,7 @@
extern PNG_EXPORT(png_charp,png_get_libpng_ver) PNGARG((png_structp png_ptr));
#define PNG_HEADER_VERSION_STRING \
- " libpng version 1.0.6j - May 4, 2000 (header)\n"
+ " libpng version 1.0.7beta11 - May 6, 2000 (header)\n"
#ifdef PNG_READ_COMPOSITE_NODIV_SUPPORTED
/* With these routines we avoid an integer divide, which will be slower on
@@ -2169,8 +2179,6 @@
#define PNG_WROTE_tIME 0x200
#define PNG_WROTE_INFO_BEFORE_PLTE 0x400
#define PNG_BACKGROUND_IS_GRAY 0x800
-#define PNG_CREATED_READ_STRUCT 0x1000
-#define PNG_CREATED_WRITE_STRUCT 0x2000
/* flags for the transformations the PNG library does on the image data */
#define PNG_BGR 0x0001
@@ -2226,6 +2234,7 @@
#define PNG_FLAG_FREE_HIST 0x4000
#define PNG_FLAG_KEEP_UNKNOWN_CHUNKS 0x8000L
#define PNG_FLAG_KEEP_UNSAFE_CHUNKS 0x10000L
+#define PNG_FLAG_LIBRARY_MISMATCH 0x20000L
/* For use in png_set_keep_unknown, png_handle_as_unknown */
#define HANDLE_CHUNK_AS_DEFAULT 0
@@ -2331,22 +2340,22 @@
#endif /* !PNG_READ_BIG_ENDIAN_SUPPORTED */
/* Initialize png_ptr struct for reading, and allocate any other memory.
- * (old interface - NOT DLL EXPORTED).
+ * (old interface - DEPRECATED).
*/
-extern void png_read_init PNGARG((png_structp png_ptr));
+extern PNG_EXPORT(void,png_read_init) PNGARG((png_structp png_ptr));
#define png_read_init(png_ptr) png_read_init_2(png_ptr, \
PNG_LIBPNG_VER_STRING, sizeof(png_struct), sizeof(png_info));
-extern void png_read_init_2 PNGARG((png_structp png_ptr,
+extern PNG_EXPORT(void,png_read_init_2) PNGARG((png_structp png_ptr,
png_const_charp user_png_ver, png_size_t png_struct_size, png_size_t
png_info_size));
/* Initialize png_ptr struct for writing, and allocate any other memory.
- * (old interface - NOT DLL EXPORTED).
+ * (old interface - DEPRECATED).
*/
-extern void png_write_init PNGARG((png_structp png_ptr));
+extern PNG_EXPORT(void,png_write_init) PNGARG((png_structp png_ptr));
#define png_write_init(png_ptr) png_write_init_2(png_ptr, \
PNG_LIBPNG_VER_STRING, sizeof(png_struct), sizeof(png_info));
-extern void png_write_init_2 PNGARG((png_structp png_ptr,
+extern PNG_EXPORT(void,png_write_init_2) PNGARG((png_structp png_ptr,
png_const_charp user_png_ver, png_size_t png_struct_size, png_size_t
png_info_size));