Compare commits

...

799 Commits

Author SHA1 Message Date
Glenn Randers-Pehrson
8fbb563f4e [master] Imported from libpng-1.4.8beta04.tar 2011-06-07 14:59:33 -05:00
Glenn Randers-Pehrson
65e6d5a34f [master] Fixed 1-byte uninitialized memory reference in png_format_buffer()
(Bug report by Frank Busse, related to CVE-2004-0421).
2011-06-07 14:58:07 -05:00
Glenn Randers-Pehrson
47be2e7c3a [master] Imported from libpng-1.4.8beta04.tar 2011-06-06 00:02:11 -05:00
Glenn Randers-Pehrson
4d694dadd8 [master] Issue warning instead of error for out of range coefficients
for rgb_to_gray transform
2011-06-05 23:44:05 -05:00
Glenn Randers-Pehrson
59397f985e [master] Imported from libpng-1.4.8beta03.tar 2011-06-05 23:27:22 -05:00
Glenn Randers-Pehrson
cc1d4d0dbc [master] Check for integer overflow in png_set_rgb_to_gray(). 2011-06-05 23:26:14 -05:00
Glenn Randers-Pehrson
070434c045 [master] Imported from libpng-1.4.8beta02.tar 2011-06-05 17:21:29 -05:00
Glenn Randers-Pehrson
0dc882d7c3 [master] Ported bugfix in pngrtran.c from 1.5.3: Ensure coefficients are OK for
png_rgb_to_gray_fixed().
2011-06-05 17:19:17 -05:00
Glenn Randers-Pehrson
c3ac9a507a [master] Bump to version bumpify-1.4.8rc01 2011-06-03 21:36:28 -05:00
Glenn Randers-Pehrson
a6afebc718 [master] Imported from libpng-1.4.8beta01.tar 2011-06-03 21:21:15 -05:00
Glenn Randers-Pehrson
d41915dc2a [master] Port change to pngrtran.c from 1.5.3: when expanding a paletted image,
always expand to RGBA if transparency is present.
2011-06-03 21:17:49 -05:00
Glenn Randers-Pehrson
5a5ad7a5fa [master] Check for up->location !PNG_AFTER_IDAT when writing unknown chunks
before IDAT.
2011-06-03 21:16:45 -05:00
Glenn Randers-Pehrson
9dad5e37ae [master] Pass "" instead of '\0' to png_default_error() in png_err().
This mistake was introduced in libpng-1.2.20beta01.
2011-06-03 21:14:55 -05:00
Glenn Randers-Pehrson
adde7b5c1e [master] Fix typo in pngwutil.c comment 2011-05-23 06:29:49 -05:00
Glenn Randers-Pehrson
3bdde42e40 [master] Copied png_debug macros from pngpriv.h into pngtest.c and removed
"#include pngpriv.h" from pngtest.c, to avoid setting a bad example.
2011-05-02 14:11:10 -05:00
Glenn Randers-Pehrson
6b4dee12f5 [master] Hard-coded the name of libpng-version.txt in Makefile.am, .in 2011-05-02 12:38:48 -05:00
Glenn Randers-Pehrson
355b90387b [master] Undef "_ALL_SOURCE" for AIX, to prevent "jmpbuf" from being redefined. 2011-05-02 12:29:20 -05:00
Glenn Randers-Pehrson
f512ca7625 [master] Bump to version 1.4.8beta01 2011-05-02 12:23:29 -05:00
Glenn Randers-Pehrson
16ee3e9870 [master] Imported from libpng-1.4.7.tar 2011-04-10 06:44:29 -05:00
Glenn Randers-Pehrson
c8444775b1 [devel] Disabled PNG_PEDANTIC_WARNINGS for all MSC versions as in libpng-1.4.5. 2011-04-10 06:43:27 -05:00
Glenn Randers-Pehrson
784d80b509 [master] Imported from libpng-1.4.7rc01.tar 2011-04-08 20:54:20 -05:00
Glenn Randers-Pehrson
98aacb16c3 [master] Relocated new misplaced declarations in pngwutil.c 2011-04-08 20:41:48 -05:00
Glenn Randers-Pehrson
8a35e25852 [master] Imported from libpng-1.4.6.tar 2011-04-08 12:03:08 -05:00
Glenn Randers-Pehrson
97eb073189 [master] Imported from libpng-1.4.6rc02.tar 2011-04-06 07:09:52 -05:00
Glenn Randers-Pehrson
28534bd47a [master] Improved the optimization of the zlib CMF byte
(see libpng-1.2.6beta03).
2011-04-06 07:07:42 -05:00
Glenn Randers-Pehrson
2053a26873 [master] Updated vstudio/zlib.props to zlib-1.2.5 2011-04-04 15:41:32 -05:00
Glenn Randers-Pehrson
736a230890 [master] Bump to version 1.4.6rc02 2011-04-03 11:36:05 -05:00
Glenn Randers-Pehrson
3926448598 [devel] Fixed a typo in the manual about dithering 2011-04-03 11:34:40 -05:00
Glenn Randers-Pehrson
11130874d4 [master] Imported from libpng-1.4.6rc01.tar 2011-03-31 13:46:06 -05:00
Glenn Randers-Pehrson
ef5a57119a [master] Imported from libpng-1.4.6beta07.tar 2011-03-22 06:31:58 -05:00
Glenn Randers-Pehrson
31f4e52842 [master] Fixed a bug (present since libpng-1.0.7) that makes png_handle_sPLT()
fail to compile when PNG_NO_POINTER_INDEXING is defined.
2011-03-21 18:20:24 -05:00
Glenn Randers-Pehrson
0e1aad158a [master] Removed "strip" from contrib/pngminim/*/makefile. 2011-03-19 22:37:30 -05:00
Glenn Randers-Pehrson
5f5d6d637b [master] Fixed incorrect examples of callback prototypes in the manual,
that were introduced in libpng-1.0.0.
2011-03-19 09:30:41 -05:00
Glenn Randers-Pehrson
a2336bcf05 [master] Bump to version 1.4.6beta07 2011-03-19 09:11:21 -05:00
Glenn Randers-Pehrson
20e6003290 [master] Added a request in the manual that applications do not use "png_" or
"PNG_" to begin any of their own symbols.
Fixed mistake in the descriptions of user read_transform and write_transform
function prototypes in the manual.  The row_info struct is png_row_infop.
2011-03-19 09:08:45 -05:00
Glenn Randers-Pehrson
54c633b810 [master] Added -D_CRT_SECURE_NO_DEPRECATE to CFLAGS in makefile.vcwin32 2011-03-19 08:58:33 -05:00
Glenn Randers-Pehrson
f0c2cc32b1 [master] Added attribute definition (warnings) for MSC_VER >= 1300 in pngconf.h 2011-03-19 08:48:07 -05:00
Glenn Randers-Pehrson
8709982e22 [master] Bump to version 1.4.6beta06 2011-03-18 22:25:49 -05:00
Glenn Randers-Pehrson
686d45dcfd [master] Imported from libpng-1.4.6beta06.tar 2011-03-18 22:22:18 -05:00
Glenn Randers-Pehrson
8502e1ff25 [master] Moved the definition of the new PNG_USED macro into pngconf.h
It really belongs in pngpriv.h and will be moved there in libpng-1.5.x
2011-03-14 12:49:20 -05:00
Glenn Randers-Pehrson
603c9fd959 [master] Added the private PNG_UNUSED() macro definition in pngpriv.h. 2011-03-08 11:33:28 -06:00
Glenn Randers-Pehrson
86946fdc03 [master] Updated contrib/pngsuite/README to add the word "modify". 2011-03-08 11:28:35 -06:00
Glenn Randers-Pehrson
af4c99b21a [master] Bump to version 1.4.6beta06 2011-01-22 21:49:52 -06:00
Glenn Randers-Pehrson
97d2d68428 [master] Imported from libpng-1.4.6beta05.tar 2011-01-22 21:22:48 -06:00
Glenn Randers-Pehrson
ce5d7cb7aa [master] Updated the synopses in the manual to reflect recent changes.
Fixed a typo in the *.def files and deleted entries that are now
declared in pngpriv.h
2011-01-22 21:10:03 -06:00
Glenn Randers-Pehrson
c4ff4e7167 [master] Imported from libpng-1.4.6beta04.tar 2011-01-21 22:20:15 -06:00
Glenn Randers-Pehrson
b94d24eb25 [master] Changed argument of png_get_io_ptr() back to png_struct
because we promised not to change its signature, so it can be used
safely in configure scripts to detect libpng.
2011-01-21 22:17:18 -06:00
Glenn Randers-Pehrson
379d0160ea [master] Added const_png_structp and const_png_infop types, and used them in
prototypes for most png_get_*() functions.
In the manual, describe the png_get_IHDR() arguments in the correct order.
2011-01-21 11:09:07 -06:00
Glenn Randers-Pehrson
23c2ea38a6 [master] Bump to version 1.4.6beta04 2011-01-15 12:05:31 -06:00
Glenn Randers-Pehrson
d486eb18c5 [master] Updated documentation of png_set|get_tRNS() and png_set|get_iCCP(). 2011-01-15 11:15:38 -06:00
Glenn Randers-Pehrson
a10d488a32 [master] Imported from libpng-1.4.6beta03.tar 2011-01-14 21:04:40 -06:00
Glenn Randers-Pehrson
25d754e86d [master] Bump to version 1.4.6beta02 2011-01-14 20:26:03 -06:00
Glenn Randers-Pehrson
bba85637d7 [master] Imported from libpng-1.4.6beta02.tar 2011-01-14 17:26:54 -06:00
Glenn Randers-Pehrson
94c3a45f4c [master] Updated CMakeLists.txt (Clifford Yapp) 2011-01-14 17:25:06 -06:00
Glenn Randers-Pehrson
221be3def1 [master] Fixed misspelled macros in contrib/pngminim (Cosmin) 2010-12-31 09:05:59 -06:00
Glenn Randers-Pehrson
1daf8980dd [master] Bump to version 1.4.6beta02 2010-12-31 09:04:02 -06:00
Glenn Randers-Pehrson
5945408a93 [master] Imported from libpng-1.4.6beta01.tar 2010-12-31 08:06:37 -06:00
Glenn Randers-Pehrson
9a8c568e3c [master] Fixed bug in background transformation handling in pngrtran.c
(it was looking for the flag in png_ptr->transformations instead of in
png_ptr->flags).
2010-12-28 21:45:08 -06:00
Glenn Randers-Pehrson
fb05477e11 [master] Bump version to 1.4.6beta01 2010-12-27 09:04:59 -06:00
Glenn Randers-Pehrson
df68ef4d5e [master] Imported from libpng-1.4.5.tar 2010-12-09 07:49:40 -06:00
Glenn Randers-Pehrson
d857ed275e [master] Reverted removal of PNG_NO_WRITE_gAMA 2010-12-09 07:42:25 -06:00
Glenn Randers-Pehrson
14181b7f48 [master] Removed PNG_NO_WRITE_gAMA from pngminim/encoder/pngusr.h, again. 2010-12-09 07:27:49 -06:00
Glenn Randers-Pehrson
6916ec5fa9 [master] Bump to version 1.4.5rc04 2010-12-09 07:12:52 -06:00
Glenn Randers-Pehrson
acb4822f6b [master] Removed PNG_NO_WRITE_GAMMA from pngminim/encoder/pngusr.h
and some cosmetic changes to some source files.
2010-12-09 06:43:24 -06:00
Glenn Randers-Pehrson
79fb836d66 [master] Imported from libpng-1.4.5rc03.tar 2010-12-03 10:02:23 -06:00
Glenn Randers-Pehrson
010110a0be [master] Imported from libpng-1.4.5rc02.tar 2010-12-02 07:05:34 -06:00
Glenn Randers-Pehrson
756f873a25 [master] Added comment about the potential API incompatibility in
png.h, libpng.3, and libpng-*.txt.
2010-11-25 07:38:30 -06:00
Glenn Randers-Pehrson
e2d740ae04 [master] Reverted png_get_uint_16 macro to beta05 and added a
comment about the potential API incompatibility.
2010-11-24 15:08:39 -06:00
Glenn Randers-Pehrson
ff244b6181 [master] Bump to version 1.4.5beta07 2010-11-24 15:04:15 -06:00
Glenn Randers-Pehrson
d3494d172c [master] Imported from libpng-1.4.5beta06.tar 2010-11-21 15:05:12 -06:00
Glenn Randers-Pehrson
2922c07e67 [master] Changes to remove gcc warnings (John Bowler) 2010-11-21 14:02:16 -06:00
Glenn Randers-Pehrson
c03a949a0d [master] Make the "png_get_uint_16" macro return a png_uint_32 in libpng-1.4
for API compatibility.
2010-11-21 13:31:52 -06:00
Glenn Randers-Pehrson
377e3ca5e6 [master] Added a comment about the parentheses in pngrutil.c 2010-11-20 22:56:49 -06:00
Glenn Randers-Pehrson
f320728911 [master] Restored the parentheses in pngrutil.c; they are needed when the
png_get_*int_*() functions are compiled (i.e., when PNG_USE_READ_MACROS
is not defined).
2010-11-20 21:41:51 -06:00
Glenn Randers-Pehrson
b4a5d88e0a [master] Updated png_get_uint_32 like the others (i -> val). 2010-11-20 18:01:52 -06:00
Glenn Randers-Pehrson
7ea0b3b9e2 [master] Bump to version 1.4.5rc02 2010-11-20 18:01:01 -06:00
Glenn Randers-Pehrson
aa3725c860 [master] Fixed spelling in ANNOUNCE and CHANGES 2010-11-20 17:38:14 -06:00
Glenn Randers-Pehrson
8aa84c7fce [master] Imported from libpng-1.4.5beta05.tar 2010-11-20 17:15:36 -06:00
Glenn Randers-Pehrson
453ceae85f [master] Fixed atomicity of chunk header serialization (Cosmin)
and added test for io_state in pngtest.c (Cosmin)
2010-11-20 16:13:12 -06:00
Glenn Randers-Pehrson
1f5a0b9fa6 [master] Moved reading of file signature into png_read_sig (Cosmin) 2010-11-20 15:50:51 -06:00
Glenn Randers-Pehrson
820a8d1de9 [master] Changed prototypes for png_git_int_16() and png_get_int_32(). 2010-11-20 15:07:51 -06:00
Glenn Randers-Pehrson
6bb02b28a1 [master] Revised png_get_int_32 and png_get_int_16 functions. 2010-11-20 15:00:35 -06:00
Glenn Randers-Pehrson
60ba227d57 [master] Removed some extraneous parentheses that appeared in pngrutil.c of
libpng-1.4.3bet01
2010-11-20 14:47:36 -06:00
Glenn Randers-Pehrson
175e21f5e1 [master] Imported from libpng-1.4.5rc01.tar 2010-11-18 22:11:18 -06:00
Glenn Randers-Pehrson
97db6709e4 [master] Imported from libpng-1.4.5beta04.tar 2010-11-08 12:44:03 -06:00
Glenn Randers-Pehrson
c0fc0dfc45 [master] Check for out-of-range text compression mode in png_set_text(). 2010-10-13 07:34:30 -05:00
Glenn Randers-Pehrson
f3eadd1737 [master] Bump to version 1.4.5beta04 2010-10-13 07:13:45 -05:00
Glenn Randers-Pehrson
c4ec48281c [master] Imported from libpng-1.4.5beta03.tar 2010-10-07 20:52:27 -05:00
Glenn Randers-Pehrson
1a006390d9 [master] Wrapped long lines in CMakeLists.txt
and introduced ${libpng_public_hdrs}
2010-10-05 08:36:49 -05:00
Glenn Randers-Pehrson
953f265513 [master] Bump to version 1.4.5beta03 2010-10-04 23:16:06 -05:00
Glenn Randers-Pehrson
468877578a [master] Imported from libpng-1.4.5beta02.tar 2010-10-04 23:15:57 -05:00
Glenn Randers-Pehrson
ff14eeb4f2 [master] Revised CHANGES about the last bugfix. 2010-10-04 22:18:50 -05:00
Glenn Randers-Pehrson
5f3eabf4cd [master] Fixed problem with symbols creation in Makefile.ac (Martin Banky). 2010-10-04 21:51:57 -05:00
Glenn Randers-Pehrson
bbc70d2471 [master] Reverted configure scripts to autoconf-2.65 2010-10-04 17:00:31 -05:00
Glenn Randers-Pehrson
a0cafa3d0b [master] Bump to version 1.4.5beta02 2010-09-25 06:38:06 -05:00
Glenn Randers-Pehrson
58219ca22f [master] Imported from libpng-1.4.5beta01.tar 2010-09-25 06:35:14 -05:00
Glenn Randers-Pehrson
50b28f3bf2 [master] Rebuilt configure scripts with autoconf-2.68 instead of autoconf-2.65 2010-09-24 15:22:09 -05:00
Glenn Randers-Pehrson
0f8345abf7 [master] Bump to version 1.4.5beta01 2010-09-24 10:22:16 -05:00
Glenn Randers-Pehrson
4f213e08aa [master] Fixed configure.ac bug introduced in version 1.4.4rc05. 2010-09-24 09:51:01 -05:00
Glenn Randers-Pehrson
8493de3cee [master] Imported from libpng-1.4.4.tar 2010-09-23 07:22:01 -05:00
Glenn Randers-Pehrson
fee6e7428f [master] Imported from libpng-1.4.4rc05.tar 2010-09-20 10:21:28 -05:00
Glenn Randers-Pehrson
d10616d364 [master] Imported from libpng-1.4.4rc04.tar 2010-09-16 09:51:06 -05:00
Glenn Randers-Pehrson
85d143a273 [master] Revised autogen.sh to recognize and use $AUTOCONF, $AUTOMAKE,
$AUTOHEADER, $AUTOPOINT, $ACLOCAL and $LIBTOOLIZE
2010-09-15 06:44:47 -05:00
Glenn Randers-Pehrson
6e72bc46d3 [master] Fixed indentation and removed debugging message from CMakeLists.txt 2010-09-15 06:43:23 -05:00
Glenn Randers-Pehrson
b8eed1d830 [master] Imported from libpng-1.4.4rc03.tar 2010-09-13 20:58:20 -05:00
Glenn Randers-Pehrson
a64ecdfa5b [master] Eliminated another deprecated reference to png_ptr->io_ptr
in pngtest.c
2010-09-13 10:19:20 -05:00
Glenn Randers-Pehrson
bcfc0ce5f6 [master] Removed an extraneous close-double-quote from CMakeLists.txt 2010-09-13 09:57:13 -05:00
Glenn Randers-Pehrson
8bc0719dde [master] Imported from libpng-1.4.4rc02.tar 2010-09-13 08:14:27 -05:00
Glenn Randers-Pehrson
185cd6c058 [master] Revised CMakeLists.txt (Philip Lowman). 2010-09-13 08:13:09 -05:00
Glenn Randers-Pehrson
afb77541b4 [master] Bump to version 1.4.4rc02 2010-09-13 08:11:54 -05:00
Glenn Randers-Pehrson
c4a5c2de26 [master] Imported from libpng-1.4.4rc01.tar 2010-09-10 08:50:36 -05:00
Glenn Randers-Pehrson
87bc4b08ff [master] Imported from libpng-1.4.4beta08.tar 2010-09-02 06:54:37 -05:00
Glenn Randers-Pehrson
65cdb3dfa8 [master] Updated the xcode project to work with libpng-1.4.x and added iOS
targets for simulator and device (Philippe Hausler).
2010-09-02 06:41:40 -05:00
Glenn Randers-Pehrson
cc411ae004 [master] Bump to version 1.4.4beta08 2010-08-26 08:50:32 -05:00
Glenn Randers-Pehrson
f521b99b09 [master] Imported from libpng-1.4.4beta07.tar 2010-08-26 08:46:53 -05:00
Glenn Randers-Pehrson
b08f330d62 [master] Eliminated new unnecessary #if tests regarding the sCAL chunk
from pngrutil.c
2010-08-24 12:38:36 -05:00
Glenn Randers-Pehrson
41ffb1c950 [master] Eliminated a deprecated reference to png_ptr->io_ptr in pngtest.c 2010-08-23 16:54:35 -05:00
Glenn Randers-Pehrson
ebe3ea3204 [master] Restored the documentation of PNG_USER_PRIVATEBUILD in pngconf.h 2010-08-23 06:46:18 -05:00
Glenn Randers-Pehrson
d94c4516c6 [master] Corrected handling and documentation of PNG_USER_PRIVATEBUILD flag. 2010-08-22 12:36:25 -05:00
Glenn Randers-Pehrson
b0f8d9bb97 [master] Changed PNG_LIB_NAME from pngNN to libpngNN in CMakeLists.txt
(Philip Lowman)
2010-08-21 18:55:08 -05:00
Glenn Randers-Pehrson
04dfe7b3f6 [master] Revised CMakeLists.txt to make symlinks instead of copies
when installing.
2010-08-21 18:49:50 -05:00
Glenn Randers-Pehrson
547afcfc74 [master] Revised CMakeLists.txt to put the man pages in share/man/man*
not in man/man*
2010-08-21 18:36:29 -05:00
Glenn Randers-Pehrson
48afdb4eef [master] Update CMakelists.txt to use CMAKE_INSTALL_LIBDIR variable;
useful for installing libpng in /usr/lib64 (FundaWang).
2010-08-21 18:29:47 -05:00
Glenn Randers-Pehrson
9ee96e3ba9 [master] Updated prebuilt aclocal.m4 and ltmain.sh 2010-08-17 13:36:20 -05:00
Glenn Randers-Pehrson
0311f5412e [master] Add .dll.a to symlinks installed by Makefile.am (Yaakov) 2010-08-13 08:14:13 -05:00
Glenn Randers-Pehrson
e734eba51e [master] Bump to version 1.4.4beta07 2010-08-13 07:56:59 -05:00
Glenn Randers-Pehrson
7ed40716cb [master] Imported from libpng-1.4.4beta06.tar 2010-08-11 09:10:35 -05:00
Glenn Randers-Pehrson
155889b318 [master] Revised contrib/gregbook to work under cygwin/mingw. 2010-08-11 06:50:11 -05:00
Glenn Randers-Pehrson
4dd011f6d0 [master] Don't try to use version-script with cygwin/mingw. 2010-08-11 06:48:37 -05:00
Glenn Randers-Pehrson
e45a5d3a32 [master] Bump to version 1.4.4beta06 2010-08-06 06:43:59 -05:00
Glenn Randers-Pehrson
80a1050237 [master] Bump to version 1.4.4beta05 2010-08-06 06:40:31 -05:00
Glenn Randers-Pehrson
54592bba4d [master] Don't depend only _WINDOWS_ in pngconf.h to detect Windows 2010-08-06 06:36:56 -05:00
Glenn Randers-Pehrson
902d4d109a [master] Correct use of _WINDOWS_ in pngconf.h 2010-08-03 21:10:04 -05:00
Glenn Randers-Pehrson
d8daacf157 [master] Removed unused png_mem_* defines from pngconf.h. 2010-08-03 20:47:46 -05:00
Glenn Randers-Pehrson
0da5bcb414 [master] Imported from libpng-1.4.4beta05.tar 2010-08-03 20:46:46 -05:00
Glenn Randers-Pehrson
ac6555fa3c [master] Updated projects/visualc71 so it can find scripts/pnglibconf.h 2010-08-03 08:53:13 -05:00
Glenn Randers-Pehrson
2af7ef63c3 [master] Updated the read macros and functions from 1.5.0beta38. 2010-07-31 16:37:38 -05:00
Glenn Randers-Pehrson
6da5b35fca [master] Bump to version 1.4.4beta04 2010-07-24 18:20:21 -05:00
Glenn Randers-Pehrson
abd68eb92b [master] Imported from libpng-1.4.4beta03.tar 2010-07-24 18:16:54 -05:00
Glenn Randers-Pehrson
bf451ffc9a [master] Eliminated the new special case typedef of png_longjmp_ptr for WATCOM
and made a special case "#define PNGAPI" in pngconf.h instead.
2010-07-24 18:13:55 -05:00
Glenn Randers-Pehrson
be734f5592 [master] Removed reference to cbuilder5/* from Makefile.in and Makefile.am 2010-07-24 15:31:38 -05:00
Glenn Randers-Pehrson
9f0c080847 [master] Bump to version 1.4.4beta03 2010-07-24 08:34:34 -05:00
Glenn Randers-Pehrson
3a1ba773b0 [master] Imported from libpng-1.4.4beta02.tar 2010-07-24 08:30:30 -05:00
Glenn Randers-Pehrson
849a1ab845 [master] Added a special case typedef of png_longjmp_ptr for WATCOM. 2010-07-24 08:02:03 -05:00
Glenn Randers-Pehrson
940de5ab02 [master] Moved the definition of png_snprintf()
outside of the enclosing #ifdef blocks in pngconf.h
2010-07-24 07:56:36 -05:00
Glenn Randers-Pehrson
dd9578f379 [master] Update copyright year in documentation 2010-07-22 07:55:00 -05:00
Glenn Randers-Pehrson
0ce807691b [master] Added -DNO_PNG_SNPRINTF to CFLAGS in scripts/makefile.dj2 2010-07-16 21:17:50 -05:00
Glenn Randers-Pehrson
4f8ea5eede [master] Bump to version 1.4.4beta02 2010-07-12 06:41:34 -05:00
Glenn Randers-Pehrson
7869e676af [master] Imported from libpng-1.4.4beta01.tar 2010-07-12 06:37:08 -05:00
Glenn Randers-Pehrson
af0a726689 [master] Changed "extern PNG_EXPORT" to "PNG_EXPORT" in png.h (Jan Nijtmans)
Changed "extern" to "PNG_EXTERN" in pngpriv.h (except for the 'extern "C" {')
Put #ifndef PNG_EXTERN, #endif around the define PNG_EXTERN in pngpriv.h
2010-07-12 06:22:55 -05:00
Glenn Randers-Pehrson
8d9263fca6 [master] Added some "(" that were missing in README and scripts/README.txt 2010-06-30 23:11:34 -05:00
Glenn Randers-Pehrson
d6a0cbaade [master] Removed some newly-added TAB characters from pngpread.c
and pngrtran.c, and fixed some indentation in pngpread.c and pngrutil.c
2010-06-30 23:07:02 -05:00
Glenn Randers-Pehrson
2302a4d04f [master] Revised the "SEE ALSO" style of libpng.3, libpngpf.3, and png.5 2010-06-27 13:53:25 -05:00
Glenn Randers-Pehrson
8f9a2d08ea [master] Bump version to libpng-1.4.4beta01 2010-06-25 22:18:15 -05:00
Glenn Randers-Pehrson
30c73195b5 [master] Tag the recent releases 2010-06-25 20:44:31 -05:00
Glenn Randers-Pehrson
097485195c [master] Imported from libpng-1.4.3.tar 2010-06-25 20:22:08 -05:00
Glenn Randers-Pehrson
c5f6fa110a [master] Imported from libpng-1.4.3rc03.tar 2010-06-25 20:20:16 -05:00
Glenn Randers-Pehrson
90cfcecc09 [master] Imported from libpng-1.4.3rc02.tar 2010-06-25 20:20:14 -05:00
Glenn Randers-Pehrson
dee0e2ed0f [master] Imported from libpng-1.4.3rc01.tar 2010-06-25 20:20:12 -05:00
Glenn Randers-Pehrson
5ad9884ff1 [master] Imported from libpng-1.4.3beta05.tar 2010-06-25 20:20:09 -05:00
Glenn Randers-Pehrson
188eb6b426 [master] Imported from libpng-1.4.3beta04.tar 2010-06-25 20:20:07 -05:00
Glenn Randers-Pehrson
8361f64dbf [master] Imported from libpng-1.4.3beta02.tar 2010-06-25 20:20:04 -05:00
Glenn Randers-Pehrson
2a6227941e [master] Imported from libpng-1.4.3beta01.tar 2010-06-25 20:20:02 -05:00
Glenn Randers-Pehrson
a582b8f840 [master] Imported from libpng-1.4.3.tar 2010-06-25 20:19:59 -05:00
Glenn Randers-Pehrson
5316f66005 [master] The "vstudio" project was missing from the .zip and .7z distributions 2010-05-17 08:31:53 -05:00
Glenn Randers-Pehrson
f86905457a [master] Added missing quotation marks in the aix block of configure.ac 2010-05-14 15:40:31 -05:00
Glenn Randers-Pehrson
abb211c4e8 [master] Bump to version 1.4.3beta01 2010-05-14 15:38:51 -05:00
Glenn Randers-Pehrson
bb56c39d16 [master] Imported from libpng-1.4.2.tar 2010-05-06 06:48:47 -05:00
Glenn Randers-Pehrson
77237196c7 [master] Imported from libpng-1.4.2rc06.tar 2010-05-04 09:34:13 -05:00
Glenn Randers-Pehrson
a310a3b398 [master] Moved declarations of umsg[] inside the proper #ifdef blocks
in pngrutil.c
2010-05-04 09:32:02 -05:00
Glenn Randers-Pehrson
e0f6c7d90b [master] Revert to version 1.4.2rc05 2010-05-04 09:24:32 -05:00
Glenn Randers-Pehrson
a1587302aa [master] Use bitwise AND instead of integer arithmetic MOD in pngrutil.c
calculation  of the png_ptr->rowbuf pointer into png_ptr->big_row_buf.
2010-05-03 21:57:13 -05:00
Glenn Randers-Pehrson
cc0bff446b [master] Changed a typecast in pngrutil.c to stifle compiler warning
in the calculation of the png_ptr->rowbuf pointer into png_ptr->big_row_buf.
2010-05-03 21:28:50 -05:00
Glenn Randers-Pehrson
9b8ddff5b7 [master] Added a typecast in pngrutil.c to stifle compiler warning
in the calculation of the png_ptr->rowbuf pointer into png_ptr->big_row_buf.
2010-05-03 15:19:11 -05:00
Glenn Randers-Pehrson
ac4942e26b [master] Moved declarations of umsg[] inside proper #ifdef blocks in pngrutil.c 2010-05-03 15:18:09 -05:00
Glenn Randers-Pehrson
2c55e3e917 [master] Bump to version 1.4.2rc06 2010-04-29 11:47:15 -05:00
Glenn Randers-Pehrson
db082802c6 [master] Bump to version 1.4.2rc05 2010-04-29 11:44:55 -05:00
Glenn Randers-Pehrson
b367fb5ac6 [master] Bump to version 1.4.2rc06 2010-04-29 11:20:42 -05:00
Glenn Randers-Pehrson
e9ab2f8d94 [master] Imported from libpng-1.4.2rc05.tar 2010-04-29 11:08:01 -05:00
Glenn Randers-Pehrson
a845cca037 [master] Corrected protection of png_get_user_transform_ptr.
The API declaration in
png.h is removed if both READ and WRITE USER_TRANSFORM are turned off
but was left defined in pngtrans.c
2010-04-29 10:43:23 -05:00
Glenn Randers-Pehrson
3ab6ef0aa1 [master] Corrected PNG_UNKNOWN_CHUNKS_SUPPORTED in gregbook/readpng2.c
to PNG_HANDLE_AS_UNKNOWN_SUPPORTED
2010-04-29 10:34:18 -05:00
Glenn Randers-Pehrson
198ed18b9e [master] Bump to version 1.4.2rc05 2010-04-29 09:41:01 -05:00
Glenn Randers-Pehrson
9110473f93 [master] Removed dummy_inflate.c and uncompr.c from contrib/pngminim/encoder 2010-04-29 09:38:05 -05:00
Glenn Randers-Pehrson
97313e0aab [master] Include png_reset_zstream() in png.c only when PNG_READ_SUPPORTED
is defined.
2010-04-29 09:22:01 -05:00
Glenn Randers-Pehrson
8876e74e43 [master] Remove mislocated files from projects/visualc6 2010-04-26 23:02:39 -05:00
Glenn Randers-Pehrson
510227e39e [master] Imported from libpng-1.4.2rc04.tar 2010-04-26 22:51:30 -05:00
Glenn Randers-Pehrson
7a1f214166 [master] Set PNG_NO_READ_BGR, PNG_NO_IO_STATE, and PNG_NO_TIME_RFC1123 in
contrib/pngminim/decoder/pngusr.h to make a smaller decoder application.
2010-04-26 22:41:53 -05:00
Glenn Randers-Pehrson
5913dd10f1 [master] Added the "vstudio" project to replace "visualc6" and "visualc71"
which will be removed from libpng-1.5.0.
2010-04-26 16:28:35 -05:00
Glenn Randers-Pehrson
087ebd80da [master] Imported from libpng-1.4.2rc03.tar 2010-04-24 13:58:16 -05:00
Glenn Randers-Pehrson
bc9267e3a6 [master] Move png_set_quantize and png_do_quantize to proper locations in docs. 2010-04-16 10:41:02 -05:00
Glenn Randers-Pehrson
a019c335c9 [master] Bump to version 1.4.2rc03 2010-04-16 10:25:20 -05:00
Glenn Randers-Pehrson
ed49c8c1b6 [master] Trivial revision of documentation. 2010-04-16 10:04:53 -05:00
Glenn Randers-Pehrson
2a243fc074 [master] Added some "(long)" typecasts to printf calls in png_handle_cHRM(). 2010-04-16 09:41:27 -05:00
Glenn Randers-Pehrson
47045ce402 [master] Bump to version 1.4.2rc02 2010-04-16 07:45:21 -05:00
Glenn Randers-Pehrson
d6e67586bf [master] Imported from libpng-1.4.2rc02.tar 2010-04-16 07:28:21 -05:00
Glenn Randers-Pehrson
6e9783bd25 [master] Updated the scripts/*.def lists to include png_set_quantize() 2010-04-16 07:26:01 -05:00
Glenn Randers-Pehrson
8dc3729522 [master] Reenabled png_set_dither() but renamed it to png_set_quantize() to
reflect more accurately what it actually does.  At the same time, renamed
the PNG_DITHER_[RED,GREEN_BLUE]_BITS macros to
PNG_QUANTIZE_[RED,GREEN,BLUE]_BITS.
2010-04-16 07:24:52 -05:00
Glenn Randers-Pehrson
7aad4e7fb4 [master] Expanded CHANGES entry about disabling dithering support. 2010-04-13 22:31:25 -05:00
Glenn Randers-Pehrson
930af7d50b [master] Documented the fact that png_set_dither() is no longer supported. 2010-04-13 22:08:21 -05:00
Glenn Randers-Pehrson
0f544f62d6 [master] Imported from libpng-1.4.2rc01.tar 2010-04-10 06:43:07 -05:00
Glenn Randers-Pehrson
398c212955 [master] Bump to version 1.4.2beta02 2010-04-01 07:52:00 -05:00
Glenn Randers-Pehrson
2ec1fc60c3 [master] Imported from libpng-1.4.2beta01.tar 2010-04-01 07:41:11 -05:00
Glenn Randers-Pehrson
c01ee053b1 [master] Imported from libpng-1.4.1.tar 2010-02-25 05:45:01 -06:00
Glenn Randers-Pehrson
b0baee5e36 [master] Removed unused gzio.c from contrib/pngminim gather and makefile
scripts.  This is necessary when libz is updated to version 1.2.4.
2010-02-21 23:12:32 -06:00
Glenn Randers-Pehrson
b55295cb12 [master] Imported from libpng-1.4.1rc04.tar 2010-02-19 19:23:47 -06:00
Glenn Randers-Pehrson
5928ee97ca [master] Define _ALL_SOURCE in configure.ac, makefile.aix, and CMakeLists.txt
when using the AIX compiler.
2010-02-19 19:22:08 -06:00
Glenn Randers-Pehrson
2445ad4331 [master] Imported from libpng-1.4.1rc03.tar 2010-02-19 15:09:07 -06:00
Glenn Randers-Pehrson
93d6d9d835 [master] Define _ALLSOURCE in pngconf.h when building with nonANSI AIX compiler.
otherwise AIX reserves "jmpbuf" and renames it to "__jmpbuf".
2010-02-19 15:02:46 -06:00
Glenn Randers-Pehrson
d207e6a6ad [master] Removed obsolete unused MMX-querying support from contrib/gregbook 2010-02-19 07:52:06 -06:00
Glenn Randers-Pehrson
df6f3f404a [master] Noted in scripts/makefile.mingw that it expects to be run under MSYS. 2010-02-18 23:04:25 -06:00
Glenn Randers-Pehrson
357c1c8c53 [master] Imported from libpng-1.4.1rc02.tar 2010-02-18 07:07:19 -06:00
Glenn Randers-Pehrson
44827ccad8 [master] Fixed typo in ANNOUNCE and CHANGES. 2010-02-14 07:43:22 -06:00
Glenn Randers-Pehrson
0d1a2dd7a9 [master] Bump to version 1.4.1beta13 2010-02-14 07:42:15 -06:00
Glenn Randers-Pehrson
471c9b47fe [master] Imported from libpng-1.4.1beta12.tar 2010-02-14 07:05:57 -06:00
Glenn Randers-Pehrson
23b9a2fda0 [master] Fixed incorrect typecast of png_get_user_malloc_max() in pngget.c 2010-02-14 06:48:09 -06:00
Glenn Randers-Pehrson
7d6103ad6c [master] Imported from libpng-1.4.1beta11.tar 2010-02-12 21:33:07 -06:00
Glenn Randers-Pehrson
ec39f8f8d7 [master] Update announcements about png_decompress_chunk(). 2010-02-12 21:25:37 -06:00
Glenn Randers-Pehrson
a2cde53c87 [master] 2010-02-12 21:07:14 -06:00
Glenn Randers-Pehrson
13714e87f2 [master] Imported from libpng-1.4.1beta10.tar 2010-02-08 15:58:31 -06:00
Glenn Randers-Pehrson
9101d75316 [master] Return allocated "old_buffer" in png_push_save_buffer()
before calling png_error(), to avoid a potential memory leak.
2010-02-08 15:56:17 -06:00
Glenn Randers-Pehrson
233edbf415 [master] Imported from libpng-1.4.1beta09.tar 2010-02-07 23:05:33 -06:00
Glenn Randers-Pehrson
bd209f75fa [master] Reverted to original png_push_save_buffer() code. 2010-02-07 23:02:42 -06:00
Glenn Randers-Pehrson
27854a478e [master] Fixed incorrect test in new png_push_save_buffer() code. 2010-02-07 20:02:02 -06:00
Glenn Randers-Pehrson
f12a87a96c [master] Imported from libpng-1.4.1beta08.tar 2010-02-06 19:48:53 -06:00
Glenn Randers-Pehrson
cb4358ddbb [master] Revert to version 1.4.1beta07 2010-02-06 13:48:45 -06:00
Glenn Randers-Pehrson
c4819d78ba [master] Fix scripting typo in pngwrite.c 2010-02-06 13:44:20 -06:00
Glenn Randers-Pehrson
0b721cd4c4 [master] Bump to version libpng-1.4.1beta08 2010-02-06 13:03:51 -06:00
Glenn Randers-Pehrson
b025757328 [master] Bump to version libpng-1.4.1beta07 2010-02-06 12:17:51 -06:00
Glenn Randers-Pehrson
4bd73b6947 [master] Revised png_push_save_buffer() to do fewer but larger png_mallocs
Eliminated use of png_ptr->irowbytes and reused the slot in png_ptr as
png_ptr->png_user_chunk_malloc_max.
2010-02-06 12:15:07 -06:00
Glenn Randers-Pehrson
f3c42680db [master] Fixed an incorrect #ifdef in pngwrite.c 2010-02-06 10:44:22 -06:00
Glenn Randers-Pehrson
c10066205d [master] Fixed indentation in some png.h comments. 2010-02-05 17:31:42 -06:00
Glenn Randers-Pehrson
21b7aaa428 [master] Imported from libpng-1.4.1beta07.tar 2010-02-05 16:30:38 -06:00
Glenn Randers-Pehrson
d7225fdfce [master] Folded some long lines in png.h
Most of them were too long because of recent insertion of PNG_DEPSTRUCT.
2010-02-05 15:35:41 -06:00
Glenn Randers-Pehrson
deb870c77d [master] Added defineable PNG_USER_CHUNK_CACHE_MAX and PNG_USER_CHUNK_MALLOC_MAX 2010-02-05 15:32:42 -06:00
Glenn Randers-Pehrson
c05538959b [master] Revised documentation to mention the change in
the prototype for the user malloc_fn().
2010-02-02 06:47:13 -06:00
Glenn Randers-Pehrson
f6c761dda1 [master] Imported from libpng-1.4.1beta06.tar 2010-01-28 07:22:50 -06:00
Glenn Randers-Pehrson
877b08d6d2 [master] Implement two-pass png_decompress_chunk() function
suggested by John Bowler.  Does not waste memory, does only one malloc()
to the measured decompressed size.
2010-01-28 07:16:15 -06:00
Glenn Randers-Pehrson
a69064328b [master] Undo recent pngtest changes
The problem was with a buggy compiler (gcc-4.0.1) not a libpng problem
and not worth attempting to work around.
2010-01-27 07:05:02 -06:00
Glenn Randers-Pehrson
01b9566e50 [master] Use int copies instead of longs in pngtest.c
to try to appease the Mac compiler
2010-01-26 23:27:21 -06:00
Glenn Randers-Pehrson
ca3a100be6 [master] Revised pngtest.c for the sake of an optimizing compiler 2010-01-26 22:45:58 -06:00
Glenn Randers-Pehrson
1655e4ddb0 [master] Imported from libpng-1.4.1beta05.tar 2010-01-26 06:56:04 -06:00
Glenn Randers-Pehrson
526f839764 [master] Relocated "int k" declaration in pngtest.c
to work around a compiler optimization bug.
2010-01-26 06:51:00 -06:00
Glenn Randers-Pehrson
1a86bd2a09 [master] Revised png_decompress_chunk() to improve speed and memory
usage when decoding large chunks.
2010-01-22 22:50:46 -06:00
Glenn Randers-Pehrson
610e7b5bd6 [master] Added png_set|get_chunk_malloc_max() functions. 2010-01-22 19:48:40 -06:00
Glenn Randers-Pehrson
86f6c04d84 [master] Imported from libpng-1.4.1beta04.tar 2010-01-22 19:34:44 -06:00
Glenn Randers-Pehrson
fb3a1da4bb [master] Bump to version 1.4.1beta04 2010-01-22 19:29:47 -06:00
Glenn Randers-Pehrson
525efcbb7b [master] Imported from libpng-1.4.1rc01.tar 2010-01-16 08:05:12 -06:00
Glenn Randers-Pehrson
ea4340e1ec [master] Imported from libpng-1.4.1beta03.tar 2010-01-10 16:53:46 -06:00
Glenn Randers-Pehrson
91f3864fbd [master] Removed png_set_premultiply_alpha() from scripts/*.def
Implementation of this function was postponed.
2010-01-10 16:51:01 -06:00
Glenn Randers-Pehrson
14fa704caf [master] Imported from libpng-1.4.1beta02.tar 2010-01-09 13:13:30 -06:00
Glenn Randers-Pehrson
ad1f8180a5 [master] Updated makefiles to link to libpng14.so.14.1 2010-01-07 23:28:16 -06:00
Glenn Randers-Pehrson
e364f899af [master] Imported from libpng-1.4.1beta01.tar 2010-01-07 22:39:45 -06:00
Glenn Randers-Pehrson
40683870ea [master] Update PNG_LIBPNG_VER_NUM to 1.4.1 2010-01-07 22:27:30 -06:00
Glenn Randers-Pehrson
7569d7c069 [master] Updated documentation about png_set_compression_buffer_size(). 2010-01-07 11:37:53 -06:00
Glenn Randers-Pehrson
c87ddbb3ce [master] Make png_set|get_compression_buffer_size() available even
when PNG_WRITE_SUPPORTED is not enabled.  There was no good reason
for this restriction, and PNG readers can gain a speed benefit in
reading large iCCP chunks by increasing png_ptr->zbuf_size via
these functions.
2010-01-07 11:10:16 -06:00
Glenn Randers-Pehrson
793fedcf57 [master] Revise makefile.linux to build libpng.so.14.1 2010-01-07 11:00:07 -06:00
Glenn Randers-Pehrson
74fd86a69e [master] Updated copyright year in revised makefiles. 2010-01-07 08:19:31 -06:00
Glenn Randers-Pehrson
f234091207 [master] Restored "; \" that was lost from makefiles in the previous change 2010-01-07 08:14:16 -06:00
Glenn Randers-Pehrson
772b72139a [master] Revised the makefiles to install the same files and symbolic
links as configure, except for libpng.la and libpng14.la.
2010-01-06 23:11:53 -06:00
Glenn Randers-Pehrson
6e6a844baf [master] Revise scripts/makefile.linux to not make libpng.so.NN 2010-01-06 22:30:32 -06:00
Glenn Randers-Pehrson
2f2f80273b [master] Undid recent change to the Makefiles.
People don't need libpng.so.NN
2010-01-06 17:39:57 -06:00
Glenn Randers-Pehrson
353d8860ac [master] Revised scripts/makefile.linux to make the same files as configure,
except for libpng.la and libpng14.la.  Many other scripts to be fixed soon.
2010-01-06 14:45:03 -06:00
Glenn Randers-Pehrson
fab96cb72a [master] Revised Makefile.am and Makefile.in to make libpng.so.14,
libpng.sl.14, and libpng.14.dylib links in the installed library directory.
2010-01-06 14:16:49 -06:00
Glenn Randers-Pehrson
2203e41900 [master] Revised Makefile.am and Makefile.in to remove references to Y2KINFO,
KNOWNBUG, and libpng.la (Robert Schwebel).
2010-01-04 06:26:41 -06:00
Glenn Randers-Pehrson
e16f2bc5f7 [master] Updated CMakeLists.txt for consistent indentation and to avoid an
unclosed if-statement warning (Philip Lowman).
2010-01-04 06:25:28 -06:00
Glenn Randers-Pehrson
2381cf3269 [master] Bump to version 1.4.1beta01 2010-01-03 17:02:38 -06:00
Glenn Randers-Pehrson
7e3a82cd9c [master] Imported from libpng-1.4.0.tar 2010-01-02 23:15:33 -06:00
Glenn Randers-Pehrson
115817d118 [master] Imported from libpng-1.2.42.tar 2010-01-02 23:15:22 -06:00
Glenn Randers-Pehrson
5cfea4fc98 [master] Imported from libpng-1.2.42rc05.tar 2010-01-01 18:29:51 -06:00
Glenn Randers-Pehrson
a87c870f99 [master] Avoid deprecated references to png_ptr-io_ptr and png_ptr->error_ptr
in pngtest.c
2010-01-01 18:28:50 -06:00
Glenn Randers-Pehrson
b9d671326b [master] Imported from libpng-1.2.42rc04.tar 2010-01-01 10:50:04 -06:00
Glenn Randers-Pehrson
8e4e070151 [master] Updated copyright year to 2010 and made some trivial cosmetic changes 2010-01-01 10:48:33 -06:00
Glenn Randers-Pehrson
4607e1386f [master] Imported from libpng-1.2.42rc03.tar 2009-12-25 14:23:21 -06:00
Glenn Randers-Pehrson
9686172872 [master] Swapped PNG_UNKNOWN_CHUNKS_SUPPORTED and PNG_HANDLE_AS_UNKNOWN_SUPPORTED
in pngset.c to be consistent with other changes in version 1.2.38.
2009-12-25 14:22:08 -06:00
Glenn Randers-Pehrson
8563ac1664 [master] Bump to version 1.2.42rc03 2009-12-25 14:20:39 -06:00
Glenn Randers-Pehrson
9a80a35f4b [master] Imported from libpng-1.2.42rc02.tar 2009-12-23 07:43:15 -06:00
Glenn Randers-Pehrson
4cde19b0c9 [master] Renamed libpng-pc.in back to libpng.pc.in and revised CMakeLists.txt
(revising changes made in 1.2.41beta17 and 1.2.41rc01)
2009-12-22 08:09:39 -06:00
Glenn Randers-Pehrson
230e8b436f [master] Bump to version libpng-1.2.42rc02 2009-12-22 08:07:11 -06:00
Glenn Randers-Pehrson
dbb86efac3 [master] Imported from libpng-1.2.42rc01.tar 2009-12-17 05:53:39 -06:00
Glenn Randers-Pehrson
e8d28e1b1c [master] Bump to version 1.2.42rc01 2009-12-13 07:37:24 -06:00
Glenn Randers-Pehrson
a3a5d0d1f4 [master] Imported from libpng-1.2.42beta02.tar 2009-12-11 17:58:22 -06:00
Glenn Randers-Pehrson
4cf1ca4338 [master] Relocated png_do_chop() to its original position in pngrtran.c
The change in version 1.2.41beta08 caused transparency to be handled wrong
in some 16-bit datastreams (Yusaku Sugai).
2009-12-11 07:29:18 -06:00
Glenn Randers-Pehrson
f174f27096 [master] Removed leftover "-DPNG_CONFIGURE_LIBPNG"
from contrib/pngminim/*/makefile
2009-12-11 07:26:31 -06:00
Glenn Randers-Pehrson
1a15762c59 [master] Bump to version 1.2.42beta02 2009-12-11 07:21:54 -06:00
Glenn Randers-Pehrson
fec6a4ca4e [master] Removed leftover "-DPNG_CONFIGURE_LIBPNG" from scripts/makefile.darwin 2009-12-04 08:26:21 -06:00
Glenn Randers-Pehrson
bcc878bb81 [master] Imported from libpng-1.2.42beta01.tar 2009-12-04 07:16:38 -06:00
Glenn Randers-Pehrson
df61a00acc [master] Revised scripts/makefile.netbsd, makefile.openbsd, and makefile.sco
to put png.h and pngconf.h in $prefix/include, like the other scripts,
    instead of in $prefix/include/libpng.
2009-12-04 06:54:36 -06:00
Glenn Randers-Pehrson
878fea5403 [master] Removed "#define PNG_NO_ERROR_NUMBERS" that was inadvertently added
to pngconf.h in version 1.2.41.
2009-12-04 06:03:57 -06:00
Glenn Randers-Pehrson
804cc98cd1 [master] Bump to version 1.2.42beta01 2009-12-04 06:03:15 -06:00
Glenn Randers-Pehrson
6e00020a9f [master] Imported from libpng-1.2.41.tar 2009-12-02 19:48:27 -06:00
Glenn Randers-Pehrson
2aac9a1fa3 [master] Brought README up to date. 2009-11-27 15:48:31 -06:00
Glenn Randers-Pehrson
5aa8676122 [master] Bump to version 1.2.41rc04 2009-11-27 15:47:49 -06:00
Glenn Randers-Pehrson
ea88d94dcf [master] Imported from libpng-1.2.41rc03.tar 2009-11-25 16:00:51 -06:00
Glenn Randers-Pehrson
eaa1b0a5f2 [master] Removed test for PNG_CONFIGURE_LIBPNG from pngconf.h 2009-11-25 09:27:48 -06:00
Glenn Randers-Pehrson
de5c932283 [master] Disabled the new pedantic warnings
about deprecated function use and deprecated structure access unless the
user defines PNG_PEDANTIC_WARNINGS.  Added "#define PNG_NO_PEDANTIC_WARNINGS"
in the libpng source files.  Removed "-DPNG_CONFIGURE_LIBPNG" from the
makefiles and projects since the warnings no longer depend on this.
2009-11-25 08:51:04 -06:00
Glenn Randers-Pehrson
3b673e0fb0 [master] Bump to version libpng-1.2.41rc03 2009-11-25 08:42:36 -06:00
Glenn Randers-Pehrson
83b84d65c2 [master] Removed some trailing blanks
in Makefile.ac and Makefile.in
2009-11-22 11:37:19 -06:00
Glenn Randers-Pehrson
c31e04e2f8 [master] Rebuilt the configure scripts with autoconf-2.65 2009-11-22 08:55:10 -06:00
Glenn Randers-Pehrson
a460e00574 [master] Bump to version 1.2.41rc02 2009-11-22 08:31:00 -06:00
Glenn Randers-Pehrson
c593d488f9 [master] Imported from libpng-1.2.41rc01.tar 2009-11-18 09:58:36 -06:00
Glenn Randers-Pehrson
44a7c89e02 [master] Moved descriptions of makefiles and other scripts out of INSTALL
into scripts/README.txt
  and updated the copyright year in scripts/pngw32.rc from 2004 to 2009.
2009-11-15 08:31:00 -06:00
Glenn Randers-Pehrson
88bbbfa567 [master] Bump to version 1.2.41rc01 2009-11-14 07:41:19 -06:00
Glenn Randers-Pehrson
e3f9ce59eb [master] Bump to version 1.2.41beta20 2009-11-12 20:24:32 -06:00
Glenn Randers-Pehrson
12f0c2f580 [master] Imported from libpng-1.2.41beta19.tar 2009-11-12 20:11:04 -06:00
Glenn Randers-Pehrson
6099e57b07 [master] Restore pngtest.png, CHANGES, and ANNOUNCE to 1.2.41beta19 version. 2009-11-12 12:20:41 -06:00
Glenn Randers-Pehrson
e53ecd35c0 [master] Restored pngtest.png to the libpng-1.4.0beta7 version. 2009-11-12 12:16:23 -06:00
Glenn Randers-Pehrson
8397b45b20 [master] Removed reference to some non-exported functions from scripts/*.def
These functions won't be exported until libpng-1.4.0
2009-11-12 11:31:09 -06:00
Glenn Randers-Pehrson
bcb1b414ed [master] Fixed up some line-wrapping in the documentation. 2009-11-12 11:30:03 -06:00
Glenn Randers-Pehrson
bef02a89ea [master] Bump to version 1.2.41beta19 2009-11-11 15:09:22 -06:00
Glenn Randers-Pehrson
1aae1bf9fd [master] Updated CHANGES and ANNOUNCE about PNG_PRIVATE macro. 2009-11-11 15:03:20 -06:00
Glenn Randers-Pehrson
078f2aecfb [master] Imported from libpng-1.2.41beta18.tar 2009-11-11 14:26:32 -06:00
Glenn Randers-Pehrson
c87f913eb9 [master] Marked "internally exported" functions with PNG_PRIVATE. 2009-11-11 14:24:27 -06:00
Glenn Randers-Pehrson
a5fc3eb9d4 [master] Bump to version libpng-1.2.41beta18 2009-11-11 14:21:39 -06:00
Glenn Randers-Pehrson
780dc06584 [master] Renamed scripts/makefile.wce to scripts/makefile.cegcc 2009-11-10 09:30:18 -06:00
Glenn Randers-Pehrson
365cddf35f [master] Bump to version libpng-1.2.41rc01 2009-11-10 09:25:53 -06:00
Glenn Randers-Pehrson
c099ea497a [master] Imported from libpng-1.2.41beta17.tar 2009-11-10 06:11:31 -06:00
Glenn Randers-Pehrson
336b43d278 [master] Moved "rm pnggccrd.c pnggvrd.c" to a separate line
in contrib/pngminim/*/gather.sh
2009-11-09 13:42:16 -06:00
Glenn Randers-Pehrson
08e585d948 [master] Added "-DPNG_CONFIGURE_LIBPNG" to the contrib/pngminum makefiles. 2009-11-09 11:20:01 -06:00
Glenn Randers-Pehrson
7aacd895ee [master] Fixed deprecated usages in contrib directory. 2009-11-09 10:47:12 -06:00
Glenn Randers-Pehrson
3130af0e2b [master] Fixed a typo in a comment in CMakeLists.txt 2009-11-09 08:31:05 -06:00
Glenn Randers-Pehrson
02a58af3c0 [master] Marked memory allocation function prototypes with PNG_ALLOCATED. 2009-11-09 08:25:36 -06:00
Glenn Randers-Pehrson
86645a3f19 [master] Marked deprecated function prototypes with PNG_DEPRECATED. 2009-11-09 08:10:22 -06:00
Glenn Randers-Pehrson
edc3994cfd [master] In CMakeLists.txt, add "-DPNG_CONFIGURE_LIBPNG" to the definitions. 2009-11-09 07:18:26 -06:00
Glenn Randers-Pehrson
71f29b701d [master] Bump to version 1.2.41beta17 2009-11-09 06:50:36 -06:00
Glenn Randers-Pehrson
b4b853b4c5 [master] Imported from libpng-1.2.41beta16.tar 2009-11-09 06:50:25 -06:00
Glenn Randers-Pehrson
d5483f3352 [master] Make PNG_DEPSTRUCT, etc., configurable.
Only #define PNG_DEPSTRUCT, etc. in pngconf.h if not already defined.
2009-11-08 20:37:37 -06:00
Glenn Randers-Pehrson
2522de8594 [master] Restore new pngtest.c 2009-11-08 20:07:41 -06:00
Glenn Randers-Pehrson
e5e60564cf [master] Bump to version 1.2.41beta16 2009-11-08 20:06:21 -06:00
Glenn Randers-Pehrson
bf2dabe6f1 [master] Removed three direct references to read_info_ptr members
in pngtest.c that were detected by the new PNG_DEPSTRUCT macro.
2009-11-08 20:01:55 -06:00
Glenn Randers-Pehrson
70c873bcac [master] Remove some extra text from CHANGES 2009-11-08 19:55:14 -06:00
Glenn Randers-Pehrson
5aabf5b8eb [master] Imported from libpng-1.2.41beta15.tar 2009-11-08 19:31:21 -06:00
Glenn Randers-Pehrson
20e82ae2a2 [master] Added deprectated-use reporting
ported from libpng-1.4.0
2009-11-08 19:18:45 -06:00
Glenn Randers-Pehrson
e890cb118c [master] Bump to version bump-to-1.2.41beta15.tar 2009-11-08 17:05:27 -06:00
Glenn Randers-Pehrson
275d1aa94e [master] Imported from libpng-1.2.41beta14.tar 2009-11-08 17:05:18 -06:00
Glenn Randers-Pehrson
f748fda0ed [master] Reverted iTXt compatibility stuff
from 1.2.41beta05, 1.2.41beta11, and 1.2.41beta12.
2009-11-08 16:51:11 -06:00
Glenn Randers-Pehrson
87480bf6d4 [master] Removed reference to png_calloc from scripts/*.def 2009-11-08 15:15:37 -06:00
Glenn Randers-Pehrson
bd6f1edea8 [master] Update png.h and pngconf.h to revert iTXt support. 2009-11-08 15:14:32 -06:00
Glenn Randers-Pehrson
ed4c9fc4e9 [master] Remove mention of empty pngpriv.h in CHANGES 2009-11-03 19:18:56 -06:00
Glenn Randers-Pehrson
8f8be84024 [master] Removed the empty pngpriv.h
due to popular demand.
2009-11-03 19:13:59 -06:00
Glenn Randers-Pehrson
ead562ed05 [master] Make PNG_CONVERT_tIME_SUPPORTED depend on PNG_WRITE_tIME_SUPPORTED 2009-11-03 12:28:14 -06:00
Glenn Randers-Pehrson
8cf8726c7c [master] Make #define PNG_CONVERT_tIME_SUPPORTED depend on PNG_tIME_SUPPORTED 2009-11-03 11:42:47 -06:00
Glenn Randers-Pehrson
b83df4e711 [master] Added empty pngpriv.h file
as an aid to migration to 1.4.x
2009-11-03 10:10:20 -06:00
Glenn Randers-Pehrson
7e64470a71 [master] Bump version to libpng-1.2.41beta14 2009-11-03 07:05:11 -06:00
Glenn Randers-Pehrson
fd3d717df5 [master] Imported from libpng-1.2.41beta13.tar 2009-11-03 06:53:07 -06:00
Glenn Randers-Pehrson
d4ebb803fa [master] Added scripts/makefile.wce and scripts/png32ce.def
to support WindowsCE.
2009-11-02 21:03:14 -06:00
Glenn Randers-Pehrson
5d276731e6 [master] Use the new PNG_CONVERT_tIME_SUPPORTED macro in pngwrite.c. 2009-11-02 11:35:26 -06:00
Glenn Randers-Pehrson
6dcfbc479d [master] Added PNG_CONVERT_tIME_SUPPORTED macro. 2009-11-02 11:26:10 -06:00
Glenn Randers-Pehrson
d8bf20d9ac [master] Updated scripts/pngw32.def and added CE support to ltmain.sh 2009-11-02 09:19:11 -06:00
Glenn Randers-Pehrson
38453101f0 [master] Bump version to 1.2.41beta13 2009-11-02 06:26:40 -06:00
Glenn Randers-Pehrson
8e46375186 [master] Free png_ptr->user_png_ver when destroying png_ptr. 2009-11-02 06:04:47 -06:00
Glenn Randers-Pehrson
c75d7fb32e [master] Bump version to 1.2.41beta12 2009-11-02 05:54:39 -06:00
Glenn Randers-Pehrson
6e0cf087ad [master] Imported from libpng-1.2.41beta11.tar 2009-11-01 21:46:17 -06:00
Glenn Randers-Pehrson
af9a41d770 [master] Store user's user_png_ver in new png_ptr->user_png_ver element.
Revised iTXt support. To ensure binary compatibility with
previous versions, the "lang" and "lang_key" members will be assumed
to be omitted from versions prior to 1.2.41beta11 whenever there is a
library mismatch.
2009-11-01 21:22:01 -06:00
Glenn Randers-Pehrson
d6dc43db7d [master] Removed some dead code from pngconf.h
(inside an #if 0/#endif block)
2009-11-01 16:41:09 -06:00
Glenn Randers-Pehrson
4c49647788 [master] Revise pngconf.h (iTXt handling)
and avoid reference to time.h "tm" structure in png.h and pngwrite.c
2009-11-01 16:32:57 -06:00
Glenn Randers-Pehrson
3de7bde0e1 [master] Revised iTXt support and documentation 2009-11-01 08:47:04 -06:00
Glenn Randers-Pehrson
dc38e24fed [master] Bump version to 1.2.41beta11 2009-10-31 23:29:58 -05:00
Glenn Randers-Pehrson
a61724c004 [master] Imported from libpng-1.2.41beta10.tar 2009-10-31 23:24:15 -05:00
Glenn Randers-Pehrson
29b738b4e6 [master] Enabled iTXt support by default.
To ensure binary compatibility with
    previous versions, the "lang" and "lang_key" members will be assumed
    to be omitted from previous versions unless the current libpng
    version was built with PNG_iTXt_SUPPORTED (which is otherwise no
    longer necessary to gain iTXt support), as a signal that the user has
    been building previous versions with PNG_iTXt_SUPPORTED as well.
2009-10-31 23:20:11 -05:00
Glenn Randers-Pehrson
602d314ba0 [master] Bump version to libpng-1.2.41beta10 2009-10-31 21:43:03 -05:00
Glenn Randers-Pehrson
a68974409c [master] Imported from libpng-1.2.41beta09.tar 2009-10-31 21:42:50 -05:00
Glenn Randers-Pehrson
5d67107c79 [master] Fix typo in pngconf.h 2009-10-31 21:32:42 -05:00
Glenn Randers-Pehrson
da9b591621 [master] Updated documentation
Merged libpng-1.2.41.txt with libpng-1.4.0.txt where appropriate.
2009-10-31 19:21:30 -05:00
Glenn Randers-Pehrson
2e8aa25844 [master] Apply png_user_chunk_cache_max within png_decompress_chunk(). 2009-10-31 19:20:20 -05:00
Glenn Randers-Pehrson
6611322a8b [master] Moved CMakeLists.txt from scripts
into the main libpng directory.  More bugfixes and improvements to
CMakeLists.txt (Philip Lowman)
2009-10-31 12:50:05 -05:00
Glenn Randers-Pehrson
948c6ee88d [master] Removed a harmless extra png_set_invert_alpha()
from pngwrite.c
2009-10-31 12:28:23 -05:00
Glenn Randers-Pehrson
b7a9d80f28 [master] Bump version to libpng-1.2.41beta09 2009-10-30 06:54:53 -05:00
Glenn Randers-Pehrson
277f6fbe49 [master] Revert version to 1.2.41beta08 2009-10-30 06:14:45 -05:00
Glenn Randers-Pehrson
e05080f5a8 [master] Added png_get_user_cache_max()
and png_set_user_cache_max() from libpng-1.4.0rc01.
2009-10-30 05:49:16 -05:00
Glenn Randers-Pehrson
4de250dd75 [master] Put new png_struct members at the end. 2009-10-30 05:41:34 -05:00
Glenn Randers-Pehrson
8f2f7f431c [master] Bump version to 1.2.41beta09 2009-10-30 00:10:54 -05:00
Glenn Randers-Pehrson
4f67b78853 [master] Imported from libpng-1.2.41beta08.tar 2009-10-29 23:54:16 -05:00
Glenn Randers-Pehrson
4b14b35208 [master] Ported functions from libpng-1.4.0rc01:
png_calloc(), png_get_io_state(),
    png_get_io_chunk_name(), png_set_premultiply_alpha, and
    png_do_read_premultiply_alpha().
2009-10-29 23:47:05 -05:00
Glenn Randers-Pehrson
bc2ab12f99 [master] Bump version to 1.2.41beta08 2009-10-29 23:41:29 -05:00
Glenn Randers-Pehrson
c3166b2a48 [master] Imported from libpng-1.2.41beta07.tar 2009-10-21 10:42:32 -05:00
Glenn Randers-Pehrson
1eef1e5b2f [master} Ported some cosmetic changes from libpng-1.4.0rc01
changing "#if defined(x)" to "#ifdef x" in png.h and pngconf.h.
2009-10-21 10:32:04 -05:00
Glenn Randers-Pehrson
8191965555 [master] Fixed "DATE" comment in pngrtran.c 2009-10-19 06:39:35 -05:00
Glenn Randers-Pehrson
f1c9244dfd [master] Bump version to 1.2.41beta07 2009-10-18 14:38:38 -05:00
Glenn Randers-Pehrson
58155a9921 [master] Imported from libpng-1.2.41beta06.tar 2009-10-18 14:36:31 -05:00
Glenn Randers-Pehrson
5d398a69fb [master] Converted all PNG_NO_* tests to PNG_*_SUPPORTED
everywhere except pngconf.h as in libpng-1.4.0beta78 and later.
2009-10-18 14:30:53 -05:00
Glenn Randers-Pehrson
4560de58f4 [master] Update CHANGES and ANNOUNCE 2009-10-18 08:07:48 -05:00
Glenn Randers-Pehrson
7f9f605781 [master] Restored PNG_USE_LOCAL_ARRAYS block of pngread.c
that was inadvertently deleted by the previous checkin.
2009-10-18 08:03:07 -05:00
Glenn Randers-Pehrson
41cad5fbed [master] Bump version to 1.2.41beta06 2009-10-17 19:20:53 -05:00
Glenn Randers-Pehrson
e4f15b0f0e [master] Ported cosmetic changes to pngread.c
from libpng-1.4.0beta87.
2009-10-17 19:02:45 -05:00
Glenn Randers-Pehrson
d4e3ef6eae [master] Ported cosmetic changes to pngwrite.c
from libpng-1.4.0beta87.
2009-10-17 18:30:44 -05:00
Glenn Randers-Pehrson
eda90ace80 [master] Port cosmetic changes in png.c
from libpng-1.4.0beta87
2009-10-13 20:12:37 -05:00
Glenn Randers-Pehrson
0c127348e1 [master] Ported cosmetic changes in pngrtran.c
from libpng-1.4.0beta87
2009-10-13 18:31:01 -05:00
Glenn Randers-Pehrson
eb6b59af64 [master] Fixed some indentation in pngrtran.c 2009-10-13 18:29:46 -05:00
Glenn Randers-Pehrson
11066e33f8 [master] Port cosmetic changes in pngrutil.c
from libpng-1.4.0beta87
2009-10-13 09:09:11 -05:00
Glenn Randers-Pehrson
51a32d64d8 [master] Ported cosmetic changes in pngpread.c and pngrtran.c
from libpng-1.4.0beta87.
2009-10-12 13:41:14 -05:00
Glenn Randers-Pehrson
77a9f59487 [master] Ported some cosmetic changes from libpng-1.4.0beta87/pngrutil.c,
changing many "#if defined(x)" to "#ifdef x".
2009-10-11 08:26:03 -05:00
Glenn Randers-Pehrson
1814c4e45b [master] Imported from libpng-1.2.41beta05.tar 2009-10-11 07:49:17 -05:00
Glenn Randers-Pehrson
722f5fd8d4 [master] Ported some cosmetic changes from libpng-1.4.0beta87
changing many "#if defined(x)" to "#ifdef x" in pngtest.c and pngwutil.c.
2009-10-10 09:27:12 -05:00
Glenn Randers-Pehrson
e9c8dcf96c [master] Revised pngconf.h to make it easier to enable iTXt support
by defining PNG_iTXT_SUPPORTED
2009-10-10 08:13:01 -05:00
Glenn Randers-Pehrson
89e0d95883 [master] Bump version to 1.2.41beta05 2009-10-10 06:29:47 -05:00
Glenn Randers-Pehrson
aeb9906717 [master] Imported from libpng-1.2.41beta04.tar 2009-10-10 06:29:36 -05:00
Glenn Randers-Pehrson
368971ec8b [master] Eliminated a shadowed declaration
of "pp" in png_handle_sPLT().
2009-10-07 12:48:44 -05:00
Glenn Randers-Pehrson
0112826daf [master] Change xcode project library name
from libpng.0.dylib to libpng.3.dylib to be consistent with makefile.darwin.
2009-10-05 14:56:46 -05:00
Glenn Randers-Pehrson
9023e8f7bb [master] Ported some cosmetic changes from the devel branch 2009-10-05 13:53:19 -05:00
Glenn Randers-Pehrson
48fac4e8ce [master] Added projects/xcode/libpng.xcodeproj/.gitignore 2009-10-04 16:01:53 -05:00
Glenn Randers-Pehrson
edeccce619 [master] Added "xcode" project
similar one already in libpng-1.4.0beta (Alam Arias).
2009-10-02 14:12:54 -05:00
Glenn Randers-Pehrson
60668aa210 [master] Bump version to 1.2.4beta04 2009-10-02 09:41:34 -05:00
Glenn Randers-Pehrson
455e8a4281 [master] Imported from libpng-1.2.41beta03.tar 2009-09-30 23:14:24 -05:00
Glenn Randers-Pehrson
5d7fe7a718 [master] Revised png_check_IHDR() again
to check info_ptr members instead of the contents of the returned parameters.
2009-09-30 23:10:28 -05:00
Glenn Randers-Pehrson
64ca95e375 [master] Bump version to 1.2.41beta03 2009-09-30 16:03:06 -05:00
Glenn Randers-Pehrson
837eecbc91 [master] Revised png_check_IHDR()
to avoid bogus complaints about filter method.
2009-09-30 14:45:33 -05:00
Glenn Randers-Pehrson
26cc10a00c [master] Reverted recent test in png_get_IHDR(). 2009-09-30 14:35:05 -05:00
Glenn Randers-Pehrson
f12abe957d [master] Revised png_check_IHDR() 2009-09-30 14:29:00 -05:00
Glenn Randers-Pehrson
caaf688582 [master] Imported from libpng-1.2.41beta02.tar 2009-09-30 13:40:53 -05:00
Glenn Randers-Pehrson
3dfd0cd62a [master] Add a test to make sure the user isn't trying to stuff height into
a 16-bit int (assuming height immediately follows width).
2009-09-30 13:38:37 -05:00
Glenn Randers-Pehrson
18bd86f154 [master] Revise documentation to mention not using TAB character 2009-09-25 14:21:52 -05:00
Glenn Randers-Pehrson
338f465019 [master] Expand TAB characters in pngrtran.c 2009-09-25 14:11:33 -05:00
Glenn Randers-Pehrson
ac13f5e6f9 [master] Imported from libpng-1.2.41beta01.tar 2009-09-25 12:07:58 -05:00
Glenn Randers-Pehrson
1b6f6d80ea [master] Imported from libpng-1.2.40.tar 2009-09-10 09:01:41 -05:00
Glenn Randers-Pehrson
18b078414a [master] Imported from libpng-1.2.40rc01.tar 2009-09-02 07:09:11 -05:00
Glenn Randers-Pehrson
f6ce318061 [master] CMakeLists.txt updated with bugfixes and improvements 2009-08-28 07:06:45 -05:00
Glenn Randers-Pehrson
a21c94e3dc [master] Bump version to libpng-1.2.40beta02 2009-08-22 09:26:42 -05:00
Glenn Randers-Pehrson
38b92d56e7 [master] Imported from libpng-1.2.40beta01.tar 2009-08-20 17:39:42 -05:00
Glenn Randers-Pehrson
a08d95b971 [master] Fixed incorrect #ifdef in pngset.c
PNG_UNKNOWN_CHUNKS_SUPPORTED should be PNG_HANDLE_AS_UNKNOWN_SUPPORTED
2009-08-20 16:13:58 -05:00
Glenn Randers-Pehrson
339416b38b [master] Trivial cosmetic changes in comments 2009-08-19 08:42:06 -05:00
Glenn Randers-Pehrson
7e2f07486a [master] Remove an extra png_debug() statement
that was recently added to png_write_find_filter() in pngwutil.c
2009-08-13 17:54:20 -05:00
Glenn Randers-Pehrson
a3e569cdda [master] Bump libpng.3 and ANNOUNCE to version 1.2.40beta01 2009-08-13 17:52:49 -05:00
Glenn Randers-Pehrson
d68d8d82e6 [master] Bump version to libpng-1.2.40beta01 2009-08-13 17:41:35 -05:00
Glenn Randers-Pehrson
997b4a544d [master] Update ANNOUNCE to mention .tar.xz instead of .tgz 2009-08-13 06:15:22 -05:00
Glenn Randers-Pehrson
176d2b622e [master] Imported from libpng-1.2.39.tar 2009-08-13 05:51:34 -05:00
Glenn Randers-Pehrson
3a9ab23713 [master] Imported from libpng-1.2.39rc01.tar 2009-08-05 21:26:48 -05:00
Glenn Randers-Pehrson
9e88fcd58c [master] Imported from libpng-1.2.39beta05.tar 2009-08-01 08:57:10 -05:00
Glenn Randers-Pehrson
39ffc1c3c7 [master] Imported from libpng-1.2.39beta04.tar 2009-08-01 08:57:08 -05:00
Glenn Randers-Pehrson
69d0e44295 [master] Imported from libpng-1.2.39beta03.tar 2009-07-29 05:50:25 -05:00
Glenn Randers-Pehrson
d2d5e540ac [master] Update configure scripts to autoconf-2.64 2009-07-28 16:51:57 -05:00
Glenn Randers-Pehrson
d7bd2d2b2c [master] Relocated prototype for png_64bit_product()
into png.h and revised the documenatation (in the libpng style section) about
placement of prototypes.
2009-07-28 08:18:31 -05:00
Glenn Randers-Pehrson
ddf5fc8a42 [master] Bump version to libpng-1.2.39beta03 2009-07-28 08:05:11 -05:00
Glenn Randers-Pehrson
0841c63e0d [master] Imported from libpng-1.2.39beta02.tar 2009-07-27 22:31:10 -05:00
Glenn Randers-Pehrson
a4d439b975 [master] Avoid a possible NULL dereference in debug build,
in png_set_text_2() (bug introduced in libpng-0.95, discovered by Evan Rouault)
2009-07-27 22:27:30 -05:00
Glenn Randers-Pehrson
8de509a837 [master] Bump version to libpng-1.2.39beta02 2009-07-27 22:26:15 -05:00
Glenn Randers-Pehrson
219760639a [master] Imported from libpng-1.2.39beta01.tar 2009-07-25 09:27:58 -05:00
Glenn Randers-Pehrson
38ed8795ab [master] Added a prototype for png_16bit_product()
(suggested by Peter Breitenlohner)
2009-07-23 13:18:55 -05:00
Glenn Randers-Pehrson
55697d7dc9 [master] Update some dates. 2009-07-23 13:17:27 -05:00
Glenn Randers-Pehrson
a7fb782aea [master] Bump version to libpng-1.2.39beta01 2009-07-23 13:01:03 -05:00
Glenn Randers-Pehrson
d91c64e428 [master] Imported from libpng-1.2.38.tar 2009-07-16 06:01:45 -05:00
Glenn Randers-Pehrson
4aa911abc6 [master] Imported from libpng-1.2.38rc03.tar 2009-07-11 09:16:28 -05:00
Glenn Randers-Pehrson glennrp@comcast.net
64c72bb919 [master] Updated configuration scripts to autoconf-2.63
from autoconf-2.62
2009-07-11 09:07:35 -05:00
Glenn Randers-Pehrson glennrp@comcast.net
fec191d3cc [master] Revised references to libpng license in contrib/visupng
to be consistent with the rest of the source files.
2009-07-11 07:13:56 -05:00
Glenn Randers-Pehrson
7430bcbc44 [master] Add a reference to the "libpng license" in each source file. 2009-06-28 21:38:35 -05:00
Glenn Randers-Pehrson
eba11d2ba5 [master] Imported from libpng-1.2.38rc02.tar 2009-06-28 20:28:53 -05:00
Glenn Randers-Pehrson
a3a724f805 [master] Imported from libpng-1.2.38rc01.tar 2009-06-24 06:59:36 -05:00
Glenn Randers-Pehrson
a770d71890 [master] Bump version to bump-to-libpng-1.2.38beta02 2009-06-18 16:53:56 -05:00
Glenn Randers-Pehrson
1de866cd09 [master] Imported from libpng-1.2.38beta01.tar 2009-06-17 07:46:44 -05:00
Glenn Randers-Pehrson
54380f53a2 [master] Fixed some indentation in pngset.c 2009-06-16 17:53:00 -05:00
Glenn Randers-Pehrson
7d870524d3 [master] Changed PNG_HANDLE_AS_UNKNOWN to PNG_UNKNOWN_CHUNKS_SUPPORTED
in pngset.c
2009-06-16 17:28:01 -05:00
Glenn Randers-Pehrson
d28aad9a58 [master] Added an "#ifdef PNG_WRITE_SUPPORTED/#endif" block in pngconf.h 2009-06-16 17:27:14 -05:00
Glenn Randers-Pehrson
8be63adbc8 [master] Relocated various UNKNOWN_CHUNK macro definitions
outside of the PNG_READ|WRITE_ANCILLARY_CHUNK_SUPPORTED macros and
updated CHANGES and ANNOUNCE.  The definitions were actually relocated
in the previous commit but I forgot to mention it.
2009-06-16 16:13:42 -05:00
Glenn Randers-Pehrson
7d8f352e0a Added a PNG_NO_HANDLE_AS_UNKNOWN inside the LEGACY block of pngconf.h 2009-06-16 13:54:57 -05:00
Glenn Randers-Pehrson
587382c0ba [master] Added 2 "defined(PNG_HANDLE_AS_UNKNOWN_SUPPORTED)" tests in png.h 2009-06-16 13:35:47 -05:00
Glenn Randers-Pehrson
0f714ca6bc [master] Reformatted some comments. 2009-06-15 22:01:39 -05:00
Glenn Randers-Pehrson
63da1df6fe [master] png.c should have been included in the previous checkin 2009-06-15 20:58:37 -05:00
Glenn Randers-Pehrson
bbe589da44 [master] Change some instances of PNG_READ_UNKNOWN_CHUNKS_SUPPORTED
to PNG_HANDLE_AS_UNKNOWN to make it possible to build a libpng that can
use the png_set_keep_unknown_chunks() mechanism to ignore unused chunks
without having to save unknown chunks.
2009-06-15 20:50:00 -05:00
Glenn Randers-Pehrson
b278e91338 about calling png_set_IHDR() multiple times and about the order
of color samples in the tRNS chunk.
2009-06-08 08:37:58 -05:00
Glenn Randers-Pehrson
f2609e133d [master] Revise libpng*.txt
about calling png_set_IHDR() multiple times and about the order
of color samples in the tRNS chunk.
2009-06-08 08:33:46 -05:00
Glenn Randers-Pehrson
e14fdbbddb [master] Bump version to bump-to-libpng-1.2.38beta01 2009-06-05 17:27:14 -05:00
Glenn Randers-Pehrson
a162155919 Imported from libpng-1.2.37.tar 2009-06-04 06:11:58 -05:00
Glenn Randers-Pehrson
4d7ae382a8 [master] Added a section in documentation
about using png_set_io_ptr() in configure scripts for detecting libpng
2009-06-02 13:48:22 -05:00
Glenn Randers-Pehrson
0c86eb2dc7 Update pngminim/*/pngusr.h
to add PNG_NO_READ_SWAP, PNG_NO_WRITE_SWAP
2009-06-02 06:50:00 -05:00
Glenn Randers-Pehrson
70c2db8b9f Updated documentation about the git repository and libpng coding style. 2009-06-02 06:41:57 -05:00
Glenn Randers-Pehrson
c1dd118d2c Reformatted several "if () statment;"
and "else statement;" into two lines.
2009-05-30 20:25:20 -05:00
Glenn Randers-Pehrson
2d21d91abd Imported from libpng-1.2.37rc01.tar 2009-05-27 06:47:59 -05:00
Glenn Randers-Pehrson
e5ee05dc0d Imported from libpng-1.2.37beta03.tar 2009-05-20 17:19:00 -05:00
Glenn Randers-Pehrson
c0d53e176b Change version from libpng-1.2.37rc01 to libpng-1.2.37beta03
Because of many cosmetic changes, drop back to beta and do rc01 later.
2009-05-20 17:16:46 -05:00
Glenn Randers-Pehrson
b26d188190 Rename contrib/pngminim/*/makefile.std to makefile. 2009-05-19 18:51:08 -05:00
Glenn Randers-Pehrson
0a6382e2af Bump version to libpng-1.2.37rc01 2009-05-19 18:48:06 -05:00
Glenn Randers-Pehrson
1214d8cd26 Fix "AVE" -> "AVG" typo in libpng docs again.
Evidently the fix didn't go into the real master copy.
2009-05-19 07:18:06 -05:00
Glenn Randers-Pehrson
65a30ab0a2 Imported from libpng-1.2.37beta02.tar 2009-05-19 07:05:20 -05:00
Glenn Randers-Pehrson
61616abef2 Fixed cut-and-paste error in contrib/pngminim/preader/README
"pngminus" should be "gregbook"
2009-05-18 15:19:29 -05:00
Glenn Randers-Pehrson
bb1fcd1ba8 Fixed a glitch in contrib/pngminim/preader/README. 2009-05-18 14:57:07 -05:00
Glenn Randers-Pehrson
6d65121993 Add contrib/pngminim/preader files
(README, gather.sh, makefile.std, and pngusr.h)
2009-05-18 14:50:48 -05:00
Glenn Randers-Pehrson
ecf0bffb79 Added contrib/pngminim/preader demo of gregbook/rpng2-x with embedded libpng
also minor editing of encoder/pngusr.h and decoder/pngusr.h
2009-05-18 14:46:35 -05:00
Glenn Randers-Pehrson
af2ea0a1f2 Revise ANNOUNCE to reflect conditional compile of png_read_finish_row(). 2009-05-18 14:43:36 -05:00
Glenn Randers-Pehrson
286467db82 Restored compiling png_combine_row() for progressive readers.
Only png_read_finish_row() can be omitted.
2009-05-18 13:40:23 -05:00
Glenn Randers-Pehrson
6b60a31ebf Restore png_memset() call
This stuff should be handled in the APNG fork.
2009-05-18 11:55:55 -05:00
Glenn Randers-Pehrson
54028e5943 Revert "png_reset_prev_row" from png.h and pngrutil.c
This should be handled in the APNG fork, not in libpng proper.
2009-05-18 11:49:19 -05:00
Glenn Randers-Pehrson
0c062e839d Conditionally compile png_combine_row() and png_read_finish_row()
which are only used by sequential PNG readers.  This can save some
resources in applications that only do progressive reading.
2009-05-18 10:31:21 -05:00
Glenn Randers-Pehrson
0fcbf05b6d Revert "Set png_ptr->old_prev_row_size=0 to force prev_row to be cleared"
This reverts commit f4276c36c9.
2009-05-18 10:18:00 -05:00
Glenn Randers-Pehrson
f4276c36c9 Set png_ptr->old_prev_row_size=0 to force prev_row to be cleared 2009-05-16 08:47:20 -05:00
Glenn Randers-Pehrson
ba05bddf92 Relocate misplaced #endif directives in pngwrite.c
having to do with sCAL chunk handling
2009-05-16 08:40:25 -05:00
Glenn Randers-Pehrson glennrp@comcast.net
7a63d75a83 Fixed typo in libpng documentation: AVE filter should be AVG filter. 2009-05-15 20:56:43 -05:00
Glenn Randers-Pehrson glennrp@comcast.net
da3f74a70e Bump version to libpng-1.2.37beta02 2009-05-15 20:53:04 -05:00
Glenn Randers-Pehrson
5f26656fc5 Imported from libpng-1.2.37beta01.tar 2009-05-14 05:23:07 -05:00
Glenn Randers-Pehrson
2f76e90d1a Reformatted comments in example.c
Added advice about setting pointers to NULL after png_free(),
capitalized sentences, reformatted long comments in libpng style.
2009-05-13 15:20:53 -05:00
Glenn Randers-Pehrson
1296329f02 Revised commentary in example.c 2009-05-13 07:42:05 -05:00
Glenn Randers-Pehrson
e38b432846 Clarified usage of sig_bit as struct vs sig_bit_p as pointer in example.c
sig_bit was not declared in write_png() and was used differently from
sig_bit in read_png(), as reported by Vincent Torri.  This update changes
sig_bit to sig_bit_p in read_png() and declares sig_bit in write_png().
2009-05-13 05:18:48 -05:00
Glenn Randers-Pehrson
549a5101e7 Fixed inconsistency in use of "row_bytes" in pngrutil.c
The memset() should use "row_bytes" instead of "png_ptr->rowbytes".
This bug was introduced in libpng-1.2.36.
2009-05-12 05:49:10 -05:00
Glenn Randers-Pehrson glennrp@comcast.net
031a8648cb Merged scripts/makefiles and other scripts with libpng-1.4.0beta57.
These are mostly just cosmetic changes.
2009-05-07 17:12:33 -05:00
Glenn Randers-Pehrson glennrp@comcast.net
a8476a8404 Bump internal version to libpng-1.2.37beta01. 2009-05-07 17:09:14 -05:00
Glenn Randers-Pehrson
25c8491fc8 Imported from libpng-1.2.36.tar 2009-05-07 10:59:02 -05:00
Glenn Randers-Pehrson
d0d637dd47 Imported from libpng-1.2.36rc01.tar 2009-04-30 15:29:29 -05:00
Glenn Randers-Pehrson
977c6bd44c Imported from libpng-1.2.36beta05.tar 2009-04-24 15:09:41 -05:00
Glenn Randers-Pehrson
89ad3aa168 Suppress "shadowed declaration" warnings about "gamma" in pngset.c
The variable "gamma" is also defined in math.h on some platforms.
2009-04-20 13:23:24 -05:00
Glenn Randers-Pehrson
55b921dab2 Suppress "shadowed declaration" warnings in pngtest.c
Changed some local variable names such as "buffer" to "buff".
2009-04-20 13:12:07 -05:00
Glenn Randers-Pehrson
92d0fe938f Add PNG_SKIP_SETJMP_CHECK macro 2009-04-20 13:07:01 -05:00
Glenn Randers-Pehrson
d07e9b03c4 Bump versioning to 1.2.36beta05 2009-04-20 13:02:18 -05:00
Glenn Randers-Pehrson
6cbd1cba68 Imported from libpng-1.2.36beta04.tar 2009-04-06 16:18:42 -05:00
Glenn Randers-Pehrson
3b8df1f143 Imported from libpng-1.2.36beta03.tar 2009-04-06 16:18:40 -05:00
Glenn Randers-Pehrson
85f7d0a8d5 Imported from libpng-1.2.36beta02.tar 2009-04-06 16:18:37 -05:00
Glenn Randers-Pehrson
556450a2ff Imported from libpng-1.2.36beta01.tar 2009-04-06 16:18:34 -05:00
Glenn Randers-Pehrson
6048b12510 Imported from libpng-1.2.35.tar 2009-04-06 16:18:32 -05:00
Glenn Randers-Pehrson
8cafc1e1ac Imported from libpng-1.2.35rc02.tar 2009-04-06 16:18:30 -05:00
Glenn Randers-Pehrson
51807d7608 Imported from libpng-1.2.35rc01.tar 2009-04-06 16:18:28 -05:00
Glenn Randers-Pehrson
e104df5bb7 Imported from libpng-1.2.35beta03.tar 2009-04-06 16:18:26 -05:00
Glenn Randers-Pehrson
c6df7e5899 Imported from libpng-1.2.35beta02.tar 2009-04-06 16:18:23 -05:00
Glenn Randers-Pehrson
d0a4300dde Imported from libpng-1.2.35beta01.tar 2009-04-06 16:18:21 -05:00
Glenn Randers-Pehrson
d8865433f9 Imported from libpng-1.2.34.tar 2009-04-06 16:18:19 -05:00
Glenn Randers-Pehrson
9c2bd642ba Imported from libpng-1.2.34rc01.tar 2009-04-06 16:18:17 -05:00
Glenn Randers-Pehrson
09883db208 Imported from libpng-1.2.34beta07.tar 2009-04-06 16:18:14 -05:00
Glenn Randers-Pehrson
f7f68f7160 Imported from libpng-1.2.34beta06.tar 2009-04-06 16:18:12 -05:00
Glenn Randers-Pehrson
31f744a8c0 Imported from libpng-1.2.34beta05.tar 2009-04-06 16:18:10 -05:00
Glenn Randers-Pehrson
bc66c96275 Imported from libpng-1.2.34beta04.tar 2009-04-06 16:18:07 -05:00
Glenn Randers-Pehrson
87c2acdeae Imported from libpng-1.2.34beta03.tar 2009-04-06 16:18:05 -05:00
Glenn Randers-Pehrson
6b90023764 Imported from libpng-1.2.34beta02.tar 2009-04-06 16:18:02 -05:00
Glenn Randers-Pehrson
e502bca962 Imported from libpng-1.2.34beta01.tar 2009-04-06 16:18:00 -05:00
Glenn Randers-Pehrson
c4d44b72e8 Imported from libpng-1.2.33.tar 2009-04-06 16:17:58 -05:00
Glenn Randers-Pehrson
e7324bb94f Imported from libpng-1.2.33rc02.tar 2009-04-06 16:17:56 -05:00
Glenn Randers-Pehrson
8431b2c190 Imported from libpng-1.2.33rc01.tar 2009-04-06 16:17:53 -05:00
Glenn Randers-Pehrson
7d376ccd8c Imported from libpng-1.2.33beta01.tar 2009-04-06 16:17:51 -05:00
Glenn Randers-Pehrson
382410249d Imported from libpng-1.2.32.tar 2009-04-06 16:17:49 -05:00
Glenn Randers-Pehrson
bfb5132362 Imported from libpng-1.2.32rc01.tar 2009-04-06 16:17:47 -05:00
Glenn Randers-Pehrson
4489dbc630 Imported from libpng-1.2.32beta01.tar 2009-04-06 16:17:45 -05:00
Glenn Randers-Pehrson
5c31bc8ffc Imported from libpng-1.2.31.tar 2009-04-06 16:17:42 -05:00
Glenn Randers-Pehrson
baee5f46cf Imported from libpng-1.2.31rc03.tar 2009-04-06 16:17:40 -05:00
Glenn Randers-Pehrson
66ab7ffa15 Imported from libpng-1.2.31rc02.tar 2009-04-06 16:17:37 -05:00
Glenn Randers-Pehrson
32df7eb346 Imported from libpng-1.2.31rc01.tar 2009-04-06 16:17:35 -05:00
Glenn Randers-Pehrson
576b532b45 Imported from libpng-1.2.30.tar 2009-04-06 16:17:33 -05:00
Glenn Randers-Pehrson
b520414d5a Imported from libpng-1.2.30rc08.tar 2009-04-06 16:17:31 -05:00
Glenn Randers-Pehrson
b54fd5c588 Imported from libpng-1.2.30rc07.tar 2009-04-06 16:17:28 -05:00
Glenn Randers-Pehrson
d9b4c01719 Imported from libpng-1.2.30rc06.tar 2009-04-06 16:17:26 -05:00
Glenn Randers-Pehrson
84d5d968a6 Imported from libpng-1.2.30rc05.tar 2009-04-06 16:17:24 -05:00
Glenn Randers-Pehrson
9c8717e42f Imported from libpng-1.2.30rc04.tar 2009-04-06 16:17:21 -05:00
Glenn Randers-Pehrson
3215e97b17 Imported from libpng-1.2.30rc03.tar 2009-04-06 16:17:19 -05:00
Glenn Randers-Pehrson
975e721432 Imported from libpng-1.2.30rc02.tar 2009-04-06 16:17:17 -05:00
Glenn Randers-Pehrson
b8bccdd081 Imported from libpng-1.2.30rc01.tar 2009-04-06 16:17:15 -05:00
Glenn Randers-Pehrson
4310a4d813 Imported from libpng-1.2.30beta04.tar 2009-04-06 16:17:12 -05:00
Glenn Randers-Pehrson
b96b342561 Imported from libpng-1.2.30beta03.tar 2009-04-06 16:17:10 -05:00
Glenn Randers-Pehrson
eb1cd11d57 Imported from libpng-1.2.30beta02.tar 2009-04-06 16:17:07 -05:00
Glenn Randers-Pehrson
a55c72890d Imported from libpng-1.2.30beta01.tar 2009-04-06 16:17:05 -05:00
Glenn Randers-Pehrson
247e230581 Imported from libpng-1.2.29.tar 2009-04-06 16:17:03 -05:00
Glenn Randers-Pehrson
1586ea6fe9 Imported from libpng-1.2.29rc01.tar 2009-04-06 16:17:01 -05:00
Glenn Randers-Pehrson
ae505c50b0 Imported from libpng-1.2.29beta03.tar 2009-04-06 16:16:58 -05:00
Glenn Randers-Pehrson
fce1b4b1fb Imported from libpng-1.2.29beta02.tar 2009-04-06 16:16:55 -05:00
Glenn Randers-Pehrson
c6bcbf4951 Imported from libpng-1.2.29beta01.tar 2009-04-06 16:16:53 -05:00
Glenn Randers-Pehrson
6ed6086da5 Imported from libpng-1.2.28.tar 2009-04-06 16:16:51 -05:00
Glenn Randers-Pehrson
9f7b16ad19 Imported from libpng-1.2.27.tar 2009-04-06 16:16:49 -05:00
Glenn Randers-Pehrson
fc70a92071 Imported from libpng-1.2.27rc01.tar 2009-04-06 16:16:46 -05:00
Glenn Randers-Pehrson
ccaaab2898 Imported from libpng-1.2.27beta06.tar 2009-04-06 16:16:43 -05:00
Glenn Randers-Pehrson
8d36e630f2 Imported from libpng-1.2.27beta05.tar 2009-04-06 16:16:41 -05:00
Glenn Randers-Pehrson
eb1f347bca Imported from libpng-1.2.27beta04.tar 2009-04-06 16:16:38 -05:00
Glenn Randers-Pehrson
7db798186c Imported from libpng-1.2.27beta03.tar 2009-04-06 16:16:36 -05:00
Glenn Randers-Pehrson
a1cd94bfbb Imported from libpng-1.2.27beta02.tar 2009-04-06 16:16:34 -05:00
Glenn Randers-Pehrson
d9d2a6f6d9 Imported from libpng-1.2.27beta01.tar 2009-04-06 16:16:31 -05:00
Glenn Randers-Pehrson
b8c4b82d18 Imported from libpng-1.2.26.tar 2009-04-06 16:16:29 -05:00
Glenn Randers-Pehrson
b8f615d7a1 Imported from libpng-1.2.26rc01.tar 2009-04-06 16:16:27 -05:00
Glenn Randers-Pehrson
35d97eb5c5 Imported from libpng-1.2.26beta06.tar 2009-04-06 16:16:24 -05:00
Glenn Randers-Pehrson
fc15b2e479 Imported from libpng-1.2.26beta05.tar 2009-04-06 16:16:22 -05:00
Glenn Randers-Pehrson
936df0d290 Imported from libpng-1.2.26beta04.tar 2009-04-06 16:16:20 -05:00
Glenn Randers-Pehrson
3236beddf8 Imported from libpng-1.2.26beta03.tar 2009-04-06 16:16:18 -05:00
Glenn Randers-Pehrson
c13f8f10e6 Imported from libpng-1.2.26beta02.tar 2009-04-06 16:16:15 -05:00
Glenn Randers-Pehrson
d8b530b93c Imported from libpng-1.2.26beta01.tar 2009-04-06 16:16:13 -05:00
Glenn Randers-Pehrson
2296f211e8 Imported from libpng-1.2.25.tar 2009-04-06 16:16:10 -05:00
Glenn Randers-Pehrson
a5136b8863 Imported from libpng-1.2.25rc02.tar 2009-04-06 16:16:08 -05:00
Glenn Randers-Pehrson
913bc38217 Imported from libpng-1.2.25beta06.tar 2009-04-06 16:16:05 -05:00
Glenn Randers-Pehrson
4b7dca3d2c Imported from libpng-1.2.25beta05.tar 2009-04-06 16:16:03 -05:00
Glenn Randers-Pehrson
5c58e3ee31 Imported from libpng-1.2.25beta04.tar 2009-04-06 16:16:00 -05:00
Glenn Randers-Pehrson
49f304bd07 Imported from libpng-1.2.25beta03.tar 2009-04-06 16:15:58 -05:00
Glenn Randers-Pehrson
c95be42221 Imported from libpng-1.2.25rc01.tar 2009-04-06 16:15:56 -05:00
Glenn Randers-Pehrson
dbc07e13bb Imported from libpng-1.2.25beta02.tar 2009-04-06 16:15:54 -05:00
Glenn Randers-Pehrson
5ca40ebc22 Imported from libpng-1.2.25beta01.tar 2009-04-06 16:15:51 -05:00
Glenn Randers-Pehrson
a8e07274ae Imported from libpng-1.2.24.tar 2009-04-06 16:15:49 -05:00
Glenn Randers-Pehrson
af99dba018 Imported from libpng-1.2.24rc01.tar 2009-04-06 16:15:46 -05:00
Glenn Randers-Pehrson
03dfa028d2 Imported from libpng-1.2.24beta02.tar 2009-04-06 16:15:44 -05:00
Glenn Randers-Pehrson
541b47ac2a Imported from libpng-1.2.24beta01.tar 2009-04-06 16:15:42 -05:00
Glenn Randers-Pehrson
507a35a9be Imported from libpng-1.2.23.tar 2009-04-06 16:15:39 -05:00
Glenn Randers-Pehrson
1eddb5463e Imported from libpng-1.2.23rc01.tar 2009-04-06 16:15:37 -05:00
Glenn Randers-Pehrson
d91769efd4 Imported from libpng-1.2.23beta05.tar 2009-04-06 16:15:34 -05:00
Glenn Randers-Pehrson
134a8eb272 Imported from libpng-1.2.23beta04.tar 2009-04-06 16:15:32 -05:00
Glenn Randers-Pehrson
930be98598 Imported from libpng-1.2.23beta03.tar 2009-04-06 16:15:30 -05:00
Glenn Randers-Pehrson
28e3cb3e93 Imported from libpng-1.2.23beta02.tar 2009-04-06 16:15:28 -05:00
Glenn Randers-Pehrson
6328671ef8 Imported from libpng-1.2.23beta01.tar 2009-04-06 16:15:25 -05:00
Glenn Randers-Pehrson
fab1959d00 Imported from libpng-1.2.22.tar 2009-04-06 16:15:23 -05:00
Glenn Randers-Pehrson
5ab788cd84 Imported from libpng-1.2.22rc1.tar 2009-04-06 16:15:21 -05:00
Glenn Randers-Pehrson
ce2a6d3739 Imported from libpng-1.2.22beta4.tar 2009-04-06 16:15:18 -05:00
Glenn Randers-Pehrson
40dd10dfb2 Imported from libpng-1.2.22beta3.tar 2009-04-06 16:15:16 -05:00
Glenn Randers-Pehrson
e41076e082 Imported from libpng-1.2.22beta2.tar 2009-04-06 16:15:14 -05:00
Glenn Randers-Pehrson
582fec4e11 Imported from libpng-1.2.22beta1.tar 2009-04-06 16:15:11 -05:00
Glenn Randers-Pehrson
42ae02aa08 Imported from libpng-1.2.21.tar 2009-04-06 16:15:08 -05:00
Glenn Randers-Pehrson
79e3fc64c4 Imported from libpng-1.2.21rc3.tar 2009-04-06 16:15:06 -05:00
Glenn Randers-Pehrson
b188d671d1 Imported from libpng-1.2.21rc2.tar 2009-04-06 16:15:04 -05:00
Glenn Randers-Pehrson
5ecf1b53ea Imported from libpng-1.2.21rc1.tar 2009-04-06 16:15:01 -05:00
Glenn Randers-Pehrson
0636311d37 Imported from libpng-1.2.21beta2.tar 2009-04-06 16:14:59 -05:00
Glenn Randers-Pehrson
219d3b449f Imported from libpng-1.2.21beta1.tar 2009-04-06 16:14:57 -05:00
Glenn Randers-Pehrson
22eaa89c5a Imported from libpng-1.2.20.tar 2009-04-06 16:14:55 -05:00
Glenn Randers-Pehrson
79e28a4c2e Imported from libpng-1.2.20rc6.tar 2009-04-06 16:14:52 -05:00
Glenn Randers-Pehrson
db05b1eb2b Imported from libpng-1.2.20rc5.tar 2009-04-06 16:14:50 -05:00
Glenn Randers-Pehrson
d20666a228 Imported from libpng-1.2.20rc4.tar 2009-04-06 16:14:48 -05:00
Glenn Randers-Pehrson
9cc7b03503 Imported from libpng-1.2.20rc3.tar 2009-04-06 16:14:45 -05:00
Glenn Randers-Pehrson
b38f12d519 Imported from libpng-1.2.20rc2.tar 2009-04-06 16:14:43 -05:00
Glenn Randers-Pehrson
e736f1ead9 Imported from libpng-1.2.20rc1.tar 2009-04-06 16:14:40 -05:00
Glenn Randers-Pehrson
b56c1f6023 Imported from libpng-1.2.20beta04.tar 2009-04-06 16:14:37 -05:00
Glenn Randers-Pehrson
268f0d64fc Imported from libpng-1.2.20beta03.tar 2009-04-06 16:14:35 -05:00
Glenn Randers-Pehrson
b3ea17736b Imported from libpng-1.2.20beta02.tar 2009-04-06 16:14:33 -05:00
Glenn Randers-Pehrson
963daeaec5 Imported from libpng-1.2.20beta01.tar 2009-04-06 16:14:30 -05:00
Glenn Randers-Pehrson
249bd44ebc Imported from libpng-1.2.19.tar 2009-04-06 16:14:28 -05:00
Glenn Randers-Pehrson
04a1b1c123 Imported from libpng-1.2.19rc6.tar 2009-04-06 16:14:25 -05:00
Glenn Randers-Pehrson
3922e7afc3 Imported from libpng-1.2.19rc5.tar 2009-04-06 16:14:23 -05:00
Glenn Randers-Pehrson
f0a97a0d80 Imported from libpng-1.2.19rc4.tar 2009-04-06 16:14:21 -05:00
Glenn Randers-Pehrson
88713fd590 Imported from libpng-1.2.19rc3.tar 2009-04-06 16:14:18 -05:00
Glenn Randers-Pehrson
394759e0c8 Imported from libpng-1.2.19rc2.tar 2009-04-06 16:14:16 -05:00
Glenn Randers-Pehrson
c229f65dcf Imported from libpng-1.2.19rc1.tar 2009-04-06 16:14:13 -05:00
Glenn Randers-Pehrson
f929861609 Imported from libpng-1.2.19beta31.tar 2009-04-06 16:14:10 -05:00
Glenn Randers-Pehrson
f024ce7675 Imported from libpng-1.2.19beta30.tar 2009-04-06 16:14:08 -05:00
Glenn Randers-Pehrson
f3fcf00392 Imported from libpng-1.2.19beta29.tar 2009-04-06 16:14:05 -05:00
Glenn Randers-Pehrson
08313ef870 Imported from libpng-1.2.19beta28.tar 2009-04-06 16:14:03 -05:00
Glenn Randers-Pehrson
911c469d69 Imported from libpng-1.2.19beta27.tar 2009-04-06 16:14:00 -05:00
Glenn Randers-Pehrson
07c089ee04 Imported from libpng-1.2.19beta26.tar 2009-04-06 16:13:58 -05:00
Glenn Randers-Pehrson
dadc944810 Imported from libpng-1.2.19beta25.tar 2009-04-06 16:13:55 -05:00
Glenn Randers-Pehrson
80663032a9 Imported from libpng-1.2.19beta24.tar 2009-04-06 16:13:53 -05:00
Glenn Randers-Pehrson
67c75ee7f0 Imported from libpng-1.2.19beta23.tar 2009-04-06 16:13:51 -05:00
Glenn Randers-Pehrson
62626737a5 Imported from libpng-1.2.19beta22.tar 2009-04-06 16:13:48 -05:00
Glenn Randers-Pehrson
e404eed318 Imported from libpng-1.2.19beta21.tar 2009-04-06 16:13:46 -05:00
Glenn Randers-Pehrson
3c115428ea Imported from libpng-1.2.19beta20.tar 2009-04-06 16:13:43 -05:00
Glenn Randers-Pehrson
db40ca4aca Imported from libpng-1.2.19beta19.tar 2009-04-06 16:13:41 -05:00
Glenn Randers-Pehrson
f456d0d6bb Imported from libpng-1.2.19beta18.tar 2009-04-06 16:13:38 -05:00
Glenn Randers-Pehrson
06fe17eb9f Imported from libpng-1.2.19beta17.tar 2009-04-06 16:13:36 -05:00
Glenn Randers-Pehrson
7945bdb88f Imported from libpng-1.2.19beta16.tar 2009-04-06 16:13:33 -05:00
Glenn Randers-Pehrson
f7794ec181 Imported from libpng-1.2.19beta15.tar 2009-04-06 16:13:31 -05:00
Glenn Randers-Pehrson
16851b3eb3 Imported from libpng-1.2.19beta14.tar 2009-04-06 16:13:29 -05:00
Glenn Randers-Pehrson
c72d8d4d29 Imported from libpng-1.2.19beta13.tar 2009-04-06 16:13:26 -05:00
Glenn Randers-Pehrson
2b7436558e Imported from libpng-1.2.19beta12.tar 2009-04-06 16:13:24 -05:00
Glenn Randers-Pehrson
e59c47d5b1 Imported from libpng-1.2.19beta11.tar 2009-04-06 16:13:22 -05:00
Glenn Randers-Pehrson
c1523ad16d Imported from libpng-1.2.19beta10.tar 2009-04-06 16:13:19 -05:00
Glenn Randers-Pehrson
d0be8e27de Imported from libpng-1.2.19beta9.tar 2009-04-06 16:13:17 -05:00
Glenn Randers-Pehrson
5c66b81289 Imported from libpng-1.2.19beta8.tar 2009-04-06 16:13:15 -05:00
Glenn Randers-Pehrson
1a42cb2013 Imported from libpng-1.2.19beta7.tar 2009-04-06 16:13:12 -05:00
Glenn Randers-Pehrson
cf2978cbbb Imported from libpng-1.2.19beta6.tar 2009-04-06 16:13:10 -05:00
Glenn Randers-Pehrson
8a9733e777 Imported from libpng-1.2.19beta5.tar 2009-04-06 16:13:07 -05:00
Glenn Randers-Pehrson
ba880c5501 Imported from libpng-1.2.19beta4.tar 2009-04-06 16:13:05 -05:00
Glenn Randers-Pehrson
788f962fbd Imported from libpng-1.2.19beta3.tar 2009-04-06 16:13:03 -05:00
Glenn Randers-Pehrson
12f8283560 Imported from libpng-1.2.19beta2.tar 2009-04-06 16:13:01 -05:00
Glenn Randers-Pehrson
4d27f6b77b Imported from libpng-1.2.19beta1.tar 2009-04-06 16:12:58 -05:00
Glenn Randers-Pehrson
413ed28246 Imported from libpng-1.2.18.tar 2009-04-06 16:12:56 -05:00
Glenn Randers-Pehrson
ad084f559a Imported from libpng-1.2.17.tar 2009-04-06 16:12:54 -05:00
Glenn Randers-Pehrson
3832ab1c21 Imported from libpng-1.2.17rc4.tar 2009-04-06 16:12:52 -05:00
Glenn Randers-Pehrson
999bceb413 Imported from libpng-1.2.17rc3.tar 2009-04-06 16:12:49 -05:00
Glenn Randers-Pehrson
e8f6605642 Imported from libpng-1.2.17rc2.tar 2009-04-06 16:12:47 -05:00
Glenn Randers-Pehrson
3148c65323 Imported from libpng-1.2.17rc1.tar 2009-04-06 16:12:45 -05:00
Glenn Randers-Pehrson
0a3d2cc68b Imported from libpng-1.2.17beta2.tar 2009-04-06 16:12:43 -05:00
Glenn Randers-Pehrson
11cf76edb3 Imported from libpng-1.2.17beta1.tar 2009-04-06 16:12:40 -05:00
Glenn Randers-Pehrson
8833ad415c Imported from libpng-1.2.16.tar 2009-04-06 16:12:38 -05:00
Glenn Randers-Pehrson
bc290d8e6c Imported from libpng-1.2.16rc1.tar 2009-04-06 16:12:35 -05:00
Glenn Randers-Pehrson
9c5b3a4060 Imported from libpng-1.2.16beta2.tar 2009-04-06 16:12:33 -05:00
Glenn Randers-Pehrson
04bbba55c7 Imported from libpng-1.2.16beta1.tar 2009-04-06 16:12:31 -05:00
Glenn Randers-Pehrson
40b70d5373 Imported from libpng-1.2.15.tar 2009-04-06 16:12:29 -05:00
Glenn Randers-Pehrson
833d32646e Imported from libpng-1.2.15rc5.tar 2009-04-06 16:12:27 -05:00
Glenn Randers-Pehrson
6cdefb3cac Imported from libpng-1.2.15rc4.tar 2009-04-06 16:12:25 -05:00
Glenn Randers-Pehrson
f959d3ee7a Imported from libpng-1.2.15rc3.tar 2009-04-06 16:12:22 -05:00
Glenn Randers-Pehrson
b0952eabc7 Imported from libpng-1.2.15rc2.tar 2009-04-06 16:12:20 -05:00
Glenn Randers-Pehrson
43bb4ba4bf Imported from libpng-1.2.15rc1.tar 2009-04-06 16:12:18 -05:00
Glenn Randers-Pehrson
c2de22abeb Imported from libpng-1.2.15beta6.tar 2009-04-06 16:12:15 -05:00
Glenn Randers-Pehrson
a0113ee049 Imported from libpng-1.2.15beta5.tar 2009-04-06 16:12:13 -05:00
Glenn Randers-Pehrson
05db10fda3 Imported from libpng-1.2.15beta4.tar 2009-04-06 16:12:11 -05:00
Glenn Randers-Pehrson
948ee23a2a Imported from libpng-1.2.15beta3.tar 2009-04-06 16:12:08 -05:00
Glenn Randers-Pehrson
271a2931b6 Imported from libpng-1.2.15beta2.tar 2009-04-06 16:12:06 -05:00
Glenn Randers-Pehrson
9fe05edd47 Imported from libpng-1.2.15beta1.tar 2009-04-06 16:12:04 -05:00
Glenn Randers-Pehrson
c2573702cf Imported from libpng-1.2.14.tar 2009-04-06 16:12:02 -05:00
Glenn Randers-Pehrson
b8e76b586e Imported from libpng-1.2.14rc1.tar 2009-04-06 16:11:59 -05:00
Glenn Randers-Pehrson
11a89964b9 Imported from libpng-1.2.14beta2.tar 2009-04-06 16:11:57 -05:00
Glenn Randers-Pehrson
b5bfcbae59 Imported from libpng-1.2.14beta1.tar 2009-04-06 16:11:55 -05:00
Glenn Randers-Pehrson
efe95a6953 Imported from libpng-1.2.13.tar 2009-04-06 16:11:53 -05:00
Glenn Randers-Pehrson
e88a5eca8b Imported from libpng-1.2.13rc2.tar 2009-04-06 16:11:51 -05:00
Glenn Randers-Pehrson
2e3980e1de Imported from libpng-1.2.13rc1.tar 2009-04-06 16:11:49 -05:00
Glenn Randers-Pehrson
0ff85c6923 Imported from libpng-1.2.13beta1.tar 2009-04-06 16:11:47 -05:00
Glenn Randers-Pehrson
e3358d1839 Imported from libpng-1.2.12.tar 2009-04-06 16:11:45 -05:00
Glenn Randers-Pehrson
f5eac0c7fa Imported from libpng-1.2.11.tar 2009-04-06 16:11:42 -05:00
Glenn Randers-Pehrson
6034592a27 Imported from libpng-1.2.11rc5.tar 2009-04-06 16:11:40 -05:00
Glenn Randers-Pehrson
7b00d826d3 Imported from libpng-1.2.11rc3.tar 2009-04-06 16:11:37 -05:00
Glenn Randers-Pehrson
52ef3586b9 Imported from libpng-1.2.11rc2.tar 2009-04-06 16:11:35 -05:00
Glenn Randers-Pehrson
4118fcdd14 Imported from libpng-1.2.11rc1.tar 2009-04-06 16:11:33 -05:00
Glenn Randers-Pehrson
d9e18047d3 Imported from libpng-1.2.11beta4.tar 2009-04-06 16:11:31 -05:00
Glenn Randers-Pehrson
734f320ade Imported from libpng-1.2.11beta3.tar 2009-04-06 16:11:29 -05:00
Glenn Randers-Pehrson
79f25cdeb2 Imported from libpng-1.2.11beta2cos.tar 2009-04-06 16:11:27 -05:00
Glenn Randers-Pehrson
413f3db617 Imported from libpng-1.2.11beta2.tar 2009-04-06 16:11:25 -05:00
Glenn Randers-Pehrson
4db11d5143 Imported from libpng-1.2.11beta1.tar 2009-04-06 16:11:23 -05:00
Glenn Randers-Pehrson
78d28c6b96 Imported from libpng-1.2.10.tar 2009-04-06 16:11:21 -05:00
Glenn Randers-Pehrson
24df7333a2 Imported from libpng-1.2.10rc3.tar 2009-04-06 16:11:18 -05:00
Glenn Randers-Pehrson
8694cd8bf5 Imported from libpng-1.2.10rc2.tar 2009-04-06 16:11:16 -05:00
Glenn Randers-Pehrson
f628ee2fa4 Imported from libpng-1.2.10rc1.tar 2009-04-06 16:09:08 -05:00
Glenn Randers-Pehrson
ad310547a2 Imported from libpng-1.2.10beta7.tar 2009-04-06 16:09:06 -05:00
Glenn Randers-Pehrson
629330e761 Imported from libpng-1.2.10beta6.tar 2009-04-06 16:09:04 -05:00
Glenn Randers-Pehrson
b511b60aaa Imported from libpng-1.2.10beta5.tar 2009-04-06 16:09:02 -05:00
Glenn Randers-Pehrson
77be22c09a Imported from libpng-1.2.10beta4.tar 2009-04-06 16:09:00 -05:00
Glenn Randers-Pehrson
b0270f77a9 Imported from libpng-1.2.10beta3.tar 2009-04-06 16:08:58 -05:00
Glenn Randers-Pehrson
3a5a759bb7 Imported from libpng-1.2.10beta2.tar 2009-04-06 16:08:55 -05:00
Glenn Randers-Pehrson
d5d63601b9 Imported from libpng-1.2.10beta1.tar 2009-04-06 16:08:53 -05:00
Glenn Randers-Pehrson
a7d0c94169 Imported from libpng-1.2.9.tar 2009-04-06 16:08:51 -05:00
Glenn Randers-Pehrson
3a51203c48 Imported from libpng-1.2.9rc1.tar 2009-04-06 16:08:49 -05:00
Glenn Randers-Pehrson
4deeb795f6 Imported from libpng-1.2.9beta11.tar 2009-04-06 16:08:46 -05:00
Glenn Randers-Pehrson
26e47d9a71 Imported from libpng-1.2.9beta10.tar 2009-04-06 16:08:44 -05:00
Glenn Randers-Pehrson
170b70ce30 Imported from libpng-1.2.9beta9.tar 2009-04-06 16:08:42 -05:00
Glenn Randers-Pehrson
1ce0836b4a Imported from libpng-1.2.9beta8.tar 2009-04-06 16:08:39 -05:00
Glenn Randers-Pehrson
5c60b2367e Imported from libpng-1.2.9beta7.tar 2009-04-06 16:08:37 -05:00
Glenn Randers-Pehrson
b7f9593715 Imported from libpng-1.2.9beta6.tar 2009-04-06 16:08:35 -05:00
Glenn Randers-Pehrson
e64746200b Imported from libpng-1.2.9beta5.tar 2009-04-06 16:08:32 -05:00
Glenn Randers-Pehrson
c3d51c14f2 Imported from libpng-1.2.9beta4.tar 2009-04-06 16:08:30 -05:00
Glenn Randers-Pehrson
7b34df33a5 Imported from libpng-1.2.9beta3.tar 2009-04-06 16:08:27 -05:00
Glenn Randers-Pehrson
ddfebd35be Imported from libpng-1.2.9beta2.tar 2009-04-06 16:08:25 -05:00
Glenn Randers-Pehrson
9c3ab68145 Imported from libpng-1.2.9beta1.tar 2009-04-06 16:08:23 -05:00
Glenn Randers-Pehrson
917648ecb9 Imported from libpng-1.2.8.tar 2009-04-06 16:08:21 -05:00
Glenn Randers-Pehrson
584b96e859 Imported from libpng-1.2.8rc5.tar 2009-04-06 16:08:18 -05:00
Glenn Randers-Pehrson
228c637527 Imported from libpng-1.2.8rc4.tar 2009-04-06 16:08:16 -05:00
Glenn Randers-Pehrson
c3dda6daea Imported from libpng-1.2.8rc3.tar 2009-04-06 16:08:15 -05:00
Glenn Randers-Pehrson
73b029f9d3 Imported from libpng-1.2.8rc2.tar 2009-04-06 16:08:13 -05:00
Glenn Randers-Pehrson
5dd2b8e208 Imported from libpng-1.2.8rc1.tar 2009-04-06 16:08:11 -05:00
Glenn Randers-Pehrson
4093607bc9 Imported from libpng-1.2.8beta5.tar 2009-04-06 16:08:09 -05:00
Glenn Randers-Pehrson
878b31e0b4 Imported from libpng-1.2.8beta4.tar 2009-04-06 16:08:07 -05:00
Glenn Randers-Pehrson
7806777139 Imported from libpng-1.2.8beta3.tar 2009-04-06 16:08:05 -05:00
Glenn Randers-Pehrson
94d9362fc5 Imported from libpng-1.2.8beta2.tar 2009-04-06 16:08:03 -05:00
Glenn Randers-Pehrson
16e11660fe Imported from libpng-1.2.8beta1.tar 2009-04-06 16:08:01 -05:00
Glenn Randers-Pehrson
250dfe1777 Imported from libpng-1.2.7.tar 2009-04-06 16:08:00 -05:00
Glenn Randers-Pehrson
5b77916ecd Imported from libpng-1.2.7rc1.tar 2009-04-06 16:07:57 -05:00
Glenn Randers-Pehrson
67864af957 Imported from libpng-1.2.7beta2.tar 2009-04-06 16:07:56 -05:00
Glenn Randers-Pehrson
a4981d4ded Imported from libpng-1.2.7beta1.tar 2009-04-06 16:07:54 -05:00
Glenn Randers-Pehrson
37f116a900 Imported from libpng-1.2.6.tar 2009-04-06 16:07:52 -05:00
Glenn Randers-Pehrson
8f3dd833d7 Imported from libpng-1.2.6rc5.tar 2009-04-06 16:07:50 -05:00
Glenn Randers-Pehrson
36d7bc7530 Imported from libpng-1.2.6rc4.tar 2009-04-06 16:07:48 -05:00
Glenn Randers-Pehrson
d029a75d4f Imported from libpng-1.2.6rc3.tar 2009-04-06 16:07:46 -05:00
Glenn Randers-Pehrson
dff799ef89 Imported from libpng-1.2.6rc2.tar 2009-04-06 16:07:44 -05:00
Glenn Randers-Pehrson
272489dc69 Imported from libpng-1.2.6rc1.tar 2009-04-06 16:07:42 -05:00
Glenn Randers-Pehrson
5fea36fb00 Imported from libpng-1.2.6beta4.tar 2009-04-06 16:07:40 -05:00
Glenn Randers-Pehrson
5b5dcf8b88 Imported from libpng-1.2.6beta3.tar 2009-04-06 16:07:38 -05:00
Glenn Randers-Pehrson
761bf9f06f Imported from libpng-1.2.6beta2.tar 2009-04-06 16:07:36 -05:00
Glenn Randers-Pehrson
c33ab4e8df Imported from libpng-1.2.6beta1.tar 2009-04-06 16:07:34 -05:00
Glenn Randers-Pehrson
0cc2f95a9d Imported from libpng-1.2.5.tar 2009-04-06 16:07:32 -05:00
Glenn Randers-Pehrson
5ff38d3e16 Imported from libpng-1.2.5rc3.tar 2009-04-06 16:07:30 -05:00
Glenn Randers-Pehrson
865f4f073a Imported from libpng-1.2.5rc2.tar 2009-04-06 16:07:28 -05:00
Glenn Randers-Pehrson
51d9250c88 Imported from libpng-1.2.5rc1.tar 2009-04-06 16:07:27 -05:00
Glenn Randers-Pehrson
8a7df0024b Imported from libpng-1.2.5beta2.tar 2009-04-06 16:07:25 -05:00
Glenn Randers-Pehrson
859665d847 Imported from libpng-1.2.5beta1.tar 2009-04-06 16:07:23 -05:00
Glenn Randers-Pehrson
484a8a10fe Imported from libpng-1.2.4.tar 2009-04-06 16:07:21 -05:00
Glenn Randers-Pehrson
2ae022da7e Imported from libpng-1.2.4rc1.tar 2009-04-06 16:07:18 -05:00
Glenn Randers-Pehrson
d020e9d826 Imported from libpng-1.2.4beta3.tar 2009-04-06 16:07:16 -05:00
Glenn Randers-Pehrson
d1e8c8694d Imported from libpng-1.2.4beta2.tar 2009-04-06 16:07:14 -05:00
Glenn Randers-Pehrson
07748d1b2c Imported from libpng-1.2.4beta1.tar 2009-04-06 16:07:12 -05:00
Glenn Randers-Pehrson
cfbed9bdf2 Imported from libpng-1.2.3.tar 2009-04-06 16:07:10 -05:00
Glenn Randers-Pehrson
22f28966c4 Imported from libpng-1.2.3rc6.tar 2009-04-06 16:07:08 -05:00
Glenn Randers-Pehrson
837a3d1745 Imported from libpng-1.2.3rc5.tar 2009-04-06 16:07:06 -05:00
Glenn Randers-Pehrson
704228f7e7 Imported from libpng-1.2.3rc4.tar 2009-04-06 16:07:04 -05:00
Glenn Randers-Pehrson
299d73503c Imported from libpng-1.2.3rc3.tar 2009-04-06 16:07:02 -05:00
Glenn Randers-Pehrson
25d8224d15 Imported from libpng-1.2.3rc2.tar 2009-04-06 16:07:00 -05:00
Glenn Randers-Pehrson
03008a08d1 Imported from libpng-1.2.3rc1.tar 2009-04-06 16:06:58 -05:00
Glenn Randers-Pehrson
4fb046a52d Imported from libpng-1.2.2.tar 2009-04-06 16:06:56 -05:00
Glenn Randers-Pehrson
fcbd7870e9 Imported from libpng-1.2.2rc1.tar 2009-04-06 16:06:54 -05:00
Glenn Randers-Pehrson
25228abdc1 Imported from libpng-1.2.2beta6.tar 2009-04-06 16:06:52 -05:00
Glenn Randers-Pehrson
73d57cb97b Imported from libpng-1.2.2beta5.tar 2009-04-06 16:06:50 -05:00
Glenn Randers-Pehrson
377657d1d6 Imported from libpng-1.2.2beta4.tar 2009-04-06 16:06:49 -05:00
Glenn Randers-Pehrson
c1bfe686ce Imported from libpng-1.2.2beta3.tar 2009-04-06 16:06:47 -05:00
Glenn Randers-Pehrson
c6de22da1d Imported from libpng-1.2.2beta2.tar 2009-04-06 16:06:45 -05:00
Glenn Randers-Pehrson
9c0f094b21 Imported from libpng-1.2.2beta1.tar 2009-04-06 16:06:43 -05:00
Glenn Randers-Pehrson
f50c91b7bd Imported from libpng-1.2.1.tar 2009-04-06 16:06:41 -05:00
Glenn Randers-Pehrson
db3b88dad2 Imported from libpng-1.2.1rc2.tar 2009-04-06 16:06:39 -05:00
Glenn Randers-Pehrson
ae498dcff3 Imported from libpng-1.2.1rc1.tar 2009-04-06 16:06:37 -05:00
Glenn Randers-Pehrson
5cded0b4b5 Imported from libpng-1.2.1beta4.tar 2009-04-06 16:06:35 -05:00
Glenn Randers-Pehrson
3f549259b2 Imported from libpng-1.2.1beta3.tar 2009-04-06 16:06:33 -05:00
Glenn Randers-Pehrson
6c97ddbffc Imported from libpng-1.2.1beta2.tar 2009-04-06 16:06:32 -05:00
Glenn Randers-Pehrson
5a0be341ba Imported from libpng-1.2.1beta1.tar 2009-04-06 16:06:30 -05:00
Glenn Randers-Pehrson
10781048be Imported from libpng-1.2.0.tar 2009-04-06 16:06:28 -05:00
Glenn Randers-Pehrson
1b8e567237 Imported from libpng-1.2.0rc1.tar 2009-04-06 16:06:26 -05:00
Glenn Randers-Pehrson
1ea0ff34fa Imported from libpng-1.2.0beta5.tar 2009-04-06 16:06:24 -05:00
Glenn Randers-Pehrson
b182893c04 Imported from libpng-1.2.0beta4.tar 2009-04-06 16:06:22 -05:00
Glenn Randers-Pehrson
8b6a889881 Imported from libpng-1.2.0beta3.tar 2009-04-06 16:06:20 -05:00
Glenn Randers-Pehrson
3097f618f2 Imported from libpng-1.2.0beta2.tar 2009-04-06 16:06:18 -05:00
Glenn Randers-Pehrson
1fd5fb33c2 Imported from libpng-1.2.0beta1.tar 2009-04-06 16:06:16 -05:00
Glenn Randers-Pehrson
e68f5a361b Imported from libpng-1.0.12beta1.tar 2009-04-06 16:06:14 -05:00
Glenn Randers-Pehrson
328353990f Imported from libpng-1.0.11.tar 2009-04-06 16:06:12 -05:00
Glenn Randers-Pehrson
82ae383331 Imported from libpng-1.0.11rc1.tar 2009-04-06 16:06:10 -05:00
Glenn Randers-Pehrson
e1eff58f87 Imported from libpng-1.0.11beta3.tar 2009-04-06 16:06:08 -05:00
Glenn Randers-Pehrson
f64a06f5ec Imported from libpng-1.0.11beta2.tar 2009-04-06 16:06:06 -05:00
Glenn Randers-Pehrson
87c6bc984a Imported from libpng-1.0.11beta1.tar 2009-04-06 16:06:04 -05:00
Glenn Randers-Pehrson
13cfbac075 Imported from libpng-1.0.10.tar 2009-04-06 16:06:02 -05:00
Glenn Randers-Pehrson
e164447858 Imported from libpng-1.0.10rc1.tar 2009-04-06 16:06:00 -05:00
Glenn Randers-Pehrson
1909560348 Imported from libpng-1.0.10beta1.tar 2009-04-06 16:05:58 -05:00
Glenn Randers-Pehrson
d4e8109a48 Imported from libpng-1.0.9.tar 2009-04-06 16:05:56 -05:00
Glenn Randers-Pehrson
be9de0f428 Imported from libpng-1.0.9rc2.tar 2009-04-06 16:05:54 -05:00
Glenn Randers-Pehrson
cdf140beec Imported from libpng-1.0.9beta9.tar 2009-04-06 16:05:52 -05:00
Glenn Randers-Pehrson
231e687411 Imported from libpng-1.0.9beta8.tar 2009-04-06 16:05:51 -05:00
Glenn Randers-Pehrson
76e5fd642e Imported from libpng-1.0.9beta7.tar 2009-04-06 16:05:49 -05:00
Glenn Randers-Pehrson
f05f8033b8 Imported from libpng-1.0.9rc1.tar 2009-04-06 16:05:47 -05:00
Glenn Randers-Pehrson
408b421265 Imported from libpng-1.0.9beta6.tar 2009-04-06 16:05:45 -05:00
Glenn Randers-Pehrson
2ad31ae31f Imported from libpng-1.0.9beta5.tar 2009-04-06 16:05:43 -05:00
Glenn Randers-Pehrson
f6b4f45c7e Imported from libpng-1.0.9beta4.tar 2009-04-06 16:05:41 -05:00
Glenn Randers-Pehrson
d56aca7104 Imported from libpng-1.0.9beta3.tar 2009-04-06 16:05:39 -05:00
Glenn Randers-Pehrson
f5ed0e130c Imported from libpng-1.0.9beta2.tar 2009-04-06 16:05:37 -05:00
Glenn Randers-Pehrson
fbbb5ecb52 Imported from libpng-1.0.9beta10.tar 2009-04-06 16:05:35 -05:00
229 changed files with 67089 additions and 32436 deletions

View File

@@ -1,32 +1,55 @@
Libpng 1.0.9beta1 - November 10, 2000
Libpng 1.4.8beta04 - June 7, 2011
This is a public release of libpng, intended for use in production codes.
This is not intended to be a public release. It will be replaced
within a few weeks by a public version or by another test version.
Changes since the last public release (1.0.8):
Files available for download:
Fixed typo in scripts/makefile.hpux
Fixed seqence-point bug in contrib/pngminus/png2pnm (Martin Zinser)
Updated makevms.com in scripts and contrib/* and contrib/* (Martin Zinser)
Changed "cdrom.com" in documentation to "libpng.org"
Revised pnggccrd.c to get it all working, and updated makefile.gcmmx (Greg).
Changed type of "params" from voidp to png_voidp in png_read|write_png().
Added MNG_EXTENSIONS_SUPPORTED macro and support for some proposed MNG
features, for testing purposes.
Make sure PNGAPI and PNG_IMPEXP are defined in pngconf.h.
Revised the 3 instances of WRITEFILE in pngtest.c.
Relocated "msvc" and "wince" project subdirectories into "dll" subdirectory.
Updated png.rc in dll/msvc project
Revised makefile.dec to define and use LIBPATH and INCPATH
Increased size of global png_libpng_ver[] array from 12 to 18 chars.
Made global png_libpng_ver[], png_sig[] and png_pass_*[] arrays const.
Removed duplicate png_crc_finish() from png_handle_bKGD() function.
Added a warning when application calls png_read_update_info() multiple times.
Revised makefile.cygwin
Fixed bugs in iCCP support in pngrutil.c and pngwutil.c.
Replaced png_set_empty_plte_permitted() with png_permit_mng_features().
Source files with LF line endings (for Unix/Linux) and with a
"configure" script
Send comments/corrections/commendations to
png-implement@ccrc.wustl.edu or to randeg@alum.rpi.edu
1.4.8beta04.tar.xz (LZMA-compressed, recommended)
1.4.8beta04.tar.gz
1.4.8beta04.tar.bz2
Source files with CRLF line endings (for Windows), without the
"configure" script
lp148b04.7z (LZMA-compressed, recommended)
lp148b04.zip
Other information:
1.4.8beta04-README.txt
1.4.8beta04-LICENSE.txt
Changes since the last public release (1.4.7):
version 1.4.8beta01 [June 4, 2011]
Undef "_ALL_SOURCE" for AIX, to prevent "jmpbuf" from being redefined.
Copied png_debug macros from pngpriv.h into pngtest.c and removed
"#include pngpriv.h" from pngtest.c, to avoid setting a bad example.
Pass "" instead of '\0' to png_default_error() in png_err(). This mistake
was introduced in libpng-1.2.20beta01.
Check for up->location !PNG_AFTER_IDAT when writing unknown chunks
before IDAT.
Ported bugfix in pngrtran.c from 1.5.3: when expanding a paletted image,
always expand to RGBA if transparency is present.
version 1.4.8beta02 [June 5, 2011]
Ported bugfix in pngrtran.c from 1.5.3: Ensure coefficients are OK for
png_rgb_to_gray_fixed().
version 1.4.8beta03 [June 6, 2011]
Check for integer overflow in png_set_rgb_to_gray().
version 1.4.8beta04 [June 7, 2011]
Fixed 1-byte uninitialized memory reference in png_format_buffer() (Bug
report by Frank Busse, related to CVE-2004-0421).
Send comments/corrections/commendations to glennrp at users.sourceforge.net
or to png-mng-implement at lists.sf.net (subscription required; visit
https://lists.sourceforge.net/lists/listinfo/png-mng-implement).
Glenn R-P

2007
CHANGES

File diff suppressed because it is too large Load Diff

397
CMakeLists.txt Normal file
View File

@@ -0,0 +1,397 @@
cmake_minimum_required(VERSION 2.4.4)
set(CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS true)
if(UNIX AND NOT DEFINED CMAKE_BUILD_TYPE)
if(CMAKE_MAJOR_VERSION EQUAL 2 AND CMAKE_MINOR_VERSION EQUAL 4)
# workaround CMake 2.4.x bug
set(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING
"Choose the type of build, options are:
None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used)
Debug
Release
RelWithDebInfo
MinSizeRel.")
else()
set(CMAKE_BUILD_TYPE "RelWithDebInfo" CACHE STRING
"Choose the type of build, options are:
None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used)
Debug
Release
RelWithDebInfo
MinSizeRel.")
endif()
endif()
project(libpng C)
enable_testing()
# Copyright (C) 2007-2010 Glenn Randers-Pehrson
# This code is released under the libpng license.
# For conditions of distribution and use, see the disclaimer
# and license in png.h
set(PNGLIB_MAJOR 1)
set(PNGLIB_MINOR 4)
set(PNGLIB_RELEASE 8)
set(PNGLIB_NAME libpng${PNGLIB_MAJOR}${PNGLIB_MINOR})
set(PNGLIB_VERSION ${PNGLIB_MAJOR}.${PNGLIB_MINOR}.${PNGLIB_RELEASE})
# needed packages
find_package(ZLIB REQUIRED)
include_directories(${ZLIB_INCLUDE_DIR})
if(NOT WIN32)
find_library(M_LIBRARY
NAMES m
PATHS /usr/lib /usr/local/lib
)
if(NOT M_LIBRARY)
message(STATUS
"math library 'libm' not found - floating point support disabled")
endif()
else()
# not needed on windows
set(M_LIBRARY "")
endif()
# COMMAND LINE OPTIONS
if(DEFINED PNG_SHARED)
option(PNG_SHARED "Build shared lib" ${PNG_SHARED})
else()
option(PNG_SHARED "Build shared lib" ON)
endif()
if(DEFINED PNG_STATIC)
option(PNG_STATIC "Build static lib" ${PNG_STATIC})
else()
option(PNG_STATIC "Build static lib" ON)
endif()
if(MINGW)
option(PNG_TESTS "Build pngtest" NO)
else()
option(PNG_TESTS "Build pngtest" YES)
endif()
option(PNG_NO_CONSOLE_IO "FIXME" YES)
option(PNG_NO_STDIO "FIXME" YES)
option(PNG_DEBUG "Build with debug output" NO)
option(PNGARG "FIXME" YES)
#TODO:
# PNG_CONSOLE_IO_SUPPORTED
# maybe needs improving, but currently I don't know when we can enable what :)
set(png_asm_tmp "OFF")
if(NOT WIN32)
find_program(uname_executable NAMES uname PATHS /bin /usr/bin /usr/local/bin)
if(uname_executable)
exec_program(${uname_executable}
ARGS --machine OUTPUT_VARIABLE uname_output)
if("uname_output" MATCHES "^.*i[1-9]86.*$")
set(png_asm_tmp "ON")
else("uname_output" MATCHES "^.*i[1-9]86.*$")
set(png_asm_tmp "OFF")
endif("uname_output" MATCHES "^.*i[1-9]86.*$")
endif(uname_executable)
else()
# this env var is normally only set on win64
set(TEXT "ProgramFiles(x86)")
if("$ENV{${TEXT}}" STREQUAL "")
set(png_asm_tmp "ON")
endif("$ENV{${TEXT}}" STREQUAL "")
endif()
# SET LIBNAME
set(PNG_LIB_NAME png${PNGLIB_MAJOR}${PNGLIB_MINOR})
# to distinguish between debug and release lib
set(CMAKE_DEBUG_POSTFIX "d")
# OUR SOURCES
set(libpng_public_hdrs
png.h
pngconf.h
)
set(libpng_sources
${libpng_public_hdrs}
pngpriv.h
png.c
pngerror.c
pngget.c
pngmem.c
pngpread.c
pngread.c
pngrio.c
pngrtran.c
pngrutil.c
pngset.c
pngtrans.c
pngwio.c
pngwrite.c
pngwtran.c
pngwutil.c
)
set(pngtest_sources
pngtest.c
)
# SOME NEEDED DEFINITIONS
add_definitions(-DPNG_CONFIGURE_LIBPNG)
if(_AIX)
add_definitions(-D_ALL_SOURCE)
endif(_AIX)
if(MSVC)
add_definitions(-DPNG_NO_MODULEDEF -D_CRT_SECURE_NO_DEPRECATE)
endif(MSVC)
if(PNG_SHARED OR NOT MSVC)
#if building msvc static this has NOT to be defined
add_definitions(-DZLIB_DLL)
endif()
if(PNG_CONSOLE_IO_SUPPORTED)
add_definitions(-DPNG_CONSOLE_IO_SUPPORTED)
endif()
if(PNG_NO_CONSOLE_IO)
add_definitions(-DPNG_NO_CONSOLE_IO)
endif()
if(PNG_NO_STDIO)
add_definitions(-DPNG_NO_STDIO)
endif()
if(PNG_DEBUG)
add_definitions(-DPNG_DEBUG)
endif()
if(NOT M_LIBRARY AND NOT WIN32)
add_definitions(-DPNG_NO_FLOATING_POINT_SUPPORTED)
endif()
# NOW BUILD OUR TARGET
include_directories(${CMAKE_CURRENT_SOURCE_DIR} ${ZLIB_INCLUDE_DIR})
if(PNG_SHARED)
add_library(${PNG_LIB_NAME} SHARED ${libpng_sources})
if(MSVC)
# msvc does not append 'lib' - do it here to have consistent name
set_target_properties(${PNG_LIB_NAME} PROPERTIES PREFIX "lib")
set_target_properties(${PNG_LIB_NAME} PROPERTIES IMPORT_PREFIX "lib")
endif()
target_link_libraries(${PNG_LIB_NAME} ${ZLIB_LIBRARY} ${M_LIBRARY})
endif()
if(PNG_STATIC)
# does not work without changing name
set(PNG_LIB_NAME_STATIC ${PNG_LIB_NAME}_static)
add_library(${PNG_LIB_NAME_STATIC} STATIC ${libpng_sources})
if(MSVC)
# msvc does not append 'lib' - do it here to have consistent name
set_target_properties(${PNG_LIB_NAME_STATIC} PROPERTIES PREFIX "lib")
endif()
target_link_libraries(${PNG_LIB_NAME_STATIC} ${ZLIB_LIBRARY} ${M_LIBRARY})
endif()
if(PNG_SHARED AND WIN32)
set_target_properties(${PNG_LIB_NAME} PROPERTIES DEFINE_SYMBOL PNG_BUILD_DLL)
endif()
if(PNG_TESTS AND PNG_SHARED)
# does not work with msvc due to png_lib_ver issue
add_executable(pngtest ${pngtest_sources})
target_link_libraries(pngtest ${PNG_LIB_NAME})
add_test(pngtest ./pngtest ${CMAKE_CURRENT_SOURCE_DIR}/pngtest.png)
endif()
#
# Set a variable with CMake code which:
# Creates a symlink from src to dest (if possible) or alternatively
# copies if different.
macro(_png_generate_symlink_code CODE SRC DEST)
if(WIN32 AND NOT CYGWIN)
set(_png_gsc_message "Copying ${SRC} to ${DEST} if needed")
set(_png_gsc_operation "copy_if_different")
else()
set(_png_gsc_message "Symlinking ${SRC} to ${DEST}")
set(_png_gsc_operation "create_symlink")
endif()
set(${CODE} "
message(STATUS \"${_png_gsc_message}\")
execute_process(COMMAND \${CMAKE_COMMAND} -E ${_png_gsc_operation}
\"${SRC}\" \"${DEST}\")
")
endmacro()
# CREATE PKGCONFIG FILES
# we use the same files like ./configure, so we have to set its vars
if(NOT DEFINED CMAKE_INSTALL_LIBDIR)
set(CMAKE_INSTALL_LIBDIR lib)
endif(NOT DEFINED CMAKE_INSTALL_LIBDIR)
set(prefix ${CMAKE_INSTALL_PREFIX})
set(exec_prefix ${CMAKE_INSTALL_PREFIX})
set(libdir ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR})
set(includedir ${CMAKE_INSTALL_PREFIX}/include)
set(LIBS "-lz -lm")
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/libpng.pc.in
${CMAKE_CURRENT_BINARY_DIR}/${PNGLIB_NAME}.pc @ONLY)
_png_generate_symlink_code(PNG_PC_INSTALL_CODE
${CMAKE_CURRENT_BINARY_DIR}/${PNGLIB_NAME}.pc
${CMAKE_CURRENT_BINARY_DIR}/libpng.pc)
install(CODE ${PNG_PC_INSTALL_CODE})
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/libpng-config.in
${CMAKE_CURRENT_BINARY_DIR}/${PNGLIB_NAME}-config @ONLY)
_png_generate_symlink_code(PNG_CONFIG_INSTALL_CODE
${CMAKE_CURRENT_BINARY_DIR}/${PNGLIB_NAME}-config
${CMAKE_CURRENT_BINARY_DIR}/libpng-config)
install(CODE ${PNG_CONFIG_INSTALL_CODE})
# SET UP LINKS
if(PNG_SHARED)
set_target_properties(${PNG_LIB_NAME} PROPERTIES
# VERSION 14.${PNGLIB_RELEASE}.1.4.8beta04
VERSION 14.${PNGLIB_RELEASE}.0
SOVERSION 14
CLEAN_DIRECT_OUTPUT 1)
endif()
if(PNG_STATIC)
# MSVC doesn't use a different file extension for shared vs. static
# libs. We are able to change OUTPUT_NAME to remove the _static
# for all other platforms.
if(NOT MSVC)
set_target_properties(${PNG_LIB_NAME_STATIC} PROPERTIES
OUTPUT_NAME ${PNG_LIB_NAME}
CLEAN_DIRECT_OUTPUT 1)
endif()
endif()
# If CMake > 2.4.x, we set a variable used below to export
# targets to an export file.
# TODO: Use VERSION_GREATER after our cmake_minimum_required >= 2.6.2
if(CMAKE_MAJOR_VERSION GREATER 1 AND CMAKE_MINOR_VERSION GREATER 4)
set(PNG_EXPORT_RULE EXPORT libpng)
elseif(CMAKE_MAJOR_VERSION GREATER 2) # future proof
set(PNG_EXPORT_RULE EXPORT libpng)
endif()
# INSTALL
if(NOT SKIP_INSTALL_LIBRARIES AND NOT SKIP_INSTALL_ALL )
if(PNG_SHARED)
install(TARGETS ${PNG_LIB_NAME}
${PNG_EXPORT_RULE}
RUNTIME DESTINATION bin
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
# Create a symlink for libpng.dll.a => libpng14.dll.a on Cygwin
if(CYGWIN)
_png_generate_symlink_code(PNG_SHARED_IMPLIB_INSTALL_CODE
${PNGLIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}
libpng${CMAKE_IMPORT_LIBRARY_SUFFIX})
install(CODE ${PNG_SHARED_IMPLIB_INSTALL_CODE})
install(FILES
${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_IMPORT_LIBRARY_SUFFIX}
DESTINATION ${CMAKE_INSTALL_LIBDIR})
endif()
if(NOT WIN32)
IF(CMAKE_LIBRARY_OUTPUT_DIRECTORY)
_png_generate_symlink_code(PNG_SHARED_INSTALL_CODE
${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${PNGLIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}
${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/libpng${CMAKE_SHARED_LIBRARY_SUFFIX})
install(CODE ${PNG_SHARED_INSTALL_CODE})
install(FILES
${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/libpng${CMAKE_SHARED_LIBRARY_SUFFIX}
DESTINATION ${CMAKE_INSTALL_LIBDIR})
ELSE(CMAKE_LIBRARY_OUTPUT_DIRECTORY)
_png_generate_symlink_code(PNG_SHARED_INSTALL_CODE
${PNGLIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}
libpng${CMAKE_SHARED_LIBRARY_SUFFIX})
install(CODE ${PNG_SHARED_INSTALL_CODE})
install(FILES
${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_SHARED_LIBRARY_SUFFIX}
DESTINATION ${CMAKE_INSTALL_LIBDIR})
ENDIF(CMAKE_LIBRARY_OUTPUT_DIRECTORY)
endif()
endif()
if(PNG_STATIC)
install(TARGETS ${PNG_LIB_NAME_STATIC}
${PNG_EXPORT_RULE}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
if(NOT WIN32 OR CYGWIN)
IF(CMAKE_ARCHIVE_OUTPUT_DIRECTORY)
_png_generate_symlink_code(PNG_STATIC_INSTALL_CODE
${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}/${PNGLIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}
${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}/libpng${CMAKE_STATIC_LIBRARY_SUFFIX})
install(CODE ${PNG_STATIC_INSTALL_CODE})
install(FILES
${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}/libpng${CMAKE_STATIC_LIBRARY_SUFFIX}
DESTINATION ${CMAKE_INSTALL_LIBDIR})
ELSE(CMAKE_ARCHIVE_OUTPUT_DIRECTORY)
_png_generate_symlink_code(PNG_STATIC_INSTALL_CODE
${PNGLIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}
libpng${CMAKE_STATIC_LIBRARY_SUFFIX})
install(CODE ${PNG_STATIC_INSTALL_CODE})
install(FILES
${CMAKE_CURRENT_BINARY_DIR}/libpng${CMAKE_STATIC_LIBRARY_SUFFIX}
DESTINATION ${CMAKE_INSTALL_LIBDIR})
ENDIF(CMAKE_ARCHIVE_OUTPUT_DIRECTORY)
endif()
endif()
endif()
if(NOT SKIP_INSTALL_HEADERS AND NOT SKIP_INSTALL_ALL )
install(FILES ${libpng_public_hdrs} DESTINATION include)
install(FILES ${libpng_public_hdrs} DESTINATION include/${PNGLIB_NAME})
endif()
if(NOT SKIP_INSTALL_EXECUTABLES AND NOT SKIP_INSTALL_ALL )
install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/libpng-config DESTINATION bin)
install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${PNGLIB_NAME}-config
DESTINATION bin)
endif()
if(NOT SKIP_INSTALL_FILES AND NOT SKIP_INSTALL_ALL )
# Install man pages
if(NOT PNG_MAN_DIR)
set(PNG_MAN_DIR "share/man")
endif()
install(FILES libpng.3 libpngpf.3 DESTINATION ${PNG_MAN_DIR}/man3)
install(FILES png.5 DESTINATION ${PNG_MAN_DIR}/man5)
# Install pkg-config files
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libpng.pc
DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/libpng-config
DESTINATION bin)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PNGLIB_NAME}.pc
DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${PNGLIB_NAME}-config
DESTINATION bin)
endif()
# On versions of CMake that support it, create an export file CMake
# users can include() to import our targets
if(PNG_EXPORT_RULE AND NOT SKIP_INSTALL_EXPORT AND NOT SKIP_INSTALL_ALL )
install(EXPORT libpng DESTINATION lib/libpng FILE lib${PNG_LIB_NAME}.cmake)
endif()
# what's with libpng-manual.txt and all the extra files?
# UNINSTALL
# do we need this?
# DIST
# do we need this?
# to create msvc import lib for mingw compiled shared lib
# pexports libpng.dll > libpng.def
# lib /def:libpng.def /machine:x86

167
INSTALL
View File

@@ -1,17 +1,53 @@
Installing libpng version 1.0.9beta1 - November 10, 2000
Installing libpng version 1.4.8beta04 - June 7, 2011
Before installing libpng, you must first install zlib. zlib
can usually be found wherever you got libpng. zlib can be
placed in another directory, at the same level as libpng.
Note that your system might already have a preinstalled
zlib, but you will still need to have access to the
zlib.h and zconf.h include files that correspond to the
version of zlib that's installed.
On Unix/Linux and similar systems, you can simply type
./configure [--prefix=/path]
make check
make install
and ignore the rest of this document.
If configure does not work on your system and you have a reasonably
up-to-date set of tools, running ./autogen.sh before running ./configure
may fix the problem. You can also run the individual commands in
autogen.sh with the --force option, if supported by your version of
the tools. If you run 'libtoolize --force', though, this will replace
the distributed, patched, version of ltmain.sh with an unpatched version
and your shared library builds may fail to produce libraries with the
correct version numbers.
Instead, you can use one of the custom-built makefiles in the
"scripts" directory
cp scripts/makefile.system makefile
make test
make install
The files that are presently available in the scripts directory
are listed and described in scripts/README.txt.
Or you can use one of the "projects" in the "projects" directory.
Before installing libpng, you must first install zlib, if it
is not already on your system. zlib can usually be found
wherever you got libpng. zlib can be placed in another directory,
at the same level as libpng.
If you want to use "cmake" (see www.cmake.org), type
cmake . -DCMAKE_INSTALL_PREFIX=/path
make
make install
If your system already has a preinstalled zlib you will still need
to have access to the zlib.h and zconf.h include files that
correspond to the version of zlib that's installed.
You can rename the directories that you downloaded (they
might be called "libpng-1.0.9beta1" or "lpng109" and "zlib-1.1.3"
or "zlib113") so that you have directories called "zlib" and "libpng".
might be called "libpng-1.4.8beta04" or "libpng14" and "zlib-1.2.3"
or "zlib123") so that you have directories called "zlib" and "libpng".
Your directory structure should look like this:
@@ -21,17 +57,27 @@ Your directory structure should look like this:
README
*.h
*.c
CMakeLists.txt => "cmake" script
configuration files:
configure.ac, configure, Makefile.am, Makefile.in,
autogen.sh, config.guess, ltmain.sh, missing,
aclocal.m4, config.h.in, config.sub,
depcomp, install-sh, test-pngtest.sh
contrib
gregbook
msvctest
pngminim
pngminus
pngsuite
visupng
dll
msvc
wince
projects
cbuilder5 (Borland)
visualc6 (msvc)
visualc71
vstudio
xcode
scripts
makefile.*
*.def (module definition files)
pngtest.png
etc.
zlib
@@ -45,61 +91,13 @@ If the line endings in the files look funny, you may wish to get the other
distribution of libpng. It is available in both tar.gz (UNIX style line
endings) and zip (DOS style line endings) formats.
If you are building libpng with MSVC, you can enter the libpng\msvc directory
and follow the instructions in msvc\README.txt. You can build libpng for
WindowsCE by entering the libpng\wince directory and following the
instructions in the README* files.
If you are building libpng with MSVC, you can enter the
libpng projects\visualc6 or visualc71 directory and follow the instructions
in README.txt.
Else enter the zlib directory and follow the instructions in zlib/README,
then come back here and choose the appropriate makefile.sys in the scripts
directory.
The files that are presently available in the scripts directory
include
makefile.std => Generic UNIX makefile (cc, creates static libpng.a)
makefile.linux => Linux/ELF makefile (gcc, creates libpng.so.2.1.0.9beta1)
makefile.gcmmx => Linux/ELF makefile (gcc, creates libpng.so.2.1.0.9beta1,
uses assembler code tuned for Intel MMX platform)
makefile.gcc => Generic makefile (gcc, creates static libpng.a)
makefile.knr => Archaic UNIX Makefile that converts files with
ansi2knr (Requires ansi2knr.c from
ftp://ftp.cs.wisc.edu/ghost)
makefile.cygwin => Cygwin/gcc makefile
makefile.dec => DEC Alpha UNIX makefile
makefile.hpux => HPUX (10.20 and 11.00) makefile
makefile.ibmc => IBM C/C++ version 3.x for Win32 and OS/2 (static)
makefile.intel => Intel C/C++ version 4.0 and later
libpng.icc => Project file for IBM VisualAge/C++ version 4.0 or later
makefile.sgi => Silicon Graphics IRIX makefile (cc, creates static lib)
makefile.sggcc => Silicon Graphics (gcc, creates libpng.so.2.1.0.9beta1)
makefile.sunos => Sun makefile
makefile.solaris => Solaris 2.X makefile (gcc, creates libpng.so.2.1.0.9beta1)
makefile.sco => For SCO OSr5 ELF and Unixware 7 with Native cc
makefile.mips => MIPS makefile
makefile.acorn => Acorn makefile
makefile.amiga => Amiga makefile
smakefile.ppc => AMIGA smakefile for SAS C V6.58/7.00 PPC compiler
(Requires SCOPTIONS, copied from scripts/SCOPTIONS.ppc)
makefile.atari => Atari makefile
makefile.beos => BEOS makefile for X86
makefile.bor => Borland makefile (uses bcc)
makefile.bc32 => 32-bit Borland C++ (all modules compiled in C mode)
makefile.bd32 => To make a png32bd.dll with Borland C++ 4.5
makefile.tc3 => Turbo C 3.0 makefile
makefile.dj2 => DJGPP 2 makefile
makefile.msc => Microsoft C makefile
makefile.vcawin32 => makefile for Microsoft Visual C++ 5.0 and later (uses
assembler code tuned for Intel MMX platform)
makefile.vcwin32 => makefile for Microsoft Visual C++ 4.0 and later (does
not use assembler code)
makefile.os2 => OS/2 Makefile (gcc and emx, requires pngos2.def)
pngos2.def => OS/2 module definition file used by makefile.os2
makefile.watcom => Watcom 10a+ Makefile, 32-bit flat memory model
makevms.com => VMS build script
descrip.mms => VMS makefile for MMS or MMK
pngdef.pas => Defines for a png32bd.dll with Borland C++ 4.5
SCOPTIONS.ppc => Used with smakefile.ppc
Otherwise enter the zlib directory and follow the instructions in zlib/README,
then come back here and run "configure" or choose the appropriate
makefile.sys in the scripts directory.
Copy the file (or files) that you need from the
scripts directory into this directory, for example
@@ -113,19 +111,34 @@ target directories to match your preferences.
Then read pngconf.h to see if you want to make any configuration
changes.
Then just run "make test" which will create the libpng library in
this directory and run a quick test that reads the "pngtest.png"
file and writes a "pngout.png" file that should be identical to it.
Look for "9782 zero samples" in the output of the test. For more
confidence, you can run another test by typing "pngtest pngnow.png"
and looking for "289 zero samples" in the output. Also, you can
run "pngtest -m *.png" in the "contrib/pngsuite" directory and compare
Then just run "make" which will create the libpng library in
this directory and "make test" which will run a quick test that reads
the "pngtest.png" file and writes a "pngout.png" file that should be
identical to it. Look for "9782 zero samples" in the output of the
test. For more confidence, you can run another test by typing
"pngtest pngnow.png" and looking for "289 zero samples" in the output.
Also, you can run "pngtest -m contrib/pngsuite/*.png" and compare
your output with the result shown in contrib/pngsuite/README.
Most of the makefiles will allow you to run "make install" to
put the library in its final resting place (if you want to
do that, run "make install" in the zlib directory first if necessary).
Some also allow you to run "make test-installed" after you have
run "make install".
If you encounter a compiler error message complaining about the
lines
__png.h__ already includes setjmp.h;
__dont__ include it again.;
this means you have compiled another module that includes setjmp.h,
which is hazardous because the two modules might not include exactly
the same setjmp.h. If you are sure that you know what you are doing
and that they are exactly the same, then you can comment out or
delete the two lines. Better yet, use the cexcept interface
instead, as demonstrated in contrib/visupng of the libpng distribution.
Further information can be found in the README and libpng.txt
files, in the individual makefiles, in png.h, in the README files in
subdirectories of the dll directory, and the manual pages libpng.3 and png.5.
files, in the individual makefiles, in png.h, and the manual pages
libpng.3 and png.5.

View File

@@ -1,65 +0,0 @@
Known bugs and suggested enhancements in libpng-1.0.8
0: November 3, 2000 -- BUG -- incorrect iCCP chunk is written
The compression_type byte in the iCCP chunk written by libpng is
usually incorrect.
Status: Fixed in libpng-1.0.9beta1
1. October 12, 2000 -- BUG -- pngtest fails
The three WRITEFILE calls in pngtest.c are incorrect. They must be
changed to read
WRITEFILE((png_FILE_p)png_ptr->io_ptr, data, length, check);
WRITEFILE(io_ptr, near_data, length, check);
WRITEFILE(io_ptr, buf, written, err);
2. August 28, 2000 -- BUG -- pnggccrd.c
The interlacing() function has still not been fully converted and
will not compile under gcc-2.95.2; it is currently ifdef'ed out.
STATUS: Fixed in libpng-1.0.9. There were also bugs in pngvcrd.c
which have been fixed. The replacement files are available at the
PNG web site (http://www.libpng.org/pub/png).
3. March 15, 1998 -- OPTIMIZATION -- Kevin Bracey
Loops need to be optimized everywhere
Make them count down instead of up -- Kevin Bracey
Optimizing compilers don't need this, and making
the change would be error prone -- Tom Lane, Glenn R-P
Question whether i-- or --i is better.
STATUS: Under investigation, postponed until after
libpng-2.0.0. About 160 loops will be turned around
in libpng-2.0.x betaxx, for testing.
4. July 4, 1998 -- ENHANCEMENT -- Glenn R-P
libpng-1.0.5 and earlier transform colors to gamma=1.0 space for
merging with background, and then back to the image's gamma. The
bit_depth of the intermediate (gamma=1.0) representation is probably
not sufficient. In the typical gamma=1/2.2 situation, the linear
pixels need about 4 more bits than the gamma-encoded ones, to avoid
loss of precision. A similar situation exists with the rgb_to_gray
operation.
STATUS: under development.
5. September 1999 -- ENHANCEMENT --
It should be possible to use libpng without floating-point arithmetic.
STATUS: Under investigation, implementation postponed until after
libpng-2.0.0.
Much of this was completed in libpng-1.0.6, but gamma compensation
is not yet done in fixed-point arithmetic.

19
LICENSE
View File

@@ -8,9 +8,18 @@ COPYRIGHT NOTICE, DISCLAIMER, and LICENSE:
If you modify libpng you may insert additional notices immediately following
this sentence.
libpng versions 1.0.7, July 1, 2000, through 1.0.9beta1, November 10, 2000, are
Copyright (c) 2000 Glenn Randers-Pehrson
and are distributed according to the same disclaimer and license as libpng-1.0.6
This code is released under the libpng license.
libpng versions 1.2.6, August 15, 2004, through 1.4.8beta04, June 7, 2011, are
Copyright (c) 2004, 2006-2010 Glenn Randers-Pehrson, and are
distributed according to the same disclaimer and license as libpng-1.2.5
with the following individual added to the list of Contributing Authors
Cosmin Truta
libpng versions 1.0.7, July 1, 2000, through 1.2.5 - October 3, 2002, are
Copyright (c) 2000-2002 Glenn Randers-Pehrson, and are
distributed according to the same disclaimer and license as libpng-1.0.6
with the following individuals added to the list of Contributing Authors
Simon-Pierre Cadieux
@@ -98,5 +107,5 @@ Libpng is OSI Certified Open Source Software. OSI Certified Open Source is a
certification mark of the Open Source Initiative.
Glenn Randers-Pehrson
randeg@alum.rpi.edu
November 10, 2000
glennrp at users.sourceforge.net
June 7, 2011

132
Makefile.am Normal file
View File

@@ -0,0 +1,132 @@
# Makefile.am:
# Source file for Makefile.in (and hence Makefile)
#
PNGLIB_BASENAME= libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@
# libpng does not follow GNU file name conventions
AUTOMAKE_OPTIONS = foreign
# test programs - run on make check, make distcheck
check_PROGRAMS= pngtest
pngtest_SOURCES = pngtest.c
pngtest_LDADD = libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@.la
TESTS = test-pngtest.sh
TESTS_ENVIRONMENT= srcdir=$(srcdir)
# man pages
dist_man_MANS= libpng.3 libpngpf.3 png.5
# generate the -config scripts if required
binconfigs= libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@-config
EXTRA_SCRIPTS= libpng-config libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@-config
bin_SCRIPTS= @binconfigs@
# rules to build libpng, only build the old library on request
lib_LTLIBRARIES=libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@.la
# EXTRA_LTLIBRARIES= libpng.la
libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_SOURCES = png.c pngset.c pngget.c pngrutil.c \
pngtrans.c pngwutil.c \
pngread.c pngrio.c pngwio.c pngwrite.c pngrtran.c \
pngwtran.c pngmem.c pngerror.c pngpread.c \
png.h pngconf.h pngpriv.h
libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_CPPFLAGS = @LIBPNG_DEFINES@
libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_LDFLAGS = -no-undefined -export-dynamic \
-version-number @PNGLIB_MAJOR@@PNGLIB_MINOR@:@PNGLIB_RELEASE@:0
if HAVE_LD_VERSION_SCRIPT
# Versioned symbols and restricted exports
libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_LDFLAGS += -Wl,--version-script=libpng.vers
libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_DEPENDENCIES = libpng.vers
else
# Only restricted exports when possible
libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_LDFLAGS += -export-symbols libpng.sym
libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@_la_DEPENDENCIES = libpng.sym
endif
# Avoid depending upon Character Ranges.
AN = '_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'
#distribute headers in /usr/include/libpng/*
pkgincludedir= $(includedir)/$(PNGLIB_BASENAME)
pkginclude_HEADERS= png.h pngconf.h
# pkg-config stuff, note that libpng.pc is always required in order
# to get the correct library
pkgconfigdir = @pkgconfigdir@
pkgconfig_DATA = libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@.pc
#extra source distribution files.
EXTRA_DIST= \
ANNOUNCE CHANGES INSTALL LICENSE README TODO \
pngtest.png pngbar.png pngnow.png pngbar.jpg autogen.sh \
${srcdir}/projects/visualc6/* \
${srcdir}/projects/visualc71/* \
${srcdir}/projects/xcode/* \
${srcdir}/scripts/* \
${srcdir}/contrib/gregbook/* \
${srcdir}/contrib/pngminim/* \
${srcdir}/contrib/pngminus/* \
${srcdir}/contrib/pngsuite/* \
${srcdir}/contrib/visupng/* \
$(TESTS) \
example.c libpng-1.4.8beta04.txt
CLEANFILES= pngout.png libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@.pc libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@-config libpng.vers \
libpng.sym
MAINTAINERCLEANFILES = Makefile.in aclocal.m4 config.guess config.h.in \
config.sub configure depcomp install-sh ltmain.sh missing
$(PNGLIB_BASENAME).pc: libpng.pc
cp libpng.pc $@
$(PNGLIB_BASENAME)-config: libpng-config
cp libpng-config $@
libpng.sym: png.h pngconf.h
rm -f $@ $@.new
$(CPP) @LIBPNG_DEFINES@ $(CPPFLAGS) -DPNG_BUILDSYMS $(srcdir)/png.h | \
$(SED) -n -e \
's|^.*PNG_FUNCTION_EXPORT[ ]*\([$(AN)]*\).*$$|$(SYMBOL_PREFIX)\1|p' \
-e 's|^.*PNG_DATA_EXPORT[ ]*\([$(AN)]*\).*$$|$(SYMBOL_PREFIX)\1|p' \
>$@.new
mv $@.new $@
libpng.vers: libpng.sym
rm -f $@ $@.new
echo PNG@PNGLIB_MAJOR@@PNGLIB_MINOR@_0 '{global:' > $@.new
$(SED) s/$$/\;/ libpng.sym >> $@.new
echo 'local: *; };' >> $@.new
mv $@.new $@
test: check
# install the .../include headers as links to the new ones
install-data-hook:
cd $(DESTDIR)$(includedir); rm -f png.h pngconf.h
cd $(DESTDIR)$(includedir); $(LN_S) $(PNGLIB_BASENAME)/png.h png.h
cd $(DESTDIR)$(includedir); $(LN_S) $(PNGLIB_BASENAME)/pngconf.h \
pngconf.h
cd $(DESTDIR)$(pkgconfigdir); rm -f libpng.pc
cd $(DESTDIR)$(pkgconfigdir); $(LN_S) $(PNGLIB_BASENAME).pc libpng.pc
# do evil things to libpng to cause libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@ to be used
install-exec-hook:
cd $(DESTDIR)$(bindir); rm -f libpng-config
cd $(DESTDIR)$(bindir); $(LN_S) $(PNGLIB_BASENAME)-config libpng-config
@set -x;\
cd $(DESTDIR)$(libdir);\
for ext in a la so so.@PNGLIB_MAJOR@@PNGLIB_MINOR@.@PNGLIB_RELEASE@ sl dylib dll.a; do\
rm -f libpng.$$ext;\
if test -f $(PNGLIB_BASENAME).$$ext; then\
$(LN_S) $(PNGLIB_BASENAME).$$ext libpng.$$ext;\
fi;\
done
uninstall-hook:
cd $(DESTDIR)$(includedir); rm -f png.h pngconf.h
rm -f $(DESTDIR)$(pkgconfigdir)/libpng.pc
rm -f $(DESTDIR)$(bindir)/libpng-config

1261
Makefile.in Normal file

File diff suppressed because it is too large Load Diff

118
README
View File

@@ -1,11 +1,11 @@
README for libpng 1.0.9beta1 - November 10, 2000 (shared library 2.1)
README for libpng version 1.4.8beta04 - June 7, 2011 (shared library 14.0)
See the note about version numbers near the top of png.h
See INSTALL for instructions on how to install libpng.
Libpng comes in two distribution formats. Get libpng-*.tar.gz if you
want UNIX-style line endings in the text files, or lpng*.zip if you want
DOS-style line endings.
Libpng comes in several distribution formats. Get libpng-*.tar.gz,
libpng-*.tar.xz or libpng-*.tar.bz2 if you want UNIX-style line endings
in the text files, or lpng*.zip if you want DOS-style line endings.
Version 0.89 was the first official release of libpng. Don't let the
fact that it's the first release fool you. The libpng library has been in
@@ -54,9 +54,9 @@ to set different actions based on whether the CRC error occurred in a
critical or an ancillary chunk.
The changes made to the library, and bugs fixed are based on discussions
on the PNG implementation mailing list <png-implement@ccrc.wustl.edu>
and not on material submitted privately to Guy, Andreas, or Glenn. They will
forward any good suggestions to the list.
on the PNG-implement mailing list and not on material submitted
privately to Guy, Andreas, or Glenn. They will forward any good
suggestions to the list.
For a detailed description on using libpng, read libpng.txt. For
examples of libpng in a program, see example.c and pngtest.c. For usage
@@ -77,16 +77,15 @@ compression library that is useful for more things than just PNG files.
You can use zlib as a drop-in replacement for fread() and fwrite() if
you are so inclined.
zlib should be available at the same place that libpng is.
If not, it should be at ftp.uu.net in /graphics/png
Eventually, it will be at ftp.uu.net in /pub/archiving/zip/zlib
zlib should be available at the same place that libpng is, or at.
ftp://ftp.info-zip.org/pub/infozip/zlib
You may also want a copy of the PNG specification. It is available
as an RFC and a W3C Recommendation. Failing
these resources you can try ftp.uu.net in the /graphics/png directory.
as an RFC, a W3C Recommendation, and an ISO/IEC Standard. You can find
these at http://www.libpng.org/pub/png/documents/
This code is currently being archived at ftp.uu.net in the
/graphics/png directory, and on CompuServe, Lib 20 (PNG SUPPORT)
This code is currently being archived at libpng.sf.net in the
[DOWNLOAD] area, and on CompuServe, Lib 20 (PNG SUPPORT)
at GO GRAPHSUP. If you can't find it in any of those places,
e-mail me, and I'll help you find it.
@@ -102,30 +101,32 @@ Finally, if you get any warning messages when compiling libpng
fix. Please mention "libpng" somewhere in the subject line. Thanks.
This release was created and will be supported by myself (of course
based in a large way on Guy's and Andreas' earlier work), and the PNG group.
based in a large way on Guy's and Andreas' earlier work), and the PNG
development group.
randeg@alum.rpi.edu
png-implement@ccrc.wustl.edu
Send comments/corrections/commendations to png-mng-implement at
lists.sourceforge.net (subscription required; visit
https://lists.sourceforge.net/lists/listinfo/png-mng-implement
to subscribe) or to glennrp at users.sourceforge.net
You can't reach Guy, the original libpng author, at the addresses
given in previous versions of this document. He and Andreas will read mail
addressed to the png-implement list, however.
given in previous versions of this document. He and Andreas will
read mail addressed to the png-implement list, however.
Please do not send general questions about PNG. Send them to
the address in the specification (png-group@w3.org). At the same
time, please do not send libpng questions to that address, send them to me
or to png-implement@ccrc.wustl.edu. I'll
get them in the end anyway. If you have a question about something
png-mng-misc at lists.sf.net (subscription required; visit
https://lists.sourceforge.net/lists/listinfo/png-mng-misc to
subscribe). If you have a question about something
in the PNG specification that is related to using libpng, send it
to me. Send me any questions that start with "I was using libpng,
and ...". If in doubt, send questions to me. I'll bounce them
to others, if necessary.
Please do not send suggestions on how to change PNG. We have
been discussing PNG for three years now, and it is official and
been discussing PNG for sixteen years now, and it is official and
finished. If you have suggestions for libpng, however, I'll
gladly listen. Even if your suggestion is not used for version
1.0, it may be used later.
gladly listen. Even if your suggestion is not used immediately,
it may be used later.
Files in this distribution:
@@ -144,7 +145,6 @@ Files in this distribution:
png.c => Basic interface functions common to library
png.h => Library function and interface declarations
pngconf.h => System specific library configuration
pngasmrd.h => Header file for assembler-coded functions
pngerror.c => Error/warning message I/O functions
pngget.c => Functions for retrieving info from struct
pngmem.c => Memory handling functions
@@ -171,34 +171,49 @@ Files in this distribution:
pngminus => Simple pnm2png and png2pnm programs
pngsuite => Test images
visupng => Contains a MSVC workspace for VisualPng
dll => Contains project files and workspaces for building DLL
msvc => Contains a Microsoft Visual C++ (MSVC) workspace
for building libpng and zlib
wince => Contains a Microsoft Visual C++ (Windows CD Toolkit)
workspace for building libpng and zlib on WindowsCE
projects => Contains project files and workspaces for
building a DLL
c5builder => Contains a Borland workspace for building
libpng and zlib
visualc6 => Contains a Microsoft Visual C++ (MSVC)
workspace for building libpng and zlib
scripts => Directory containing scripts for building libpng:
descrip.mms => VMS makefile for MMS or MMK
makefile.std => Generic UNIX makefile (cc, creates static libpng.a)
makefile.std => Generic UNIX makefile (cc, creates static
libpng.a)
makefile.elf => Linux/ELF makefile symbol versioning,
(gcc, creates libpng14.so.14.1.4.8beta04)
makefile.linux => Linux/ELF makefile
(gcc, creates libpng.so.2.1.0.9beta1)
makefile.gcmmx => Linux/ELF makefile (gcc, creates
libpng.so.2.1.0.9beta1, uses assembler code
tuned for Intel MMX platform)
(gcc, creates libpng14.so.14.1.4.8beta04)
makefile.gcc => Generic makefile (gcc, creates static libpng.a)
makefile.knr => Archaic UNIX Makefile that converts files with
ansi2knr (Requires ansi2knr.c from
ftp://ftp.cs.wisc.edu/ghost)
makefile.aix => AIX makefile
makefile.cygwin => Cygwin/gcc makefile
makefile.darwin => Darwin makefile
makefile.dec => DEC Alpha UNIX makefile
makefile.freebsd => FreeBSD makefile
makefile.hpgcc => HPUX makefile using gcc
makefile.hpux => HPUX (10.20 and 11.00) makefile
makefile.hp64 => HPUX (10.20 and 11.00) makefile, 64 bit
makefile.ibmc => IBM C/C++ version 3.x for Win32 and OS/2 (static)
makefile.intel => Intel C/C++ version 4.0 and later
libpng.icc => Project file, IBM VisualAge/C++ 4.0 or later
makefile.mingw => Mingw/gcc makefile
makefile.netbsd => NetBSD/cc makefile, makes libpng.so.
makefile.ne14bsd => NetBSD/cc makefile, makes
libpng14.so
makefile.openbsd => OpenBSD makefile
makefile.sgi => Silicon Graphics IRIX (cc, creates static lib)
makefile.sggcc => Silicon Graphics (gcc, creates libpng.so.2.1.0.9beta1)
makefile.sggcc => Silicon Graphics
(gcc, creates libpng14.so.14.1.4.8beta04)
makefile.sunos => Sun makefile
makefile.solaris => Solaris 2.X makefile
(gcc, creates libpng.so.2.1.0.9beta1)
(gcc, creates libpng14.so.14.1.4.8beta04)
makefile.so9 => Solaris 9 makefile
(gcc, creates libpng14.so.14.1.4.8beta04)
makefile.32sunu => Sun Ultra 32-bit makefile
makefile.64sunu => Sun Ultra 64-bit makefile
makefile.sco => For SCO OSr5 ELF and Unixware 7 with Native cc
makefile.mips => MIPS makefile
makefile.acorn => Acorn makefile
@@ -210,31 +225,30 @@ Files in this distribution:
makefile.beos => BEOS makefile for X86
makefile.bor => Borland makefile (uses bcc)
makefile.bc32 => 32-bit Borland C++ (all modules compiled in C mode)
makefile.bd32 => To make a png32bd.dll with Borland C++ 4.5
makefile.tc3 => Turbo C 3.0 makefile
makefile.dj2 => DJGPP 2 makefile
makefile.msc => Microsoft C makefile
makefile.vcawin32 => makefile for Microsoft Visual C++ 5.0 and
later (uses assembler code tuned for Intel MMX
platform)
makefile.vcwin32 => makefile for Microsoft Visual C++ 4.0 and
later (does not use assembler code)
makefile.os2 => OS/2 Makefile (gcc and emx, requires pngos2.def)
pngos2.def => OS/2 module definition file used by makefile.os2
png32ce.def => module definition for makefile.cegccg
pngos2.def => OS/2 module definition file used by
makefile.os2
pngwin.def => module definition file used by
makefile.cygwin and makefile.mingw
makefile.watcom => Watcom 10a+ Makefile, 32-bit flat memory model
makevms.com => VMS build script
pngdef.pas => Defines for a png32bd.dll with Borland C++ 4.5
SCOPTIONS.ppc => Used with smakefile.ppc
Good luck, and happy coding.
-Glenn Randers-Pehrson
Internet: randeg@alum.rpi.edu
-Glenn Randers-Pehrson (current maintainer, since 1998)
Internet: glennrp at users.sourceforge.net
-Andreas Eric Dilger
Internet: adilger@enel.ucalgary.ca
-Andreas Eric Dilger (former maintainer, 1996-1997)
Internet: adilger at enel.ucalgary.ca
Web: http://www-mddsp.enel.ucalgary.ca/People/adilger/
-Guy Eric Schalnat
-Guy Eric Schalnat (original author and former maintainer, 1995-1996)
(formerly of Group 42, Inc)
Internet: gschal@infinet.com
Internet: gschal at infinet.com

14
TODO
View File

@@ -1,3 +1,4 @@
/*
TODO - list of things to do for libpng:
Final bug fixes.
@@ -8,7 +9,7 @@ Fix problem with C++ and EXTERN "C".
cHRM transformation.
Improve setjmp/longjmp usage or remove it in favor of returning error codes.
Add "grayscale->palette" transformation and "palette->grayscale" detection.
Improved dithering.
Improved quantizing and dithering.
Multi-lingual error and warning message support.
Complete sRGB transformation (presently it simply uses gamma=0.45455).
Man pages for function calls.
@@ -17,3 +18,14 @@ Better filter selection
(counting huffman bits/precompression? filter inertia? filter costs?).
Histogram creation.
Text conversion between different code pages (Latin-1 -> Mac and DOS).
Build gamma tables using fixed point (and do away with floating point entirely).
Avoid building gamma tables whenever possible.
Use greater precision when changing to linear gamma for compositing against
background and doing rgb-to-gray transformation.
Investigate pre-incremented loop counters and other loop constructions.
Add interpolated method of handling interlacing.
Provide for conditional compilation of 16-bit support (except for the
initial stripping down to 8-bits when reading a 16-bit PNG datastream).
Switch to the simpler zlib (zlib/libpng) license if legally possible.
*/

55
Y2KINFO
View File

@@ -1,55 +0,0 @@
Y2K compliance in libpng:
=========================
November 10, 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.9beta1 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
that will hold years up to 65535. The other two hold the date in text
format, and will hold years up to 9999.
The integer is
"png_uint_16 year" in png_time_struct.
The strings are
"png_charp time_buffer" in png_struct and
"near_time_buffer", which is a local character string in png.c.
There are seven time-related functions:
png_convert_to_rfc_1123() in png.c
(formerly png_convert_to_rfc_1152() in error)
png_convert_from_struct_tm() in pngwrite.c, called in pngwrite.c
png_convert_from_time_t() in pngwrite.c
png_get_tIME() in pngget.c
png_handle_tIME() in pngrutil.c, called in pngread.c
png_set_tIME() in pngset.c
png_write_tIME() in pngwutil.c, called in pngwrite.c
All appear to handle dates properly in a Y2K environment. The
png_convert_from_time_t() function calls gmtime() to convert from system
clock time, which returns (year - 1900), which we properly convert to
the full 4-digit year. There is a possibility that applications using
libpng are not passing 4-digit years into the png_convert_to_rfc_1123()
function, or that they are incorrectly passing only a 2-digit year
instead of "year - 1900" into the png_convert_from_struct_tm() function,
but this is not under our control. The libpng documentation has always
stated that it works with 4-digit years, and the APIs have been
documented as such.
The tIME chunk itself is also Y2K compliant. It uses a 2-byte unsigned
integer to hold the year, and can hold years as large as 65535.
zlib, upon which libpng depends, is also Y2K compliant. It contains
no date-related code.
Glenn Randers-Pehrson
libpng maintainer
PNG Development Group

9036
aclocal.m4 vendored Normal file

File diff suppressed because it is too large Load Diff

34
autogen.sh Executable file
View File

@@ -0,0 +1,34 @@
#! /bin/sh
# a quick hack script to generate necessary files from
# auto* tools.
#
# WARNING: if you run this you will change the versions
# of the tools which are used and, maybe, required!
# You can define your own replacements in your environment.
# $AUTOCONF, $AUTOMAKE, $AUTOHEADER, $AUTOPOINT, $ACLOCAL and $LIBTOOLIZE
touch Makefile.am configure.ac
{
LT=${LIBTOOLIZE-libtoolize}
echo "running $LT" >&2
$LT --force --copy --automake
} && {
AL=${ACLOCAL-aclocal}
echo "running $AL" >&2
$AL
} && {
AH=${AUTOHEADER-autoheader}
echo "running $AH [ignore the warnings]" >&2
$AH
} && {
AM=${AUTOMAKE-automake}
echo "running $AM" >&2
$AM --force-missing --foreign -a -c
} && {
AC=${AUTOCONF-autoconf}
echo "running $AC" >&2
$AC
} &&
echo "autogen complete" >&2 ||
echo "ERROR: autogen.sh failed, autogen is incomplete" >&2

1501
config.guess vendored Executable file

File diff suppressed because it is too large Load Diff

86
config.h.in Normal file
View File

@@ -0,0 +1,86 @@
/* config.h.in. Generated from configure.ac by autoheader. */
/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define to 1 if you have the `m' library (-lm). */
#undef HAVE_LIBM
/* Define to 1 if you have the `z' library (-lz). */
#undef HAVE_LIBZ
/* Define to 1 if you have the <malloc.h> header file. */
#undef HAVE_MALLOC_H
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the `memset' function. */
#undef HAVE_MEMSET
/* Define to 1 if you have the `pow' function. */
#undef HAVE_POW
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define to the sub-directory in which libtool stores uninstalled libraries.
*/
#undef LT_OBJDIR
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the home page for this package. */
#undef PACKAGE_URL
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Define to 1 if your <sys/time.h> declares `struct tm'. */
#undef TM_IN_SYS_TIME
/* Version number of package */
#undef VERSION
/* Define to empty if `const' does not conform to ANSI C. */
#undef const
/* Define to `unsigned int' if <sys/types.h> does not define. */
#undef size_t

1705
config.sub vendored Executable file

File diff suppressed because it is too large Load Diff

14002
configure vendored

File diff suppressed because it is too large Load Diff

140
configure.ac Normal file
View File

@@ -0,0 +1,140 @@
# configure.ac
dnl Process this file with autoconf to produce a configure script.
dnl
dnl Minor upgrades (compatible ABI): increment the package version
dnl (third field in two places below) and set the PNGLIB_RELEASE
dnl variable.
dnl
dnl Major upgrades (incompatible ABI): increment the package major
dnl version (second field, or first if desired), set the minor
dnl to 0, set PNGLIB_MAJOR below *and* follow the instructions in
dnl Makefile.am to upgrade the package name.
dnl This is here to prevent earlier autoconf from being used, it
dnl should not be necessary to regenerate configure if the time
dnl stamps are correct
AC_PREREQ(2.59)
AC_INIT([libpng], [1.4.8beta04], [png-mng-implement@lists.sourceforge.net])
AM_INIT_AUTOMAKE
dnl stop configure from automagically running automake
AM_MAINTAINER_MODE
dnl Version number stuff here:
PNGLIB_VERSION=1.4.8beta04
PNGLIB_MAJOR=1
PNGLIB_MINOR=4
PNGLIB_RELEASE=8
dnl End of version number stuff
AC_CONFIG_SRCDIR([pngget.c])
AM_CONFIG_HEADER(config.h)
# Checks for programs.
AC_PROG_CC
AC_PROG_LD
AC_PROG_CPP
AC_CHECK_TOOL(SED, sed, :)
AC_PROG_INSTALL
AC_PROG_LN_S
AC_PROG_MAKE_SET
LT_INIT([win32-dll])
# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([malloc.h stdlib.h string.h strings.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_TYPE_SIZE_T
AC_STRUCT_TM
# Checks for library functions.
AC_FUNC_STRTOD
AC_CHECK_FUNCS([memset], , AC_ERROR([memset not found in libc]))
AC_CHECK_FUNCS([pow], , AC_CHECK_LIB(m, pow, , AC_ERROR([cannot find pow])) )
AC_CHECK_LIB(z, zlibVersion, , AC_ERROR([zlib not installed]))
case $host_os in
aix*)
LIBPNG_DEFINES="-DPNG_CONFIGURE_LIBPNG -D_ALL_SOURCE";;
*)
LIBPNG_DEFINES=-DPNG_CONFIGURE_LIBPNG;;
esac
LIBPNG_DEFINES=$LIBPNG_DEFINES
AC_SUBST(LIBPNG_DEFINES)
AC_MSG_CHECKING([if libraries can be versioned])
# Special case for PE/COFF platforms: ld reports
# support for version-script, but doesn't actually
# DO anything with it.
case $host in
*cygwin* | *mingw32* )
have_ld_version_script=no
AC_MSG_RESULT(no)
;;
* )
GLD=`$LD --help < /dev/null 2>/dev/null | grep version-script`
if test "$GLD"; then
have_ld_version_script=yes
AC_MSG_RESULT(yes)
else
have_ld_version_script=no
AC_MSG_RESULT(no)
AC_MSG_WARN(*** You have not enabled versioned symbols.)
fi
;;
esac
AM_CONDITIONAL(HAVE_LD_VERSION_SCRIPT, test "$have_ld_version_script" = "yes")
if test "$have_ld_version_script" = "yes"; then
AC_MSG_CHECKING([for symbol prefix])
SYMBOL_PREFIX=`echo "PREFIX=__USER_LABEL_PREFIX__" \
| ${CPP-${CC-gcc} -E} - 2>&1 \
| ${EGREP-grep} "^PREFIX=" \
| ${SED-sed} "s:^PREFIX=::"`
AC_SUBST(SYMBOL_PREFIX)
AC_MSG_RESULT($SYMBOL_PREFIX)
fi
# Substitutions for .in files
AC_SUBST(PNGLIB_VERSION)
AC_SUBST(PNGLIB_MAJOR)
AC_SUBST(PNGLIB_MINOR)
AC_SUBST(PNGLIB_RELEASE)
# Additional arguments (and substitutions)
# Allow the pkg-config directory to be set
AC_ARG_WITH(pkgconfigdir,
AC_HELP_STRING([--with-pkgconfigdir],
[Use the specified pkgconfig dir (default is libdir/pkgconfig)]),
[pkgconfigdir=${withval}],
[pkgconfigdir='${libdir}/pkgconfig'])
AC_SUBST([pkgconfigdir])
AC_MSG_NOTICE([pkgconfig directory is ${pkgconfigdir}])
# Make the *-config binary config scripts optional
AC_ARG_WITH(binconfigs,
AC_HELP_STRING([--with-binconfigs],
[Generate shell libpng-config scripts as well as pkg-config data]
[@<:@default=yes@:>@]),
[if test "${withval}" = no; then
binconfigs=
AC_MSG_NOTICE([libpng-config scripts will not be built])
else
binconfigs='${binconfigs}'
fi],
[binconfigs='${binconfigs}'])
AC_SUBST([binconfigs])
# Config files, substituting as above
AC_CONFIG_FILES([Makefile libpng.pc:libpng.pc.in])
AC_CONFIG_FILES([libpng-config:libpng-config.in],
[chmod +x libpng-config])
AC_OUTPUT

340
contrib/gregbook/COPYING Normal file
View File

@@ -0,0 +1,340 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Library General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General
Public License instead of this License.

View File

@@ -1,12 +1,19 @@
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2008 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -23,4 +30,21 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------

View File

@@ -0,0 +1,130 @@
# Sample makefile for rpng-win / rpng2-win / wpng using mingw32-gcc and make.
# Greg Roelofs
# Last modified: 2 June 2007
#
# The programs built by this makefile are described in the book,
# "PNG: The Definitive Guide," by Greg Roelofs (O'Reilly and
# Associates, 1999). Go buy a copy, eh? Well, OK, it's not
# generally for sale anymore, but it's the thought that counts,
# right? (Hint: http://www.libpng.org/pub/png/book/ )
#
# Invoke this makefile from a DOS-prompt window via:
#
# make -f Makefile.mingw32
#
# This makefile assumes libpng and zlib have already been built or downloaded
# and are in subdirectories at the same level as the current subdirectory
# (as indicated by the PNGDIR and ZDIR macros below). It makes no assumptions
# at all about the mingw32 installation tree (W32DIR). Edit as appropriate.
#
# Note that the names of the dynamic and static libpng and zlib libraries
# used below may change in later releases of the libraries. This makefile
# builds both statically and dynamically linked executables by default.
# (You need only one set, but for testing it can be handy to have both.)
# macros --------------------------------------------------------------------
#PNGDIR = ../..# for libpng-x.y.z/contrib/gregbook builds
PNGDIR = ../libpng-win32
PNGINC = -I$(PNGDIR)
PNGLIBd = $(PNGDIR)/libpng.dll.a # dynamically linked
PNGLIBs = $(PNGDIR)/libpng.a # statically linked, local libpng
#ZDIR = ../../../zlib-win32# for libpng-x.y.z/contrib/gregbook builds
ZDIR = ../zlib-win32
ZINC = -I$(ZDIR)
ZLIBd = $(ZDIR)/libzdll.a
ZLIBs = $(ZDIR)/libz.a
# change this to be the path where mingw32 installs its stuff:
W32DIR =
#W32DIR = /usr/local/cross-tools/i386-mingw32msvc
W32INC = -I$(W32DIR)/include
W32LIB = $(W32DIR)/lib/libuser32.a $(W32DIR)/lib/libgdi32.a
CC = gcc
#CC = i386-mingw32msvc-gcc # e.g., Linux -> Win32 cross-compilation
LD = $(CC)
RM = rm -f
CFLAGS = -O -Wall $(INCS) $(MINGW_CCFLAGS)
# [note that -Wall is a gcc-specific compilation flag ("most warnings on")]
# [-ansi, -pedantic and -W can also be used]
LDFLAGS = $(MINGW_LDFLAGS)
O = .o
E = .exe
INCS = $(PNGINC) $(ZINC) $(W32INC)
RLIBSd = $(PNGLIBd) $(ZLIBd) $(W32LIB) -lm
RLIBSs = $(PNGLIBs) $(ZLIBs) $(W32LIB) -lm
WLIBSd = $(PNGLIBd) $(ZLIBd)
WLIBSs = $(PNGLIBs) $(ZLIBs)
RPNG = rpng-win
RPNG2 = rpng2-win
WPNG = wpng
ROBJSd = $(RPNG)$(O) readpng.pic$(O)
ROBJS2d = $(RPNG2)$(O) readpng2.pic$(O)
WOBJSd = $(WPNG)$(O) writepng.pic$(O)
RPNGs = $(RPNG)-static
RPNG2s = $(RPNG2)-static
WPNGs = $(WPNG)-static
ROBJSs = $(RPNG)$(O) readpng$(O)
ROBJS2s = $(RPNG2)$(O) readpng2$(O)
WOBJSs = $(WPNG)$(O) writepng$(O)
STATIC_EXES = $(RPNGs)$(E) $(RPNG2s)$(E) $(WPNGs)$(E)
DYNAMIC_EXES = $(RPNG)$(E) $(RPNG2)$(E) $(WPNG)$(E)
EXES = $(STATIC_EXES) $(DYNAMIC_EXES)
# implicit make rules -------------------------------------------------------
.c$(O):
$(CC) -c $(CFLAGS) $<
%.pic$(O): %.c
$(CC) -c $(CFLAGS) -DPNG_BUILD_DLL -o $@ $<
# dependencies --------------------------------------------------------------
all: $(EXES)
$(RPNGs)$(E): $(ROBJSs)
$(LD) $(LDFLAGS) -o $@ $(ROBJSs) $(RLIBSs)
$(RPNG)$(E): $(ROBJSd)
$(LD) $(LDFLAGS) -o $@ $(ROBJSd) $(RLIBSd)
$(RPNG2s)$(E): $(ROBJS2s)
$(LD) $(LDFLAGS) -o $@ $(ROBJS2s) $(RLIBSs)
$(RPNG2)$(E): $(ROBJS2d)
$(LD) $(LDFLAGS) -o $@ $(ROBJS2d) $(RLIBSd)
$(WPNGs)$(E): $(WOBJSs)
$(LD) $(LDFLAGS) -o $@ $(WOBJSs) $(WLIBSs)
$(WPNG)$(E): $(WOBJSd)
$(LD) $(LDFLAGS) -o $@ $(WOBJSd) $(WLIBSd)
$(RPNG)$(O): $(RPNG).c readpng.h
$(RPNG2)$(O): $(RPNG2).c readpng2.h
$(WPNG)$(O): $(WPNG).c writepng.h
readpng$(O) readpng.pic$(O): readpng.c readpng.h
readpng2$(O) readpng2.pic$(O): readpng2.c readpng2.h
writepng$(O) writepng.pic$(O): writepng.c writepng.h
# maintenance ---------------------------------------------------------------
clean:
$(RM) $(EXES)
$(RM) $(ROBJSs) $(ROBJS2s) $(WOBJSs)
$(RM) $(ROBJSd) $(ROBJS2d) $(WOBJSd)

View File

@@ -0,0 +1,104 @@
# Sample makefile for rpng-x / rpng2-x / wpng for SGI using cc and make.
# Greg Roelofs
# Last modified: 7 March 2002
#
# The programs built by this makefile are described in the book,
# "PNG: The Definitive Guide," by Greg Roelofs (O'Reilly and
# Associates, 1999). Go buy a copy, eh? Buy some for friends
# and family, too. (Not that this is a blatant plug or anything.)
#
# Invoke this makefile from a shell prompt in the usual way; for example:
#
# make -f Makefile.sgi
#
# This makefile assumes libpng and zlib have already been built or downloaded
# and are both installed in /usr/local/{include,lib} (as indicated by the
# PNG* and Z* macros below). Edit as appropriate--choose only ONE each of
# the PNGINC, PNGLIB, ZINC and ZLIB lines.
#
# This makefile builds dynamically linked executables (against libpng and zlib,
# that is), but that can be changed by uncommenting the appropriate PNGLIB and
# ZLIB lines.
# macros --------------------------------------------------------------------
PNGINC = -I/usr/local/include/libpng14
PNGLIB = -L/usr/local/lib -lpng14 # dynamically linked against libpng
#PNGLIB = /usr/local/lib/libpng14.a # statically linked against libpng
# or:
#PNGINC = -I../..
#PNGLIB = -L../.. -lpng
#PNGLIB = ../../libpng.a
ZINC = -I/usr/local/include
ZLIB = -L/usr/local/lib -lz # dynamically linked against zlib
#ZLIB = /usr/local/lib/libz.a # statically linked against zlib
#ZINC = -I../zlib
#ZLIB = -L../zlib -lz
#ZLIB = ../../../zlib/libz.a
XINC = -I/usr/include/X11 # old-style, stock X distributions
XLIB = -L/usr/lib/X11 -lX11
#XINC = -I/usr/openwin/include # Sun workstations (OpenWindows)
#XLIB = -L/usr/openwin/lib -lX11
#XINC = -I/usr/X11R6/include # new X distributions (XFree86, etc.)
#XLIB = -L/usr/X11R6/lib -lX11
INCS = $(PNGINC) $(ZINC) $(XINC)
RLIBS = $(PNGLIB) $(ZLIB) $(XLIB) -lm
WLIBS = $(PNGLIB) $(ZLIB)
CC = cc
LD = cc
RM = rm -f
# ABI must be the same as that used to build libpng.
ABI=
CFLAGS = $(ABI) -O -fullwarn $(INCS)
LDFLAGS = $(ABI)
O = .o
E =
RPNG = rpng-x
RPNG2 = rpng2-x
WPNG = wpng
ROBJS = $(RPNG)$(O) readpng$(O)
ROBJS2 = $(RPNG2)$(O) readpng2$(O)
WOBJS = $(WPNG)$(O) writepng$(O)
EXES = $(RPNG)$(E) $(RPNG2)$(E) $(WPNG)$(E)
# implicit make rules -------------------------------------------------------
.c$(O):
$(CC) -c $(CFLAGS) $<
# dependencies --------------------------------------------------------------
all: $(EXES)
$(RPNG)$(E): $(ROBJS)
$(LD) $(LDFLAGS) -o $@ $(ROBJS) $(RLIBS)
$(RPNG2)$(E): $(ROBJS2)
$(LD) $(LDFLAGS) -o $@ $(ROBJS2) $(RLIBS)
$(WPNG)$(E): $(WOBJS)
$(LD) $(LDFLAGS) -o $@ $(WOBJS) $(WLIBS)
$(RPNG)$(O): $(RPNG).c readpng.h
$(RPNG2)$(O): $(RPNG2).c readpng2.h
$(WPNG)$(O): $(WPNG).c writepng.h
readpng$(O): readpng.c readpng.h
readpng2$(O): readpng2.c readpng2.h
writepng$(O): writepng.c writepng.h
# maintenance ---------------------------------------------------------------
clean:
$(RM) $(EXES) $(ROBJS) $(ROBJS2) $(WOBJS)

View File

@@ -1,73 +1,92 @@
# Sample makefile for rpng-x / rpng2-x / wpng using gcc and make.
# Greg Roelofs
# Last modified: 28 February 2000
# Last modified: 2 June 2007
#
# The programs built by this makefile are described in the book,
# "PNG: The Definitive Guide," by Greg Roelofs (O'Reilly and
# Associates, 1999). Go buy a copy, eh? Buy some for friends
# and family, too. (Not that this is a blatant plug or anything.)
# Associates, 1999). Go buy a copy, eh? Well, OK, it's not
# generally for sale anymore, but it's the thought that counts,
# right? (Hint: http://www.libpng.org/pub/png/book/ )
#
# Invoke this makefile from a shell prompt in the usual way; for example:
#
# make -f Makefile.unx
#
# This makefile assumes libpng and zlib have already been built or downloaded
# and are both installed in /usr/local/{include,lib} (as indicated by the
# PNG* and Z* macros below). Edit as appropriate--choose only ONE each of
# the PNGINC, PNGLIB, ZINC and ZLIB lines.
# and are installed in /usr/local/{include,lib} or as otherwise indicated by
# the PNG* and Z* macros below. Edit as appropriate--choose only ONE each of
# the PNGINC, PNGLIBd, PNGLIBs, ZINC, ZLIBd and ZLIBs lines.
#
# This makefile builds statically linked executables (against libpng and zlib,
# that is), but that can be changed by uncommenting the appropriate PNGLIB and
# ZLIB lines.
# This makefile builds both dynamically and statically linked executables
# (against libpng and zlib, that is), but that can be changed by modifying
# the "EXES =" line. (You need only one set, but for testing it can be handy
# to have both.)
# macros --------------------------------------------------------------------
PNGINC = -I/usr/local/include
#PNGLIB = -L/usr/local/lib -lpng # dynamically linked against libpng
PNGLIB = /usr/local/lib/libpng.a # statically linked against libpng
#PNGDIR = /usr/local/lib
#PNGINC = -I/usr/local/include/libpng14
#PNGLIBd = -L$(PNGDIR) -lpng14 # dynamically linked, installed libpng
#PNGLIBs = $(PNGDIR)/libpng14.a # statically linked, installed libpng
# or:
#PNGINC = -I../..
#PNGLIB = -L../.. -lpng
#PNGLIB = ../../libpng.a
PNGDIR = ../..# this one is for libpng-x.y.z/contrib/gregbook builds
#PNGDIR = ../libpng
PNGINC = -I$(PNGDIR)
PNGLIBd = -Wl,-rpath,$(PNGDIR) -L$(PNGDIR) -lpng14 # dynamically linked
PNGLIBs = $(PNGDIR)/libpng.a # statically linked, local libpng
ZDIR = /usr/local/lib
#ZDIR = /usr/lib64
ZINC = -I/usr/local/include
#ZLIB = -L/usr/local/lib -lz # dynamically linked against zlib
ZLIB = /usr/local/lib/libz.a # statically linked against zlib
#ZINC = -I../zlib
#ZLIB = -L../zlib -lz
#ZLIB = ../../../zlib/libz.a
ZLIBd = -L$(ZDIR) -lz # dynamically linked against zlib
ZLIBs = $(ZDIR)/libz.a # statically linked against zlib
# or:
#ZDIR = ../zlib
#ZINC = -I$(ZDIR)
#ZLIBd = -Wl,-rpath,$(ZDIR) -L$(ZDIR) -lz # -rpath allows in-place testing
#ZLIBs = $(ZDIR)/libz.a
#XINC = -I/usr/include/X11 # old-style, stock X distributions
#XLIB = -L/usr/lib/X11 -lX11
#XINC = -I/usr/openwin/include # Sun workstations (OpenWindows)
#XINC = -I/usr/include # old-style, stock X distributions
#XLIB = -L/usr/lib/X11 -lX11 # (including SGI IRIX)
#XINC = -I/usr/openwin/include # Sun workstations (OpenWindows)
#XLIB = -L/usr/openwin/lib -lX11
XINC = -I/usr/X11R6/include # new X distributions (XFree86, etc.)
XINC = -I/usr/X11R6/include # new X distributions (X.org, etc.)
XLIB = -L/usr/X11R6/lib -lX11
#XLIB = -L/usr/X11R6/lib64 -lX11 # e.g., Red Hat on AMD64
INCS = $(PNGINC) $(ZINC) $(XINC)
RLIBS = $(PNGLIB) $(ZLIB) $(XLIB) -lm
WLIBS = $(PNGLIB) $(ZLIB)
RLIBSd = $(PNGLIBd) $(ZLIBd) $(XLIB) -lm
RLIBSs = $(PNGLIBs) $(ZLIBs) $(XLIB) -lm
WLIBSd = $(PNGLIBd) $(ZLIBd) -lm
WLIBSs = $(PNGLIBs) $(ZLIBs)
CC = gcc
LD = gcc
RM = rm -f
CFLAGS = -O -Wall $(INCS)
CFLAGS = -O -Wall $(INCS) -DFEATURE_LOOP
# [note that -Wall is a gcc-specific compilation flag ("most warnings on")]
# [-ansi, -pedantic and -W can also be used]
LDFLAGS =
O = .o
E =
RPNG = rpng-x
RPNG2 = rpng2-x
WPNG = wpng
RPNG = rpng-x
RPNG2 = rpng2-x
WPNG = wpng
RPNGs = $(RPNG)-static
RPNG2s = $(RPNG2)-static
WPNGs = $(WPNG)-static
ROBJS = $(RPNG)$(O) readpng$(O)
ROBJS2 = $(RPNG2)$(O) readpng2$(O)
WOBJS = $(WPNG)$(O) writepng$(O)
EXES = $(RPNG)$(E) $(RPNG2)$(E) $(WPNG)$(E)
STATIC_EXES = $(RPNGs)$(E) $(RPNG2s)$(E) $(WPNGs)$(E)
DYNAMIC_EXES = $(RPNG)$(E) $(RPNG2)$(E) $(WPNG)$(E)
EXES = $(STATIC_EXES) $(DYNAMIC_EXES)
# implicit make rules -------------------------------------------------------
@@ -80,14 +99,23 @@ EXES = $(RPNG)$(E) $(RPNG2)$(E) $(WPNG)$(E)
all: $(EXES)
$(RPNGs)$(E): $(ROBJS)
$(LD) $(LDFLAGS) -o $@ $(ROBJS) $(RLIBSs)
$(RPNG)$(E): $(ROBJS)
$(LD) $(LDFLAGS) -o $@ $(ROBJS) $(RLIBS)
$(LD) $(LDFLAGS) -o $@ $(ROBJS) $(RLIBSd)
$(RPNG2s)$(E): $(ROBJS2)
$(LD) $(LDFLAGS) -o $@ $(ROBJS2) $(RLIBSs)
$(RPNG2)$(E): $(ROBJS2)
$(LD) $(LDFLAGS) -o $@ $(ROBJS2) $(RLIBS)
$(LD) $(LDFLAGS) -o $@ $(ROBJS2) $(RLIBSd)
$(WPNGs)$(E): $(WOBJS)
$(LD) $(LDFLAGS) -o $@ $(WOBJS) $(WLIBSs)
$(WPNG)$(E): $(WOBJS)
$(LD) $(LDFLAGS) -o $@ $(WOBJS) $(WLIBS)
$(LD) $(LDFLAGS) -o $@ $(WOBJS) $(WLIBSd)
$(RPNG)$(O): $(RPNG).c readpng.h
$(RPNG2)$(O): $(RPNG2).c readpng2.h

View File

@@ -1,11 +1,12 @@
# Sample makefile for rpng-win / rpng2-win / wpng using MSVC and NMAKE.
# Greg Roelofs
# Last modified: 16 February 1999
# Last modified: 2 June 2007
#
# The programs built by this makefile are described in the book,
# "PNG: The Definitive Guide," by Greg Roelofs (O'Reilly and
# Associates, 1999). Go buy a copy, eh? Buy some for friends
# and family, too. (Not that this is a blatant plug or anything.)
# Associates, 1999). Go buy a copy, eh? Well, OK, it's not
# generally for sale anymore, but it's the thought that counts,
# right? (Hint: http://www.libpng.org/pub/png/book/ )
#
# Invoke this makefile from a DOS prompt window via:
#
@@ -32,12 +33,12 @@
# macros --------------------------------------------------------------------
PNGPATH = ../..
PNGPATH = ../libpng
PNGINC = -I$(PNGPATH)
#PNGLIB = $(PNGPATH)/pngdll.lib
PNGLIB = $(PNGPATH)/libpng.lib
ZPATH = ../../../zlib
ZPATH = ../zlib
ZINC = -I$(ZPATH)
#ZLIB = $(ZPATH)/zlibdll.lib
ZLIB = $(ZPATH)/zlibstat.lib
@@ -53,7 +54,7 @@ CC = cl
LD = link
RM = del
CFLAGS = -nologo -O -W3 $(INCS) $(cvars)
# [note that -Wall is an MSVC-specific compilation flag ("all warnings on")]
# [note that -W3 is an MSVC-specific compilation flag ("all warnings on")]
# [see %devstudio%\vc\include\win32.mak for cvars macro definition]
O = .obj
E = .exe

View File

@@ -16,14 +16,14 @@ of PBMPLUS/NetPBM) and converts them to PNG.
The source code for all three demo programs currently compiles under
Unix, OpenVMS, and 32-bit Windows. (Special thanks to Martin Zinser,
zinser@decus.de, for making the necessary changes for OpenVMS and for
providing an appropriate build script.) Build instructions can be
found below.
providing an appropriate build script.) Build instructions can be found
below.
Files:
README this file
README.w32 additional Windows-specific information
LICENSE terms of distribution and reuse (BSD-like)
LICENSE terms of distribution and reuse (BSD-like or GNU GPL)
COPYING GNU General Public License (GPL)
Makefile.unx Unix makefile
Makefile.w32 Windows (MSVC) makefile
@@ -45,26 +45,27 @@ Files:
toucan.png transparent PNG for testing (by Stefan Schneider)
Note that the programs are designed to be functional, but their primary
purpose is to demonstrate how to use libpng to add PNG support to other
programs. As such, their user interfaces are crude and definitely not
intended for everyday use.
Note that, although the programs are designed to be functional, their
primary purpose is to illustrate how to use libpng to add PNG support to
other programs. As such, their user interfaces are crude and definitely
are not intended for everyday use.
Please see http://www.cdrom.com/pub/png/pngbook.html for further infor-
Please see http://www.libpng.org/pub/png/pngbook.html for further infor-
mation and links to the latest version of the source code, and Chapters
13-15 of the book for detailed discussion of the three programs.
Greg Roelofs
19 March 2000
http://pobox.com/~newt/greg_contact.html
16 March 2008
BUILD INSTRUCTIONS
- Prerequisites:
- Prerequisites (in order of compilation):
- zlib ftp://ftp.cdrom.com/pub/infozip/zlib/zlib.html
- libpng http://www.cdrom.com/pub/png/pngcode.html
- pngbook http://www.cdrom.com/pub/png/book/sources.html
- zlib http://zlib.net/
- libpng http://www.libpng.org/pub/png/libpng.html
- pngbook http://www.libpng.org/pub/png/book/sources.html
The pngbook demo programs are explicitly designed to demonstrate proper
coding techniques for using the libpng reference library. As a result,
@@ -128,11 +129,13 @@ BUILD INSTRUCTIONS
The result should be three executables: rpng-win.exe, rpng2-win.exe,
and wpng.exe. Copy them somewhere in your PATH or run them from the
current folder. Unlike the Unix versions, the two windowed programs
(rpng and rpng2) do not display a usage screen when invoked without
command-line arguments; see README.w32 for brief help or the book for
details. Note that the programs use the Unix-style "-" character to
specify options, instead of the more common DOS/Windows "/" character.
current folder. Like the Unix versions, the two windowed programs
(rpng and rpng2) now display a usage screen in a console window when
invoked without command-line arguments; this is new behavior as of
the June 2001 release. Note that the programs use the Unix-style "-"
character to specify options, instead of the more common DOS/Windows
"/" character. (For example: "rpng2-win -bgpat 4 foo.png", not
"rpng2-win /bgpat 4 foo.png")
- OpenVMS:
@@ -148,9 +151,9 @@ BUILD INSTRUCTIONS
To run the programs, they probably first need to be set up as "foreign
symbols," with "disk" and "dir" set appropriately:
$ rpng == "$disk:[dir]rpng-x.exe"
$ rpng == "$disk:[dir]rpng-x.exe"
$ rpng2 == "$disk:[dir]rpng2-x.exe"
$ wpng == "$disk:[dir]wpng.exe"
$ wpng == "$disk:[dir]wpng.exe"
All three will print a basic usage screen when run without any command-
line arguments; see the book for more details. Note that the options
@@ -162,7 +165,7 @@ RUNNING THE PROGRAMS: (VERY) BRIEF INTRO
rpng is a simple PNG viewer that can display transparent PNGs with a
specified background color; for example,
rpng -bgcolor #ff0000 toucan.png
rpng -bgcolor \#ff0000 toucan.png
would display the image with a red background. rpng2 is a progressive
viewer that simulates a web browser in some respects; it can display
@@ -174,7 +177,7 @@ RUNNING THE PROGRAMS: (VERY) BRIEF INTRO
wpng is a purely command-line image converter from binary PBMPLUS/NetPBM
format (.pgm or .ppm) to PNG; for example,
wpng -time < toucan.ppm > toucan.png
wpng -time < toucan-notrans.ppm > toucan-notrans.png
would convert the specified PPM file (using redirection) to PNG, auto-
matically setting the PNG modification-time chunk.

View File

@@ -1,53 +0,0 @@
See the main README file for basic instructions on compiling and running
the programs. See http://www.cdrom.com/pub/png/pngbook.html for further
information and links to the source code, and Chapters 13-15 of the book
for detailed discussion of the three programs.
Since the two viewers, rpng and rpng2, are both designed to write infor-
mation to the console (i.e., a DOS-window command line) while displaying
the image in a graphical window--and since I haven't yet figured out how
to do that under Windows--here are the usage screens for the two programs:
rpng-win 1.02 of 19 March 2000: Simple PNG Viewer for Windows
Compiled with libpng 1.0.5; using libpng 1.0.5.
Compiled with zlib 1.1.3; using zlib 1.1.3.
Usage: rpng-win [-gamma exp] [-bgcolor bg] file.png
exp transfer-function exponent (``gamma'') of the display
system in floating-point format (e.g., ``2.2''); equal
to the product of the lookup-table exponent (varies)
and the CRT exponent (usually 2.2); must be positive
bg desired background color in 7-character hex RGB format
(e.g., ``#ff7f00'' for orange: same as HTML colors);
used with transparent images
Press Q, Esc or mouse button 1 after image is displayed to quit.
rpng2-win 1.04 of 19 March 2000: Progressive PNG Viewer for Windows
Compiled with libpng 1.0.5; using libpng 1.0.5.
Compiled with zlib 1.1.3; using zlib 1.1.3.
Usage: rpng2-win [-gamma exp] [-bgcolor bg | -bgpat pat] [-timing] file.png
exp transfer-function exponent (``gamma'') of the display
system in floating-point format (e.g., ``2.2''); equal
to the product of the lookup-table exponent (varies)
and the CRT exponent (usually 2.2); must be positive
bg desired background color in 7-character hex RGB format
(e.g., ``#ff7f00'' for orange: same as HTML colors);
used with transparent images; overrides -bgpat
pat desired background pattern number (1-16); used with
transparent images; overrides -bgcolor
-timing enables delay for every block read, to simulate modem
download of image (~36 Kbps)
Press Q, Esc or mouse button 1 after image is displayed to quit.
The usage screen for the third (non-windowed) program, wpng, can be seen
simply by invoking it without any parameters (``wpng'').
Greg Roelofs
19 March 2000

View File

@@ -9,21 +9,22 @@ $! Set locations where zlib and libpng sources live.
$!
$ zpath = ""
$ pngpath = ""
$ if f$search("[-.zlib]zlib.h").nes."" then zpath = "[-.zlib]"
$ if f$search("[-.libpng]png.h").nes."" then pngpath = "[-.libpng]"
$!
$ if f$search("[---.zlib]zlib.h").nes."" then zpath = "[---.zlib]"
$ if f$search("[--]png.h").nes."" then pngpath = "[--]"
$!
$ if f$search("[-.zlib]zlib.h").nes."" then zpath = "[-.zlib]"
$ if f$search("[-.libpng]png.h").nes."" then pngpath = "[-.libpng]"
$!
$ if zpath .eqs. ""
$ then
$ write sys$output "Zlib include not found. Exiting..."
$ write sys$output "zlib include not found. Exiting..."
$ exit 2
$ endif
$!
$ if pngpath .eqs. ""
$ then
$ write sys$output "Libpng include not found. Exiting..."
$ write sys$output "libpng include not found. Exiting..."
$ exit 2
$ endif
$!

View File

@@ -4,13 +4,20 @@
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2007 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -27,6 +34,23 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#include <stdio.h>
@@ -69,7 +93,7 @@ int readpng_init(FILE *infile, ulg *pWidth, ulg *pHeight)
* have used slightly more general png_sig_cmp() function instead */
fread(sig, 1, 8, infile);
if (!png_check_sig(sig, 8))
if (png_sig_cmp(sig, 0, 8))
return 1; /* bad signature */
@@ -239,7 +263,7 @@ uch *readpng_get_image(double display_exponent, int *pChannels, ulg *pRowbytes)
return NULL;
}
Trace((stderr, "readpng_get_image: rowbytes = %ld, height = %ld\n", rowbytes, height));
Trace((stderr, "readpng_get_image: channels = %d, rowbytes = %ld, height = %ld\n", *pChannels, rowbytes, height));
/* set the individual row_pointers to point at the correct offsets */

View File

@@ -4,13 +4,20 @@
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2007 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -27,6 +34,23 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#ifndef TRUE

View File

@@ -4,13 +4,20 @@
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2007 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -27,6 +34,23 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
@@ -49,9 +73,10 @@ static void readpng2_error_handler(png_structp png_ptr, png_const_charp msg);
void readpng2_version_info(void)
{
fprintf(stderr, " Compiled with libpng %s; using libpng %s.\n",
fprintf(stderr, " Compiled with libpng %s; using libpng %s\n",
PNG_LIBPNG_VER_STRING, png_libpng_ver);
fprintf(stderr, " Compiled with zlib %s; using zlib %s.\n",
fprintf(stderr, " and with zlib %s; using zlib %s.\n",
ZLIB_VERSION, zlib_version);
}
@@ -60,7 +85,7 @@ void readpng2_version_info(void)
int readpng2_check_sig(uch *sig, int num)
{
return png_check_sig(sig, num);
return !png_sig_cmp(sig, 0, num);
}
@@ -104,6 +129,38 @@ int readpng2_init(mainprog_info *mainprog_ptr)
}
#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED
/* prepare the reader to ignore all recognized chunks whose data won't be
* used, i.e., all chunks recognized by libpng except for IHDR, PLTE, IDAT,
* IEND, tRNS, bKGD, gAMA, and sRGB (small performance improvement) */
{
/* These byte strings were copied from png.h. If a future libpng
* version recognizes more chunks, add them to this list. If a
* future version of readpng2.c recognizes more chunks, delete them
* from this list. */
static /* const */ png_byte chunks_to_ignore[] = {
99, 72, 82, 77, '\0', /* cHRM */
104, 73, 83, 84, '\0', /* hIST */
105, 67, 67, 80, '\0', /* iCCP */
105, 84, 88, 116, '\0', /* iTXt */
111, 70, 70, 115, '\0', /* oFFs */
112, 67, 65, 76, '\0', /* pCAL */
112, 72, 89, 115, '\0', /* pHYs */
115, 66, 73, 84, '\0', /* sBIT */
115, 67, 65, 76, '\0', /* sCAL */
115, 80, 76, 84, '\0', /* sPLT */
115, 84, 69, 82, '\0', /* sTER */
116, 69, 88, 116, '\0', /* tEXt */
116, 73, 77, 69, '\0', /* tIME */
122, 84, 88, 116, '\0' /* zTXt */
};
png_set_keep_unknown_chunks(png_ptr, 1 /* PNG_HANDLE_CHUNK_NEVER */,
chunks_to_ignore, sizeof(chunks_to_ignore)/5);
}
#endif /* PNG_HANDLE_AS_UNKNOWN_SUPPORTED */
/* instead of doing png_init_io() here, now we set up our callback
* functions for progressive decoding */
@@ -158,6 +215,7 @@ static void readpng2_info_callback(png_structp png_ptr, png_infop info_ptr)
{
mainprog_info *mainprog_ptr;
int color_type, bit_depth;
png_uint_32 width, height;
double gamma;
@@ -193,8 +251,10 @@ static void readpng2_info_callback(png_structp png_ptr, png_infop info_ptr)
/* this is just like in the non-progressive case */
png_get_IHDR(png_ptr, info_ptr, &mainprog_ptr->width,
&mainprog_ptr->height, &bit_depth, &color_type, NULL, NULL, NULL);
png_get_IHDR(png_ptr, info_ptr, &width, &height, &bit_depth, &color_type,
NULL, NULL, NULL);
mainprog_ptr->width = (ulg)width;
mainprog_ptr->height = (ulg)height;
/* since we know we've read all of the PNG file's "header" (i.e., up

View File

@@ -4,13 +4,20 @@
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2008 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -27,6 +34,23 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#ifndef TRUE
@@ -45,6 +69,12 @@
# define Trace(x) ;
#endif
enum rpng2_states {
kPreInit = 0,
kWindowInit,
kDone
};
typedef unsigned char uch;
typedef unsigned short ush;
typedef unsigned long ulg;
@@ -66,7 +96,7 @@ typedef struct _mainprog_info {
int rowbytes;
int channels;
int need_bgcolor;
int done;
int state;
uch bg_red;
uch bg_green;
uch bg_blue;

179
contrib/gregbook/readppm.c Normal file
View File

@@ -0,0 +1,179 @@
/*---------------------------------------------------------------------------
rpng - simple PNG display program readppm.c
---------------------------------------------------------------------------
This is a special-purpose replacement for readpng.c that allows binary
PPM files to be used in place of PNG images.
---------------------------------------------------------------------------
Copyright (c) 1998-2007 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
1. Redistributions of source code must retain the above copyright
notice, disclaimer, and this list of conditions.
2. Redistributions in binary form must reproduce the above copyright
notice, disclaimer, and this list of conditions in the documenta-
tion and/or other materials provided with the distribution.
3. All advertising materials mentioning features or use of this
software must display the following acknowledgment:
This product includes software developed by Greg Roelofs
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#include <stdio.h>
#include <stdlib.h>
#include "readpng.h" /* typedefs, common macros, public prototypes */
ulg width, height;
int bit_depth, color_type, channels;
uch *image_data = NULL;
FILE *saved_infile;
void readpng_version_info()
{
fprintf(stderr, " Compiled without libpng, zlib or PBMPLUS/NetPBM.\n");
}
/* return value = 0 for success, 1 for bad sig, 2 for bad IHDR, 4 for no mem */
int readpng_init(FILE *infile, ulg *pWidth, ulg *pHeight)
{
static uch ppmline[256];
int maxval;
saved_infile = infile;
fgets(ppmline, 256, infile);
if (ppmline[0] != 'P' || ppmline[1] != '6') {
fprintf(stderr, "ERROR: not a PPM file\n");
return 1;
}
/* possible color types: P5 = grayscale (0), P6 = RGB (2), P8 = RGBA (6) */
if (ppmline[1] == '6') {
color_type = 2;
channels = 3;
} else if (ppmline[1] == '8') {
color_type = 6;
channels = 4;
} else /* if (ppmline[1] == '5') */ {
color_type = 0;
channels = 1;
}
do {
fgets(ppmline, 256, infile);
} while (ppmline[0] == '#');
sscanf(ppmline, "%lu %lu", &width, &height);
do {
fgets(ppmline, 256, infile);
} while (ppmline[0] == '#');
sscanf(ppmline, "%d", &maxval);
if (maxval != 255) {
fprintf(stderr, "ERROR: maxval = %d\n", maxval);
return 2;
}
bit_depth = 8;
*pWidth = width;
*pHeight = height;
return 0;
}
/* returns 0 if succeeds, 1 if fails due to no bKGD chunk, 2 if libpng error;
* scales values to 8-bit if necessary */
int readpng_get_bgcolor(uch *red, uch *green, uch *blue)
{
return 1;
}
/* display_exponent == LUT_exponent * CRT_exponent */
uch *readpng_get_image(double display_exponent, int *pChannels, ulg *pRowbytes)
{
ulg rowbytes;
/* expand palette images to RGB, low-bit-depth grayscale images to 8 bits,
* transparency chunks to full alpha channel; strip 16-bit-per-sample
* images to 8 bits per sample; and convert grayscale to RGB[A] */
/* GRR WARNING: grayscale needs to be expanded and channels reset! */
*pRowbytes = rowbytes = channels*width;
*pChannels = channels;
if ((image_data = (uch *)malloc(rowbytes*height)) == NULL) {
return NULL;
}
Trace((stderr, "readpng_get_image: rowbytes = %ld, height = %ld\n", rowbytes, height));
/* now we can go ahead and just read the whole image */
fread(image_data, 1L, rowbytes*height, saved_infile);
return image_data;
}
void readpng_cleanup(int free_image_data)
{
if (free_image_data && image_data) {
free(image_data);
image_data = NULL;
}
}

View File

@@ -9,7 +9,6 @@
with a little tweaking (or maybe not).
to do:
- stdout/stderr don't work! need message window (maybe scrollable?)
- handle quoted command-line args (especially filenames with spaces)
- have minimum window width: oh well
- use %.1023s to simplify truncation of title-bar string?
@@ -22,16 +21,26 @@
match; switched to png_jmpbuf() macro
- 1.02: added extra set of parentheses to png_jmpbuf() macro; fixed
command-line parsing bug
- 1.10: enabled "message window"/console (thanks to David Geldreich)
- 2.00: dual-licensed (added GNU GPL)
- 2.01: fixed improper display of usage screen on PNG error(s)
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2008 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -48,17 +57,61 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#define PROGNAME "rpng-win"
#define LONGNAME "Simple PNG Viewer for Windows"
#define VERSION "1.02 of 19 March 2000"
#define VERSION "2.01 of 16 March 2008"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <windows.h>
#ifdef __CYGWIN__
/* getch replacement. Turns out, we don't really need this,
* but leave it here if we ever enable any of the uses of
* _getch in the main code
*/
#include <unistd.h>
#include <termio.h>
#include <sys/ioctl.h>
int repl_getch( void )
{
char ch;
int fd = fileno(stdin);
struct termio old_tty, new_tty;
ioctl(fd, TCGETA, &old_tty);
new_tty = old_tty;
new_tty.c_lflag &= ~(ICANON | ECHO | ISIG);
ioctl(fd, TCSETA, &new_tty);
fread(&ch, 1, sizeof(ch), stdin);
ioctl(fd, TCSETA, &old_tty);
return ch;
}
#define _getch repl_getch
#else
#include <conio.h> /* only for _getch() */
#endif
/* #define DEBUG : this enables the Trace() macros */
@@ -84,10 +137,9 @@ static void rpng_win_cleanup(void);
LRESULT CALLBACK rpng_win_wndproc(HWND, UINT, WPARAM, LPARAM);
static char titlebar[1024], *window_name = titlebar;
static char titlebar[1024];
static char *progname = PROGNAME;
static char *appname = LONGNAME;
static char *icon_name = PROGNAME; /* GRR: not (yet) used */
static char *filename;
static FILE *infile;
@@ -127,8 +179,19 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
filename = (char *)NULL;
#ifndef __CYGWIN__
/* First reenable console output, which normally goes to the bit bucket
* for windowed apps. Closing the console window will terminate the
* app. Thanks to David.Geldreich@realviz.com for supplying the magical
* incantation. */
/* First set the default value for our display-system exponent, i.e.,
AllocConsole();
freopen("CONOUT$", "a", stderr);
freopen("CONOUT$", "a", stdout);
#endif
/* Next set the default value for our display-system exponent, i.e.,
* the product of the CRT exponent and the exponent corresponding to
* the frame-buffer's lookup table (LUT), if any. This is not an
* exhaustive list of LUT values (e.g., OpenStep has a lot of weird
@@ -236,9 +299,43 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
}
}
if (!filename) {
if (!filename)
++error;
} else if (!(infile = fopen(filename, "rb"))) {
/* print usage screen if any errors up to this point */
if (error) {
#ifndef __CYGWIN__
int ch;
#endif
fprintf(stderr, "\n%s %s: %s\n\n", PROGNAME, VERSION, appname);
readpng_version_info();
fprintf(stderr, "\n"
"Usage: %s [-gamma exp] [-bgcolor bg] file.png\n"
" exp \ttransfer-function exponent (``gamma'') of the display\n"
"\t\t system in floating-point format (e.g., ``%.1f''); equal\n"
"\t\t to the product of the lookup-table exponent (varies)\n"
"\t\t and the CRT exponent (usually 2.2); must be positive\n"
" bg \tdesired background color in 7-character hex RGB format\n"
"\t\t (e.g., ``#ff7700'' for orange: same as HTML colors);\n"
"\t\t used with transparent images\n"
"\nPress Q, Esc or mouse button 1 after image is displayed to quit.\n"
#ifndef __CYGWIN__
"Press Q or Esc to quit this usage screen.\n"
#endif
"\n", PROGNAME, default_display_exponent);
#ifndef __CYGWIN__
do
ch = _getch();
while (ch != 'q' && ch != 'Q' && ch != 0x1B);
#endif
exit(1);
}
if (!(infile = fopen(filename, "rb"))) {
fprintf(stderr, PROGNAME ": can't open PNG file [%s]\n", filename);
++error;
} else {
@@ -251,8 +348,7 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
break;
case 2:
fprintf(stderr, PROGNAME
": [%s] has bad IHDR (libpng longjmp)\n",
filename);
": [%s] has bad IHDR (libpng longjmp)\n", filename);
break;
case 4:
fprintf(stderr, PROGNAME ": insufficient memory\n");
@@ -269,23 +365,25 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
}
/* usage screen */
if (error) {
#ifndef __CYGWIN__
int ch;
#endif
fprintf(stderr, PROGNAME ": aborting.\n");
#ifndef __CYGWIN__
do
ch = _getch();
while (ch != 'q' && ch != 'Q' && ch != 0x1B);
#endif
exit(2);
} else {
fprintf(stderr, "\n%s %s: %s\n", PROGNAME, VERSION, appname);
readpng_version_info();
fprintf(stderr, "\n"
"Usage: %s [-gamma exp] [-bgcolor bg] file.png\n"
" exp \ttransfer-function exponent (``gamma'') of the display\n"
"\t\t system in floating-point format (e.g., ``%.1f''); equal\n"
"\t\t to the product of the lookup-table exponent (varies)\n"
"\t\t and the CRT exponent (usually 2.2); must be positive\n"
" bg \tdesired background color in 7-character hex RGB format\n"
"\t\t (e.g., ``#ff7700'' for orange: same as HTML colors);\n"
"\t\t used with transparent images\n"
"\nPress Q, Esc or mouse button 1 after image is displayed to quit.\n"
"\n", PROGNAME, default_display_exponent);
exit(1);
#ifndef __CYGWIN__
fprintf(stderr,
"\n [console window: closing this window will terminate %s]\n\n",
PROGNAME);
#endif
}
@@ -303,9 +401,14 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
* check for one in the PNG file--if not, the initialized values of 0
* (black) will be used */
if (have_bg)
sscanf(bgstr+1, "%2x%2x%2x", &bg_red, &bg_green, &bg_blue);
else if (readpng_get_bgcolor(&bg_red, &bg_green, &bg_blue) > 1) {
if (have_bg) {
unsigned r, g, b; /* this approach quiets compiler warnings */
sscanf(bgstr+1, "%2x%2x%2x", &r, &g, &b);
bg_red = (uch)r;
bg_green = (uch)g;
bg_blue = (uch)b;
} else if (readpng_get_bgcolor(&bg_red, &bg_green, &bg_blue) > 1) {
readpng_cleanup(TRUE);
fprintf(stderr, PROGNAME
": libpng error while checking for background color\n");
@@ -353,7 +456,12 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
/* wait for the user to tell us when to quit */
printf(
"Done. Press Q, Esc or mouse button 1 (within image window) to quit.\n");
#ifndef __CYGWIN__
"Done. Press Q, Esc or mouse button 1 (within image window) to quit.\n"
#else
"Done. Press mouse button 1 (within image window) to quit.\n"
#endif
);
fflush(stdout);
while (GetMessage(&msg, NULL, 0, 0)) {

View File

@@ -9,7 +9,7 @@
by Martin Zinser under OpenVMS; may work under OS/2 with some tweaking).
to do:
- 8-bit support
- 8-bit (colormapped) X support
- use %.1023s to simplify truncation of title-bar string?
---------------------------------------------------------------------------
@@ -21,16 +21,28 @@
- 1.10: added support for non-default visuals; fixed X pixel-conversion
- 1.11: added extra set of parentheses to png_jmpbuf() macro; fixed
command-line parsing bug
- 1.12: fixed some small X memory leaks (thanks to Fran<61>ois Petitjean)
- 1.13: fixed XFreeGC() crash bug (thanks to Patrick Welche)
- 1.14: added support for X resources (thanks to Gerhard Niklasch)
- 2.00: dual-licensed (added GNU GPL)
- 2.01: fixed improper display of usage screen on PNG error(s)
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2008 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -47,11 +59,30 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#define PROGNAME "rpng-x"
#define LONGNAME "Simple PNG Viewer for X"
#define VERSION "1.11 of 19 March 2000"
#define VERSION "2.01 of 16 March 2008"
#define RESNAME "rpng" /* our X resource application name */
#define RESCLASS "Rpng" /* our X resource class name */
#include <stdio.h>
#include <stdlib.h>
@@ -89,6 +120,8 @@ static int rpng_x_msb(ulg u32val);
static char titlebar[1024], *window_name = titlebar;
static char *appname = LONGNAME;
static char *icon_name = PROGNAME;
static char *res_name = RESNAME;
static char *res_class = RESCLASS;
static char *filename;
static FILE *infile;
@@ -117,6 +150,7 @@ static Colormap colormap;
static int have_nondefault_visual = FALSE;
static int have_colormap = FALSE;
static int have_window = FALSE;
static int have_gc = FALSE;
/*
ulg numcolors=0, pixels[256];
ush reds[256], greens[256], blues[256];
@@ -232,9 +266,33 @@ int main(int argc, char **argv)
}
}
if (!filename) {
if (!filename)
++error;
} else if (!(infile = fopen(filename, "rb"))) {
/* print usage screen if any errors up to this point */
if (error) {
fprintf(stderr, "\n%s %s: %s\n", PROGNAME, VERSION, appname);
readpng_version_info();
fprintf(stderr, "\n"
"Usage: %s [-display xdpy] [-gamma exp] [-bgcolor bg] file.png\n"
" xdpy\tname of the target X display (e.g., ``hostname:0'')\n"
" exp \ttransfer-function exponent (``gamma'') of the display\n"
"\t\t system in floating-point format (e.g., ``%.1f''); equal\n"
"\t\t to the product of the lookup-table exponent (varies)\n"
"\t\t and the CRT exponent (usually 2.2); must be positive\n"
" bg \tdesired background color in 7-character hex RGB format\n"
"\t\t (e.g., ``#ff7700'' for orange: same as HTML colors);\n"
"\t\t used with transparent images\n"
"\nPress Q, Esc or mouse button 1 (within image window, after image\n"
"is displayed) to quit.\n"
"\n", PROGNAME, default_display_exponent);
exit(1);
}
if (!(infile = fopen(filename, "rb"))) {
fprintf(stderr, PROGNAME ": can't open PNG file [%s]\n", filename);
++error;
} else {
@@ -247,8 +305,7 @@ int main(int argc, char **argv)
break;
case 2:
fprintf(stderr, PROGNAME
": [%s] has bad IHDR (libpng longjmp)\n",
filename);
": [%s] has bad IHDR (libpng longjmp)\n", filename);
break;
case 4:
fprintf(stderr, PROGNAME ": insufficient memory\n");
@@ -273,25 +330,9 @@ int main(int argc, char **argv)
}
/* usage screen */
if (error) {
fprintf(stderr, "\n%s %s: %s\n", PROGNAME, VERSION, appname);
readpng_version_info();
fprintf(stderr, "\n"
"Usage: %s [-display xdpy] [-gamma exp] [-bgcolor bg] file.png\n"
" xdpy\tname of the target X display (e.g., ``hostname:0'')\n"
" exp \ttransfer-function exponent (``gamma'') of the display\n"
"\t\t system in floating-point format (e.g., ``%.1f''); equal\n"
"\t\t to the product of the lookup-table exponent (varies)\n"
"\t\t and the CRT exponent (usually 2.2); must be positive\n"
" bg \tdesired background color in 7-character hex RGB format\n"
"\t\t (e.g., ``#ff7700'' for orange: same as HTML colors);\n"
"\t\t used with transparent images\n"
"\nPress Q, Esc or mouse button 1 (within image window, after image\n"
"is displayed) to quit.\n"
"\n", PROGNAME, default_display_exponent);
exit(1);
fprintf(stderr, PROGNAME ": aborting.\n");
exit(2);
}
@@ -396,11 +437,12 @@ static int rpng_x_create_window(void)
XEvent e;
XGCValues gcvalues;
XSetWindowAttributes attr;
XSizeHints *size_hints;
XTextProperty windowName, *pWindowName = &windowName;
XTextProperty iconName, *pIconName = &iconName;
XVisualInfo visual_info;
XSizeHints *size_hints;
XWMHints *wm_hints;
XClassHint *class_hints;
screen = DefaultScreen(display);
@@ -523,7 +565,7 @@ static int rpng_x_create_window(void)
if (!XStringListToTextProperty(&icon_name, 1, pIconName))
pIconName = NULL;
/* OK if either hints allocation fails; XSetWMProperties() allows NULLs */
/* OK if any hints allocation fails; XSetWMProperties() allows NULLs */
if ((size_hints = XAllocSizeHints()) != NULL) {
/* window will not be resizable */
@@ -539,12 +581,30 @@ static int rpng_x_create_window(void)
wm_hints->flags = StateHint | InputHint /* | IconPixmapHint */ ;
}
if ((class_hints = XAllocClassHint()) != NULL) {
class_hints->res_name = res_name;
class_hints->res_class = res_class;
}
XSetWMProperties(display, window, pWindowName, pIconName, NULL, 0,
size_hints, wm_hints, NULL);
size_hints, wm_hints, class_hints);
/* various properties and hints no longer needed; free memory */
if (pWindowName)
XFree(pWindowName->value);
if (pIconName)
XFree(pIconName->value);
if (size_hints)
XFree(size_hints);
if (wm_hints)
XFree(wm_hints);
if (class_hints)
XFree(class_hints);
XMapWindow(display, window);
gc = XCreateGC(display, window, 0, &gcvalues);
have_gc = TRUE;
/*---------------------------------------------------------------------------
Fill window with the specified background color.
@@ -814,7 +874,8 @@ static void rpng_x_cleanup(void)
ximage = NULL;
}
XFreeGC(display, gc);
if (have_gc)
XFreeGC(display, gc);
if (have_window)
XDestroyWindow(display, window);

View File

@@ -10,8 +10,7 @@
tweaking (or maybe not). Thanks to Adam Costello and Pieter S. van der
Meulen for the "diamond" and "radial waves" patterns, respectively.
to do:
- stdout/stderr don't work! need message window (maybe scrollable?)
to do (someday, maybe):
- handle quoted command-line args (especially filenames with spaces)
- finish resizable checkerboard-gradient (sizes 4-128?)
- use %.1023s to simplify truncation of title-bar string?
@@ -25,16 +24,32 @@
- 1.03: modified to allow abbreviated options
- 1.04: removed bogus extra argument from usage fprintf() [Glenn R-P?];
fixed command-line parsing bug
- 1.10: enabled "message window"/console (thanks to David Geldreich)
- 1.20: added runtime MMX-enabling/disabling and new -mmx* options
- 1.21: made minor tweak to usage screen to fit within 25-line console
- 1.22: added AMD64/EM64T support (__x86_64__)
- 2.00: dual-licensed (added GNU GPL)
- 2.01: fixed 64-bit typo in readpng2.c
- 2.02: fixed improper display of usage screen on PNG error(s); fixed
unexpected-EOF and file-read-error cases
- 2.03: removed runtime MMX-enabling/disabling and obsolete -mmx* options
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2008 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -51,11 +66,28 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#define PROGNAME "rpng2-win"
#define LONGNAME "Progressive PNG Viewer for Windows"
#define VERSION "1.04 of 19 March 2000"
#define VERSION "2.02 of 16 March 2008"
#include <stdio.h>
#include <stdlib.h>
@@ -64,6 +96,33 @@
#include <time.h>
#include <math.h> /* only for PvdM background code */
#include <windows.h>
#ifdef __CYGWIN__
/* getch replacement. Turns out, we don't really need this,
* but leave it here if we ever enable any of the uses of
* _getch in the main code
*/
#include <unistd.h>
#include <termio.h>
#include <sys/ioctl.h>
int repl_getch( void )
{
char ch;
int fd = fileno(stdin);
struct termio old_tty, new_tty;
ioctl(fd, TCGETA, &old_tty);
new_tty = old_tty;
new_tty.c_lflag &= ~(ICANON | ECHO | ISIG);
ioctl(fd, TCSETA, &new_tty);
fread(&ch, 1, sizeof(ch), stdin);
ioctl(fd, TCSETA, &old_tty);
return ch;
}
#define _getch repl_getch
#else
#include <conio.h> /* only for _getch() */
#endif
/* all for PvdM background code: */
#ifndef PI
@@ -116,10 +175,9 @@ static void rpng2_win_cleanup(void);
LRESULT CALLBACK rpng2_win_wndproc(HWND, UINT, WPARAM, LPARAM);
static char titlebar[1024], *window_name = titlebar;
static char titlebar[1024];
static char *progname = PROGNAME;
static char *appname = LONGNAME;
static char *icon_name = PROGNAME; /* GRR: not (yet) used */
static char *filename;
static FILE *infile;
@@ -238,6 +296,16 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
filename = (char *)NULL;
memset(&rpng2_info, 0, sizeof(mainprog_info));
#ifndef __CYGWIN__
/* Next reenable console output, which normally goes to the bit bucket
* for windowed apps. Closing the console window will terminate the
* app. Thanks to David.Geldreich@realviz.com for supplying the magical
* incantation. */
AllocConsole();
freopen("CONOUT$", "a", stderr);
freopen("CONOUT$", "a", stdout);
#endif
/* Set the default value for our display-system exponent, i.e., the
* product of the CRT exponent and the exponent corresponding to
@@ -364,9 +432,56 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
}
}
if (!filename) {
if (!filename)
++error;
} else if (!(infile = fopen(filename, "rb"))) {
/* print usage screen if any errors up to this point */
if (error) {
#ifndef __CYGWIN__
int ch;
#endif
fprintf(stderr, "\n%s %s: %s\n\n", PROGNAME, VERSION, appname);
readpng2_version_info();
fprintf(stderr, "\n"
"Usage: %s [-gamma exp] [-bgcolor bg | -bgpat pat] [-timing]\n"
" %*s file.png\n\n"
" exp \ttransfer-function exponent (``gamma'') of the display\n"
"\t\t system in floating-point format (e.g., ``%.1f''); equal\n"
"\t\t to the product of the lookup-table exponent (varies)\n"
"\t\t and the CRT exponent (usually 2.2); must be positive\n"
" bg \tdesired background color in 7-character hex RGB format\n"
"\t\t (e.g., ``#ff7700'' for orange: same as HTML colors);\n"
"\t\t used with transparent images; overrides -bgpat option\n"
" pat \tdesired background pattern number (1-%d); used with\n"
"\t\t transparent images; overrides -bgcolor option\n"
" -timing\tenables delay for every block read, to simulate modem\n"
"\t\t download of image (~36 Kbps)\n"
"\nPress Q, Esc or mouse button 1 after image is displayed to quit.\n"
#ifndef __CYGWIN__
"Press Q or Esc to quit this usage screen. ",
#else
,
#endif
PROGNAME,
#if (defined(__i386__) || defined(_M_IX86) || defined(__x86_64__)) && \
!(defined(__CYGWIN__) || defined(__MINGW32__))
(int)strlen(PROGNAME), " ",
#endif
(int)strlen(PROGNAME), " ", default_display_exponent, num_bgpat);
fflush(stderr);
#ifndef __CYGWIN__
do
ch = _getch();
while (ch != 'q' && ch != 'Q' && ch != 0x1B);
#endif
exit(1);
}
if (!(infile = fopen(filename, "rb"))) {
fprintf(stderr, PROGNAME ": can't open PNG file [%s]\n", filename);
++error;
} else {
@@ -380,8 +495,7 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
switch (rc) {
case 2:
fprintf(stderr, PROGNAME
": [%s] has bad IHDR (libpng longjmp)\n",
filename);
": [%s] has bad IHDR (libpng longjmp)\n", filename);
break;
case 4:
fprintf(stderr, PROGNAME ": insufficient memory\n");
@@ -398,28 +512,26 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
}
/* usage screen */
if (error) {
#ifndef __CYGWIN__
int ch;
#endif
fprintf(stderr, PROGNAME ": aborting.\n");
#ifndef __CYGWIN__
do
ch = _getch();
while (ch != 'q' && ch != 'Q' && ch != 0x1B);
#endif
exit(2);
} else {
fprintf(stderr, "\n%s %s: %s\n", PROGNAME, VERSION, appname);
readpng2_version_info();
fprintf(stderr, "\n"
"Usage: %s [-gamma exp] [-bgcolor bg | -bgpat pat] [-timing]"
" file.png\n\n"
" exp \ttransfer-function exponent (``gamma'') of the display\n"
"\t\t system in floating-point format (e.g., ``%.1f''); equal\n"
"\t\t to the product of the lookup-table exponent (varies)\n"
"\t\t and the CRT exponent (usually 2.2); must be positive\n"
" bg \tdesired background color in 7-character hex RGB format\n"
"\t\t (e.g., ``#ff7700'' for orange: same as HTML colors);\n"
"\t\t used with transparent images; overrides -bgpat\n"
" pat \tdesired background pattern number (1-%d); used with\n"
"\t\t transparent images; overrides -bgcolor\n"
" -timing\tenables delay for every block read, to simulate modem\n"
"\t\t download of image (~36 Kbps)\n"
"\nPress Q, Esc or mouse button 1 after image is displayed to quit.\n"
"\n", PROGNAME, default_display_exponent, num_bgpat);
exit(1);
#ifndef __CYGWIN__
fprintf(stderr,
"\n [console window: closing this window will terminate %s]\n\n",
PROGNAME);
#endif
fflush(stderr);
}
@@ -445,7 +557,7 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
} else
rpng2_info.need_bgcolor = TRUE;
rpng2_info.done = FALSE;
rpng2_info.state = kPreInit;
rpng2_info.mainprog_init = rpng2_win_init;
rpng2_info.mainprog_display_row = rpng2_win_display_row;
rpng2_info.mainprog_finish_display = rpng2_win_finish_display;
@@ -465,10 +577,27 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, PSTR cmd, int showmode)
if (readpng2_decode_data(&rpng2_info, inbuf, incount))
++error;
Trace((stderr, "done with readpng2_decode_data()\n"))
if (error || feof(infile) || rpng2_info.done)
if (error || incount != INBUFSIZE || rpng2_info.state == kDone) {
if (rpng2_info.state == kDone) {
Trace((stderr, "done decoding PNG image\n"))
} else if (ferror(infile)) {
fprintf(stderr, PROGNAME
": error while reading PNG image file\n");
exit(3);
} else if (feof(infile)) {
fprintf(stderr, PROGNAME ": end of file reached "
"(unexpectedly) while reading PNG image file\n");
exit(3);
} else /* if (error) */ {
// will print error message below
}
break;
}
if (timing)
Sleep(1000L);
incount = fread(inbuf, 1, INBUFSIZE, infile);
}
@@ -515,7 +644,7 @@ static void rpng2_win_init()
ulg rowbytes = rpng2_info.rowbytes;
Trace((stderr, "beginning rpng2_win_init()\n"))
Trace((stderr, " rowbytes = %ld\n", rpng2_info.rowbytes))
Trace((stderr, " rowbytes = %d\n", rpng2_info.rowbytes))
Trace((stderr, " width = %ld\n", rpng2_info.width))
Trace((stderr, " height = %ld\n", rpng2_info.height))
@@ -545,6 +674,8 @@ static void rpng2_win_init()
readpng2_cleanup(&rpng2_info);
return;
}
rpng2_info.state = kWindowInit;
}
@@ -1040,9 +1171,14 @@ static void rpng2_win_finish_display()
* we have nothing to do here except set a flag and let the user know
* that the image is done */
rpng2_info.done = TRUE;
rpng2_info.state = kDone;
printf(
"Done. Press Q, Esc or mouse button 1 (within image window) to quit.\n");
#ifndef __CYGWIN__
"Done. Press Q, Esc or mouse button 1 (within image window) to quit.\n"
#else
"Done. Press mouse button 1 (within image window) to quit.\n"
#endif
);
fflush(stdout);
}

File diff suppressed because it is too large Load Diff

View File

@@ -5,8 +5,10 @@
This program converts certain NetPBM binary files (grayscale and RGB,
maxval = 255) to PNG. Non-interlaced PNGs are written progressively;
interlaced PNGs are read and written in one memory-intensive blast.
Thanks to Jean-loup Gailly for providing the necessary trick to read
interactive text from the keyboard while stdin is redirected.
interactive text from the keyboard while stdin is redirected. Thanks
to Cosmin Truta for Cygwin fixes.
NOTE: includes provisional support for PNM type "8" (portable alphamap)
images, presumed to be a 32-bit interleaved RGBA format; no pro-
@@ -24,16 +26,32 @@
- 1.02: modified to allow abbreviated options
- 1.03: removed extraneous character from usage screen; fixed bug in
command-line parsing
- 1.04: fixed DOS/OS2/Win32 detection, including partial Cygwin fix
(see http://home.att.net/~perlspinr/diffs/GregBook_cygwin.diff)
- 2.00: dual-licensed (added GNU GPL)
[REPORTED BUG (win32 only): "contrib/gregbook/wpng.c - cmd line
dose not work! In order to do something useful I needed to redirect
both input and output, with cygwin and with bcc32 as well. Under
Linux, the same wpng appears to work fine. I don't know what is
the problem."]
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2007 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -50,16 +68,35 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#define PROGNAME "wpng"
#define VERSION "1.03 of 19 March 2000"
#define VERSION "2.00 of 2 June 2007"
#define APPNAME "Simple PGM/PPM/PAM to PNG Converter"
#if defined(__MSDOS__) || defined(__OS2__)
# define DOS_OS2_W32
#elif defined(_WIN32) || defined(__WIN32__)
# define DOS_OS2_W32
#elif defined(WIN32) || defined(_WIN32) || defined(__WIN32__)
# ifndef __GNUC__ /* treat Win32 native ports of gcc as Unix environments */
# define DOS_OS2_W32
# endif
#endif
#include <stdio.h>

View File

@@ -4,13 +4,20 @@
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2007 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -27,6 +34,23 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/

View File

@@ -4,13 +4,20 @@
---------------------------------------------------------------------------
Copyright (c) 1998-2000 Greg Roelofs. All rights reserved.
Copyright (c) 1998-2007 Greg Roelofs. All rights reserved.
This software is provided "as is," without warranty of any kind,
express or implied. In no event shall the author or contributors
be held liable for any damages arising in any way from the use of
this software.
The contents of this file are DUAL-LICENSED. You may modify and/or
redistribute this software according to the terms of one of the
following two licenses (at your option):
LICENSE 1 ("BSD-like with advertising clause"):
Permission is granted to anyone to use this software for any purpose,
including commercial applications, and to alter it and redistribute
it freely, subject to the following restrictions:
@@ -27,6 +34,23 @@
and contributors for the book, "PNG: The Definitive Guide,"
published by O'Reilly and Associates.
LICENSE 2 (GNU GPL v2 or later):
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
---------------------------------------------------------------------------*/
#ifndef TRUE

View File

@@ -1,22 +0,0 @@
Microsoft Developer Studio Build File, Format Version 6.00 for
msvctest
Assumes that libpng DLLs and LIBs are in ..\..\dll\msvc\win32\libpng
Assumes that zlib DLLs and LIBs are in ..\..\dll\msvc\win32\zlib
To build:
1) On the main menu Select "Build|Set Active configuration".
Choose the configuration that corresponds to the library you want to test.
This library must have been built using the libpng MS project located in
the "mscv" subdirectory.
2) Select "Build|Clean"
3) Select "Build|Rebuild All"
4) The test results should appear in the "Build" pane of the Output Window.
Simon-Pierre Cadieux
Methodex Computer Systems Inc.

View File

@@ -1,247 +0,0 @@
# Microsoft Developer Studio Project File - Name="msvctest" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Console Application" 0x0103
CFG=msvctest - Win32 Debug DLL
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
!MESSAGE use the Export Makefile command and run
!MESSAGE
!MESSAGE NMAKE /f "msvctest.mak".
!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE NMAKE /f "msvctest.mak" CFG="msvctest - Win32 Debug DLL"
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE "msvctest - Win32 DLL" (based on "Win32 (x86) Console Application")
!MESSAGE "msvctest - Win32 Debug DLL" (based on "Win32 (x86) Console Application")
!MESSAGE "msvctest - Win32 ASM DLL" (based on "Win32 (x86) Console Application")
!MESSAGE "msvctest - Win32 Debug ASM DLL" (based on "Win32 (x86) Console Application")
!MESSAGE "msvctest - Win32 LIB" (based on "Win32 (x86) Console Application")
!MESSAGE "msvctest - Win32 Debug LIB" (based on "Win32 (x86) Console Application")
!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
# PROP Scc_ProjName ""
# PROP Scc_LocalPath ""
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "msvctest - Win32 DLL"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "dll"
# PROP BASE Intermediate_Dir "dll"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "dll"
# PROP Intermediate_Dir "dll"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /O1 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /FD /c
# ADD CPP /nologo /MD /W3 /O1 /I "..\..\..\zlib" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "PNG_DLL" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /subsystem:console /machine:I386
# ADD LINK32 ..\..\dll\msvc\win32\libpng\dll\libpng1.lib /nologo /subsystem:console /machine:I386
# Begin Special Build Tool
OutDir=.\dll
SOURCE="$(InputPath)"
PostBuild_Desc=[Run Test]
PostBuild_Cmds=set path=..\..\dll\msvc\win32\libpng\dll;..\..\dll\msvc\win32\zlib\dll; $(outdir)\msvctest.exe ..\..\pngtest.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "msvctest - Win32 Debug DLL"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "dll_dbg"
# PROP BASE Intermediate_Dir "dll_dbg"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "dll_dbg"
# PROP Intermediate_Dir "dll_dbg"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Zi /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MDd /W3 /Zi /Od /I "..\..\..\zlib" /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "PNG_DLL" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /GZ /c
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 ..\..\dll\msvc\win32\libpng\dll_dbg\libpng1d.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# Begin Special Build Tool
OutDir=.\dll_dbg
SOURCE="$(InputPath)"
PostBuild_Desc=[Run Test]
PostBuild_Cmds=set path=..\..\dll\msvc\win32\libpng\dll_dbg;..\..\dll\msvc\win32\zlib\dll_dbg; $(outdir)\msvctest.exe ..\..\pngtest.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "msvctest - Win32 ASM DLL"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "dll_asm"
# PROP BASE Intermediate_Dir "dll_asm"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "dll_asm"
# PROP Intermediate_Dir "dll_asm"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /O1 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /FD /c
# ADD CPP /nologo /MD /W3 /O1 /I "..\..\..\zlib" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "PNG_DLL" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /subsystem:console /machine:I386
# ADD LINK32 ..\..\dll\msvc\win32\libpng\dll_asm\libpng1a.lib /nologo /subsystem:console /machine:I386
# Begin Special Build Tool
OutDir=.\dll_asm
SOURCE="$(InputPath)"
PostBuild_Desc=[Run Test]
PostBuild_Cmds=set path=..\..\dll\msvc\win32\libpng\dll_asm;..\..\dll\msvc\win32\zlib\dll_asm; $(outdir)\msvctest.exe ..\..\pngtest.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "msvctest - Win32 Debug ASM DLL"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "dll_dbga"
# PROP BASE Intermediate_Dir "dll_dbga"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "dll_dbga"
# PROP Intermediate_Dir "dll_dbga"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Zi /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MDd /W3 /Zi /Od /I "..\..\..\zlib" /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "PNG_DLL" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /GZ /c
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 ..\..\dll\msvc\win32\libpng\dll_dbga\libpng1b.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# Begin Special Build Tool
OutDir=.\dll_dbga
SOURCE="$(InputPath)"
PostBuild_Desc=[Run Test]
PostBuild_Cmds=set path=..\..\dll\msvc\win32\libpng\dll_dbga;..\..\dll\msvc\win32\zlib\dll_dbga; $(outdir)\msvctest.exe ..\..\pngtest.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "msvctest - Win32 LIB"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "lib"
# PROP BASE Intermediate_Dir "lib"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "lib"
# PROP Intermediate_Dir "lib"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /O1 /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /FD /c
# ADD CPP /nologo /W3 /O1 /I "..\..\..\zlib" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /subsystem:console /machine:I386
# ADD LINK32 ..\..\dll\msvc\win32\libpng\lib\libpng.lib /nologo /subsystem:console /machine:I386
# Begin Special Build Tool
OutDir=.\lib
SOURCE="$(InputPath)"
PostBuild_Desc=[Run Test]
PostBuild_Cmds=$(outdir)\msvctest.exe ..\..\pngtest.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "msvctest - Win32 Debug LIB"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "lib_dbg"
# PROP BASE Intermediate_Dir "lib_dbg"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "lib_dbg"
# PROP Intermediate_Dir "lib_dbg"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Zi /Od /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /W3 /Zi /Od /I "..\..\..\zlib" /D "_DEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FD /GZ /c
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 ..\..\dll\msvc\win32\libpng\lib_dbg\libpng.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# Begin Special Build Tool
OutDir=.\lib_dbg
SOURCE="$(InputPath)"
PostBuild_Desc=[Run Test]
PostBuild_Cmds=$(outdir)\msvctest.exe ..\..\pngtest.png
# End Special Build Tool
!ENDIF
# Begin Target
# Name "msvctest - Win32 DLL"
# Name "msvctest - Win32 Debug DLL"
# Name "msvctest - Win32 ASM DLL"
# Name "msvctest - Win32 Debug ASM DLL"
# Name "msvctest - Win32 LIB"
# Name "msvctest - Win32 Debug LIB"
# Begin Group "Source Files"
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
# Begin Source File
SOURCE=..\..\pngtest.c
# End Source File
# Begin Source File
SOURCE=.\README.txt
# PROP Exclude_From_Build 1
# End Source File
# End Group
# Begin Group "Header Files"
# PROP Default_Filter "h;hpp;hxx;hm;inl"
# End Group
# Begin Group "Resource Files"
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
# End Group
# End Target
# End Project

View File

@@ -1,29 +0,0 @@
Microsoft Developer Studio Workspace File, Format Version 6.00
# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
###############################################################################
Project: "msvctest"=.\msvctest.dsp - Package Owner=<4>
Package=<5>
{{{
}}}
Package=<4>
{{{
}}}
###############################################################################
Global:
Package=<5>
{{{
}}}
Package=<3>
{{{
}}}
###############################################################################

View File

@@ -0,0 +1,9 @@
This demonstrates the use of PNG_USER_CONFIG and pngusr.h
To build a minimal read-only decoder with embedded libpng and zlib, run
gather.sh # to collect needed files from pngminus, libpng, and zlib
make
If you prefer to use the shared libraries, go to contrib/pngminus
and build the png2pnm application there.

View File

@@ -0,0 +1,10 @@
#!/bin/sh
cp ../../pngminus/png2pnm.c pngm2pnm.c
cp ../../../*.h .
cp ../../../*.c .
rm example.c pngtest.c pngpread.c pngw*.c
# change the following 2 lines if zlib is somewhere else
cp ../../../../zlib/*.h .
cp ../../../../zlib/*.c .
rm minigzip.c example.c compress.c deflate.c gz*

View File

@@ -0,0 +1,43 @@
# Makefile for PngMinus (pngm2pnm)
# Linux / Unix
#CC=cc
CC=gcc
LD=$(CC)
RM=rm -f
CFLAGS=-DPNG_USER_CONFIG -DNO_GZCOMPRESS -DNO_GZIP \
-DdeflateParams\(a,b,c\)=Z_OK -I. -O1
C=.c
O=.o
L=.a
E=
ZOBJS = adler32$(O) crc32$(O) \
infback$(O) inffast$(O) inflate$(O) inftrees$(O) \
trees$(O) uncompr$(O) zutil$(O)
OBJS = pngm2pnm$(O) png$(O) pngerror$(O) pngget$(O) pngmem$(O) \
pngread$(O) pngrio$(O) pngrtran$(O) pngrutil$(O) \
pngset$(O) pngtrans$(O) $(ZOBJS)
# implicit make rules -------------------------------------------------------
.c$(O): png.h pngconf.h pngpriv.h pngusr.h zlib.h
$(CC) -c $(CFLAGS) $<
# dependencies
all: pngm2pnm$(E)
pngm2pnm$(E): $(OBJS)
$(LD) -o pngm2pnm$(E) $(OBJS)
clean:
$(RM) pngm2pnm$(O)
$(RM) pngm2pnm$(E)
$(RM) $(OBJS)
# End of makefile for pngm2pnm

View File

@@ -0,0 +1,75 @@
/* minrdpngconf.h: headers to make a minimal png-read-only library
*
* Copyright (c) 2007, 2009 Glenn Randers-Pehrson
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
* and license in png.h
*
* Derived from pngcrush.h, Copyright 1998-2007, Glenn Randers-Pehrson
*/
#ifndef MINRDPNGCONF_H
#define MINRDPNGCONF_H
#define PNG_NO_WARNINGS
#define png_warning(s1,s2) ""
#define png_chunk_warning(s1,s2) ""
#define PNG_NO_ERROR_TEXT
#define png_error(s1,s2) png_err(s1)
#define png_chunk_error(s1,s2) png_err(s1)
#define PNG_NO_READ_BGR
#define PNG_NO_READ_GAMMA
#define PNG_NO_READ_BACKGROUND
#define PNG_NO_READ_QUANTIZE
#define PNG_NO_READ_INVERT
#define PNG_NO_READ_SHIFT
#define PNG_NO_READ_PACK
#define PNG_NO_READ_PACKSWAP
#define PNG_NO_READ_FILLER
#define PNG_NO_READ_SWAP
#define PNG_NO_READ_SWAP_ALPHA
#define PNG_NO_READ_INVERT_ALPHA
#define PNG_NO_READ_RGB_TO_GRAY
#define PNG_NO_READ_USER_TRANSFORM
#define PNG_NO_READ_bKGD
#define PNG_NO_READ_cHRM
#define PNG_NO_READ_gAMA
#define PNG_NO_READ_hIST
#define PNG_NO_READ_iCCP
#define PNG_NO_READ_oFFs
#define PNG_NO_READ_pCAL
#define PNG_NO_READ_pHYs
#define PNG_NO_READ_sBIT
#define PNG_NO_READ_sCAL
#define PNG_NO_READ_sPLT
#define PNG_NO_READ_sRGB
#define PNG_NO_READ_TEXT
#define PNG_NO_READ_tIME
#define PNG_NO_READ_UNKNOWN_CHUNKS
#define PNG_NO_READ_USER_CHUNKS
#define PNG_NO_READ_EMPTY_PLTE
#define PNG_NO_READ_OPT_PLTE
#define PNG_NO_READ_STRIP_ALPHA
#define PNG_NO_WRITE_SUPPORTED
#define PNG_NO_INFO_IMAGE
#define PNG_NO_IO_STATE
#define PNG_NO_USER_MEM
#define PNG_NO_FIXED_POINT_SUPPORTED
#define PNG_NO_MNG_FEATURES
#define PNG_NO_USER_TRANSFORM_PTR
#define PNG_NO_HANDLE_AS_UNKNOWN
#define PNG_NO_CONSOLE_IO
#define PNG_NO_ZALLOC_ZERO
#define PNG_NO_ERROR_NUMBERS
#define PNG_NO_EASY_ACCESS
#define PNG_NO_PROGRESSIVE_READ
#define PNG_NO_USER_LIMITS
#define PNG_NO_SET_USER_LIMITS
#define PNG_NO_TIME_RFC1123
#endif /* MINRDPNGCONF_H */

View File

@@ -0,0 +1,9 @@
This demonstrates the use of PNG_USER_CONFIG and pngusr.h
To build a minimal write-only decoder with embedded libpng and zlib, run
gather.sh # to collect needed files from pngminus, libpng, and zlib
make
If you prefer to use the shared libraries, go to contrib/pngminus
and build the pnm2png application there.

View File

@@ -0,0 +1,11 @@
#!/bin/sh
cp ../../pngminus/pnm2png.c pnm2pngm.c
cp ../../../*.h .
cp ../../../*.c .
rm example.c pngtest.c pngr*.c pngpread.c
# Change the next 2 lines if zlib is somewhere else.
cp ../../../../zlib/*.h .
cp ../../../../zlib/*.c .
rm inf*.[ch]
rm uncompr.c minigzip.c example.c gz*

View File

@@ -0,0 +1,41 @@
# Makefile for PngMinus (pnm2pngm)
# Linux / Unix
#CC=cc
CC=gcc
LD=$(CC)
RM=rm -f
CFLAGS=-DPNG_USER_CONFIG -DNO_GZIP -I. -O1
C=.c
O=.o
L=.a
E=
ZOBJS = adler32$(O) compress$(O) crc32$(O) deflate$(O) \
trees$(O) zutil$(O)
OBJS = pnm2pngm$(O) png$(O) pngerror$(O) pngget$(O) pngmem$(O) \
pngset$(O) pngtrans$(O) pngwio$(O) pngwrite$(O) \
pngwtran$(O) pngwutil$(O) $(ZOBJS)
# implicit make rules -------------------------------------------------------
.c$(O): png.h pngconf.h pngpriv.h pngusr.h zlib.h
$(CC) -c $(CFLAGS) $<
# dependencies
all: pnm2pngm$(E)
pnm2pngm$(E): $(OBJS)
$(LD) -o pnm2pngm$(E) $(OBJS)
clean:
$(RM) pnm2pngm$(O)
$(RM) pnm2pngm$(E)
$(RM) $(OBJS)
# End of makefile for pnm2pngm

View File

@@ -0,0 +1,75 @@
/* minwrpngconf.h: headers to make a minimal png-write-only library
*
* Copyright (c) 2007, 2009 Glenn Randers-Pehrson
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
* and license in png.h
*
* Derived from pngcrush.h, Copyright 1998-2007, Glenn Randers-Pehrson
*/
#ifndef MINWRPNGCONF_H
#define MINWRPNGCONF_H
#define PNG_NO_READ_SUPPORTED
#define PNG_NO_WARNINGS
#define png_warning(s1,s2) ""
#define png_chunk_warning(s1,s2) ""
#define PNG_NO_ERROR_TEXT
#define png_error(s1,s2) png_err(s1)
#define png_chunk_error(s1,s2) png_err(s1)
#define PNG_NO_WRITE_BACKGROUND
#define PNG_NO_WRITE_BGR
#define PNG_NO_WRITE_QUANTIZE
#define PNG_NO_WRITE_INVERT
#define PNG_NO_WRITE_SHIFT
#define PNG_NO_WRITE_PACK
#define PNG_NO_WRITE_PACKSWAP
#define PNG_NO_WRITE_FILLER
#define PNG_NO_WRITE_SWAP
#define PNG_NO_WRITE_SWAP_ALPHA
#define PNG_NO_WRITE_INVERT_ALPHA
#define PNG_NO_WRITE_RGB_TO_GRAY
#define PNG_NO_WRITE_USER_TRANSFORM
#define PNG_NO_WRITE_bKGD
#define PNG_NO_WRITE_cHRM
#define PNG_NO_WRITE_gAMA
#define PNG_NO_WRITE_hIST
#define PNG_NO_WRITE_iCCP
#define PNG_NO_WRITE_oFFs
#define PNG_NO_WRITE_pCAL
#define PNG_NO_WRITE_pHYs
#define PNG_NO_WRITE_sBIT
#define PNG_NO_WRITE_sCAL
#define PNG_NO_WRITE_sPLT
#define PNG_NO_WRITE_sRGB
#define PNG_NO_WRITE_TEXT
#define PNG_NO_WRITE_tIME
#define PNG_NO_WRITE_UNKNOWN_CHUNKS
#define PNG_NO_WRITE_USER_CHUNKS
#define PNG_NO_WRITE_EMPTY_PLTE
#define PNG_NO_WRITE_OPT_PLTE
#define PNG_NO_WRITE_FILTER
#define PNG_NO_WRITE_WEIGHTED_FILTER
#define PNG_NO_WRITE_INTERLACING_SUPPORTED
#define PNG_NO_WRITE_FLUSH
#define PNG_NO_INFO_IMAGE
#define PNG_NO_IO_STATE
#define PNG_NO_USER_MEM
#define PNG_NO_FIXED_POINT_SUPPORTED
#define PNG_NO_MNG_FEATURES
#define PNG_NO_USER_TRANSFORM_PTR
#define PNG_NO_HANDLE_AS_UNKNOWN
#define PNG_NO_CONSOLE_IO
#define PNG_NO_ZALLOC_ZERO
#define PNG_NO_ERROR_NUMBERS
#define PNG_NO_EASY_ACCESS
#define PNG_NO_USER_LIMITS
#define PNG_NO_SET_USER_LIMITS
#define PNG_NO_TIME_RFC1123
#endif /* MINWRPNGCONF_H */

View File

@@ -0,0 +1,14 @@
This demonstrates the use of PNG_USER_CONFIG and pngusr.h
To build a minimal read-only progressive decoder embedded libpng and
zlib and with your system's X library, run
gather.sh # to collect needed files from gregbook, libpng, and zlib
Edit makefile if required, to find your X library and include files,
then
make
If you prefer to use the shared libraries, go to contrib/gregbook
and build the rpng2-x application there.

View File

@@ -0,0 +1,11 @@
#!/bin/sh
cp ../../gregbook/rpng2-x.c ../../gregbook/readpng2.[ch] .
cp ../../gregbook/COPYING ../../gregbook/LICENSE .
cp ../../../*.h .
cp ../../../*.c .
rm example.c pngtest.c pngw*.c
# change the following 2 lines if zlib is somewhere else
cp ../../../../zlib/*.h .
cp ../../../../zlib/*.c .
rm minigzip.c example.c compress.c deflate.c gz*

View File

@@ -0,0 +1,59 @@
# Makefile for PngMinus (rpng2)
# Linux / Unix
#CC=cc
CC=gcc
LD=$(CC)
RM=rm -f
#XINC = -I/usr/include # old-style, stock X distributions
#XLIB = -L/usr/lib/X11 -lX11 # (including SGI IRIX)
#XINC = -I/usr/openwin/include # Sun workstations (OpenWindows)
#XLIB = -L/usr/openwin/lib -lX11
XINC = -I/usr/X11R6/include # new X distributions (X.org, etc.)
XLIB = -L/usr/X11R6/lib -lX11
#XLIB = -L/usr/X11R6/lib64 -lX11 # e.g., Red Hat on AMD64
#XINC = -I/usr/local/include # FreeBSD
#XLIB = -L/usr/local/lib -lX11
#LIBS = $(XLIB)
LIBS = $(XLIB) -lm #platforms that need libm
CFLAGS=-DPNG_USER_CONFIG -DNO_GZCOMPRESS -DNO_GZIP \
-DdeflateParams\(a,b,c\)=Z_OK -I. $(XINC) -O1
C=.c
O=.o
L=.a
E=
ZOBJS = adler32$(O) crc32$(O) \
infback$(O) inffast$(O) inflate$(O) inftrees$(O) \
trees$(O) uncompr$(O) zutil$(O)
OBJS = rpng2-x$(O) readpng2$(O) png$(O) pngerror$(O) pngget$(O) pngmem$(O) \
pngpread$(O) pngread$(O) pngrio$(O) pngrtran$(O) pngrutil$(O) \
pngset$(O) pngtrans$(O) $(ZOBJS)
# implicit make rules -------------------------------------------------------
.c$(O): png.h pngconf.h pngpriv.h readpng2.h pngusr.h zlib.h
$(CC) -c $(CFLAGS) $<
# dependencies
all: rpng2-x$(E)
rpng2-x$(E): $(OBJS)
$(LD) -o rpng2-x$(E) $(OBJS) $(LIBS)
clean:
$(RM) rpng2-x$(O)
$(RM) rpng2-x$(E)
$(RM) $(OBJS)
# End of makefile for rpng2-x

View File

@@ -0,0 +1,68 @@
/* minrdpngconf.h: headers to make a minimal png-read-only library
*
* Copyright (c) 2009 Glenn Randers-Pehrson
*
* This code is released under the libpng license.
* For conditions of distribution and use, see the disclaimer
* and license in png.h
*
* Derived from pngcrush.h, Copyright 1998-2007, Glenn Randers-Pehrson
*/
#ifndef MINPRDPNGCONF_H
#define MINPRDPNGCONF_H
#define PNG_NO_WARNINGS
#define png_warning(s1,s2) ""
#define png_chunk_warning(s1,s2) ""
#define PNG_NO_ERROR_TEXT
#define png_error(s1,s2) png_err(s1)
#define png_chunk_error(s1,s2) png_err(s1)
#define PNG_NO_READ_BGR
#define PNG_NO_READ_DITHER
#define PNG_NO_READ_INVERT
#define PNG_NO_READ_SHIFT
#define PNG_NO_READ_PACK
#define PNG_NO_READ_PACKSWAP
#define PNG_NO_READ_FILLER
#define PNG_NO_READ_SWAP
#define PNG_NO_READ_SWAP_ALPHA
#define PNG_NO_READ_INVERT_ALPHA
#define PNG_NO_READ_RGB_TO_GRAY
#define PNG_NO_READ_USER_TRANSFORM
#define PNG_NO_READ_cHRM
#define PNG_NO_READ_hIST
#define PNG_NO_READ_iCCP
#define PNG_NO_READ_oFFs
#define PNG_NO_READ_pCAL
#define PNG_NO_READ_pHYs
#define PNG_NO_READ_sBIT
#define PNG_NO_READ_sCAL
#define PNG_NO_READ_sPLT
#define PNG_NO_READ_TEXT
#define PNG_NO_READ_tIME
#define PNG_NO_READ_UNKNOWN_CHUNKS
#define PNG_NO_READ_USER_CHUNKS
#define PNG_NO_READ_EMPTY_PLTE
#define PNG_NO_READ_OPT_PLTE
#define PNG_NO_READ_STRIP_ALPHA
#define PNG_NO_WRITE_SUPPORTED
#define PNG_NO_INFO_IMAGE
#define PNG_NO_IO_STATE
#define PNG_NO_USER_MEM
#define PNG_NO_FIXED_POINT_SUPPORTED
#define PNG_NO_MNG_FEATURES
#define PNG_NO_USER_TRANSFORM_PTR
#define PNG_NO_HANDLE_AS_UNKNOWN
#define PNG_NO_CONSOLE_IO
#define PNG_NO_ZALLOC_ZERO
#define PNG_NO_ERROR_NUMBERS
#define PNG_NO_EASY_ACCESS
#define PNG_NO_USER_LIMITS
#define PNG_NO_SET_USER_LIMITS
#define PNG_NO_TIME_RFC1123
#endif /* MINPRDPNGCONF_H */

View File

@@ -20,7 +20,7 @@ Soon after the creation of PNG in 1995, the need was felt for a set of
pnmtopng / pngtopnm utilities. Independantly Alexander Lehmann and I
(Willem van Schaik) started such a project. Luckily we discovered this
and merged the two together into pnmtopng.tar.gz, which is available
from a/o ftp://swrinde.nde.swri.edu/pub/png/.
from a/o ftp://ftp.simplesystems.org/pub/libpng/png/.
These two utilities have many, many options and make use of most of the
features of PNG, like gamma, alpha, sbit, text-chunks, etc. This makes

View File

@@ -1,26 +1,31 @@
# Makefile for PngMinus (png2pnm and pnm2png)
# Linux / Unix
CC=cc -O
LD=cc -O
#CC=gcc -O
#LD=gcc -O
LB=ar
RM=rm
CP=cp
#CC=cc
CC=gcc
LD=$(CC)
PNGPATH = /usr/local
PNGINC = $(PNGPATH)/include
#PNGLIB = $(PNGPATH)/lib -lpng
PNGLIB = $(PNGPATH)/lib/libpng.a
RM=rm -f
ZPATH = /usr/local
ZINC = $(ZPATH)/include
#ZLIB = $(ZPATH)/lib -lz
ZLIB = $(ZPATH)/lib/libz.a
#PNGPATH = /usr/local
#PNGINC = -I$(PNGPATH)/include/libpng12
#PNGLIB = -L$(PNGPATH)/lib -lpng12
#PNGLIBS = $(PNGPATH)/lib/libpng12.a
PNGINC = -I../..
PNGLIB = -L../.. -lpng
PNGLIBS = ../../libpng.a
CCFLAGS=-I$(PNGINC) -I$(ZINC)
LDFLAGS=-L$(PNGLIB) -L$(ZLIB)
#ZPATH = /usr/local
#ZINC = -I$(ZPATH)/include
#ZLIB = -L$(ZPATH)/lib -lz
#ZLIBS = $(ZPATH)/lib/libz.a
ZINC = -I../../../zlib
ZLIB = -L../../../zlib -lz
ZLIBS = ../../../zlib/libz.a
CFLAGS=-O3 $(PNGINC) $(ZINC)
LDFLAGS=$(PNGLIB) $(ZLIB)
LDFLAGSS=$(PNGLIBS) $(ZLIBS)
C=.c
O=.o
L=.a
@@ -28,25 +33,33 @@ E=
# dependencies
all: png2pnm$(E) pnm2png$(E)
#all: png2pnm$(E) pnm2png$(E)
all: png2pnm$(E) pnm2png$(E) png2pnm-static$(E) pnm2png-static$(E)
png2pnm$(O): png2pnm$(C)
$(CC) -c $(CCFLAGS) png2pnm$(C)
$(CC) -c $(CFLAGS) png2pnm$(C)
png2pnm$(E): png2pnm$(O)
$(LD) -o png2pnm$(E) png2pnm$(O) $(LDFLAGS) -lpng -lz -lm
$(LD) -o png2pnm$(E) png2pnm$(O) $(LDFLAGS) -lm
png2pnm-static$(E): png2pnm$(O)
$(LD) -o png2pnm-static$(E) png2pnm$(O) $(LDFLAGSS) -lm
pnm2png$(O): pnm2png$(C)
$(CC) -c $(CCFLAGS) pnm2png$(C)
$(CC) -c $(CFLAGS) pnm2png$(C)
pnm2png$(E): pnm2png$(O)
$(LD) -o pnm2png$(E) pnm2png$(O) $(LDFLAGS) -lpng -lz -lm
$(LD) -o pnm2png$(E) pnm2png$(O) $(LDFLAGS) -lm
pnm2png-static$(E): pnm2png$(O)
$(LD) -o pnm2png-static$(E) pnm2png$(O) $(LDFLAGSS) -lm
clean:
$(RM) png2pnm$(O)
$(RM) pnm2png$(O)
$(RM) png2pnm$(E)
$(RM) pnm2png$(E)
$(RM) png2pnm-static$(E)
$(RM) pnm2png-static$(E)
# End of makefile for png2pnm / pnm2png

View File

@@ -211,8 +211,8 @@ BOOL png2pnm (FILE *png_file, FILE *pnm_file, FILE *alpha_file, BOOL raw, BOOL a
if (ret != 8)
return FALSE;
ret = png_check_sig (buf, 8);
if (!ret)
ret = png_sig_cmp (buf, 0, 8);
if (ret)
return FALSE;
/* create png and info structures */

1
contrib/pngminus/png2pnm.sh Executable file → Normal file
View File

@@ -1,3 +1,4 @@
#!/bin/sh
# -- grayscale
./png2pnm -noraw ../pngsuite/basn0g01.png basn0g01.pgm
./png2pnm -noraw ../pngsuite/basn0g02.png basn0g02.pgm

1
contrib/pngminus/pngminus.sh Executable file → Normal file
View File

@@ -1,3 +1,4 @@
#!/bin/sh
make -f makefile.std
sh png2pnm.sh
sh pnm2png.sh

1
contrib/pngminus/pnm2png.sh Executable file → Normal file
View File

@@ -1,3 +1,4 @@
#!/bin/sh
# -- grayscale
./pnm2png basn0g01.pgm basn0g01.png
./pnm2png basn0g02.pgm basn0g02.png

View File

@@ -1,41 +1,58 @@
pngsuite
--------
(c) Willem van Schaik, 1999
(c) Willem van Schaik, 1999, 2011
Permission to use, copy, and distribute these images for any purpose and
without fee is hereby granted.
Permission to use, copy, modify, and distribute these images for any
purpose and without fee is hereby granted.
These 15 images are part of the much larger PngSuite test-set of
The 15 "bas*.png" images are part of the much larger PngSuite test-set of
images, available for developers of PNG supporting software. The
complete set, available at http:/www.schaik.com/pngsuite/, contains
a variety of images to test interlacing, gamma settings, ancillary
chunks, etc.
The "ft*.png" images are "free/libre" replacements for the transparent
corresponding t*.png images in the PngSuite.
The images in this directory represent the basic PNG color-types:
grayscale (1-16 bit deep), full color (8 or 16 bit), paletted
(1-8 bit) and grayscale or color images with alpha channel. You
can use them to test the proper functioning of PNG software.
filename depth type
filename depth type
------------ ------ --------------
basn0g01.png 1-bit grayscale
basn0g02.png 2-bit grayscale
basn0g04.png 4-bit grayscale
basn0g08.png 8-bit grayscale
basn0g16.png 16-bit grayscale
basn2c08.png 8-bit truecolor
basn2c16.png 16-bit truecolor
basn3p01.png 1-bit paletted
basn3p02.png 2-bit paletted
basn3p04.png 4-bit paletted
basn3p08.png 8-bit paletted
basn4a08.png 8-bit gray with alpha
basn4a16.png 16-bit gray with alpha
basn6a08.png 8-bit RGBA
basn6a16.png 16-bit RGBA
basn0g01.png 1-bit grayscale
basn0g02.png 2-bit grayscale
basn0g04.png 4-bit grayscale
basn0g08.png 8-bit grayscale
basn0g16.png 16-bit grayscale
basn2c08.png 8-bit truecolor
basn2c16.png 16-bit truecolor
basn3p01.png 1-bit paletted
basn3p02.png 2-bit paletted
basn3p04.png 4-bit paletted
basn3p08.png 8-bit paletted
basn4a08.png 8-bit gray with alpha
basn4a16.png 16-bit gray with alpha
basn6a08.png 8-bit RGBA
basn6a16.png 16-bit RGBA
Here is the correct result of typing "pngtest -m *.png" in
ftbbn0g04.png 4-bit grayscale, black bKGD
ftbbn2c16.png 16-bit truecolor, black bKGD
ftbbn3p08.png 8-bit paletted, black bKGD
ftbgn2c16.png 16-bit truecolor, gray bKGD
ftbgn3p08.png 8-bit paletted, gray bKGD
ftbrn2c08.png 8-bit truecolor, red bKGD
ftbwn0g16.png 16-bit gray, white bKGD
ftbwn3p08.png 8-bit paletted, white bKGD
ftbyn3p08.png 8-bit paletted, yellow bKGD
ftp0n0g08.png 8-bit grayscale, opaque
ftp0n2c08.png 8-bit truecolor, opaque
ftp0n3p08.png 8-bit paletted, opaque
ftp1n3p08.png 8-bit paletted, no bKGD
Here is the correct result of typing "pngtest -m bas*.png" in
this directory:
Testing basn0g01.png: PASS (524 zero samples)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 164 B

After

Width:  |  Height:  |  Size: 164 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 104 B

After

Width:  |  Height:  |  Size: 104 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 145 B

After

Width:  |  Height:  |  Size: 145 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 138 B

After

Width:  |  Height:  |  Size: 138 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 167 B

After

Width:  |  Height:  |  Size: 167 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 145 B

After

Width:  |  Height:  |  Size: 145 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 302 B

After

Width:  |  Height:  |  Size: 302 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 112 B

After

Width:  |  Height:  |  Size: 112 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 146 B

After

Width:  |  Height:  |  Size: 146 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 216 B

After

Width:  |  Height:  |  Size: 216 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 126 B

After

Width:  |  Height:  |  Size: 126 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 184 B

After

Width:  |  Height:  |  Size: 184 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 429 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 719 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@@ -2,8 +2,11 @@
// PNGFILE.C -- Image File Functions
//-------------------------------------
// Copyright 2000, Willem van Schaik. For conditions of distribution and
// use, see the copyright/license/disclaimer notice in png.h
// Copyright 2000, Willem van Schaik.
//
// This code is released under the libpng license.
// For conditions of distribution and use, see the disclaimer
// and license in png.h
#include <windows.h>
#include <commdlg.h>
@@ -32,7 +35,7 @@ png_cexcept_error(png_structp png_ptr, png_const_charp msg)
{
if(png_ptr)
;
#ifndef PNG_NO_CONSOLE_IO
#ifdef PNG_CONSOLE_IO_SUPPORTED
fprintf(stderr, "libpng error: %s\n", msg);
#endif
{
@@ -123,7 +126,7 @@ BOOL PngLoadImage (PTSTR pstrFileName, png_byte **ppbImageData,
// first check the eight byte PNG signature
fread(pbSig, 1, 8, pfFile);
if (!png_check_sig(pbSig, 8))
if (png_sig_cmp(pbSig, 0, 8))
{
*ppbImageData = pbImageData = NULL;
return FALSE;
@@ -152,7 +155,7 @@ BOOL PngLoadImage (PTSTR pstrFileName, png_byte **ppbImageData,
// initialize the png structure
#if !defined(PNG_NO_STDIO)
#ifdef PNG_STDIO_SUPPORTED
png_init_io(png_ptr, pfFile);
#else
png_set_read_fn(png_ptr, (png_voidp)pfFile, png_read_data);
@@ -321,7 +324,7 @@ BOOL PngSaveImage (PTSTR pstrFileName, png_byte *pDiData,
{
// initialize the png structure
#if !defined(PNG_NO_STDIO)
#ifdef PNG_STDIO_SUPPORTED
png_init_io(png_ptr, pfFile);
#else
png_set_write_fn(png_ptr, (png_voidp)pfFile, png_write_data, png_flush);
@@ -392,7 +395,7 @@ BOOL PngSaveImage (PTSTR pstrFileName, png_byte *pDiData,
return TRUE;
}
#ifdef PNG_NO_STDIO
#ifndef PNG_STDIO_SUPPORTED
static void
png_read_data(png_structp png_ptr, png_bytep data, png_size_t length)

View File

@@ -2,8 +2,11 @@
// PNGFILE.H -- Header File for pngfile.c
//------------------------------------------
// Copyright 2000, Willem van Schaik. For conditions of distribution and
// use, see the copyright/license/disclaimer notice in png.h
// Copyright 2000, Willem van Schaik.
// This code is released under the libpng license.
// For conditions of distribution and use, see the disclaimer
// and license in png.h
#include <stdio.h>
#include <stdlib.h>
@@ -19,7 +22,7 @@ BOOL PngLoadImage (PTSTR pstrFileName, png_byte **ppbImageData,
BOOL PngSaveImage (PTSTR pstrFileName, png_byte *pDiData,
int iWidth, int iHeight, png_color BkgColor);
#if defined(PNG_NO_STDIO)
#ifndef PNG_STDIO_SUPPORTED
static void png_read_data(png_structp png_ptr, png_bytep data, png_size_t length);
static void png_write_data(png_structp png_ptr, png_bytep data, png_size_t length);
static void png_flush(png_structp png_ptr);

View File

@@ -1,8 +1,11 @@
Microsoft Developer Studio Build File, Format Version 6.00 for VisualPng
------------------------------------------------------------------------
Copyright 2000, Willem van Schaik. For conditions of distribution and
use, see the copyright/license/disclaimer notice in png.h
Copyright 2000, Willem van Schaik.
This code is released under the libpng license.
For conditions of distribution and use, see the disclaimer
and license in png.h
As a PNG .dll demo VisualPng is finished. More features would only hinder
the program's objective. However, further extensions (like support for other
@@ -13,8 +16,8 @@ binaries, go to "http://www.schaik.com/png/visualpng.html".
Assumes that
libpng DLLs and LIBs are in ..\..\dll\msvc\win32\libpng
zlib DLLs and LIBs are in ..\..\dll\msvc\win32\zlib
libpng DLLs and LIBs are in ..\..\projects\msvc\win32\libpng
zlib DLLs and LIBs are in ..\..\projects\msvc\win32\zlib
libpng header files are in ..\..\..\libpng
zlib header files are in ..\..\..\zlib
the pngsuite images are in ..\pngsuite

View File

@@ -2,8 +2,11 @@
// VisualPng.C -- Shows a PNG image
//------------------------------------
// Copyright 2000, Willem van Schaik. For conditions of distribution and
// use, see the copyright/license/disclaimer notice in png.h
// Copyright 2000, Willem van Schaik.
// This code is released under the libpng license.
// For conditions of distribution and use, see the disclaimer
// and license in png.h
// switches

View File

@@ -1,223 +1,147 @@
# Microsoft Developer Studio Project File - Name="VisualPng" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# Copyright 2000, Willem van Schaik. For conditions of distribution and
# use, see the copyright/license/disclaimer notice in png.h
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Application" 0x0101
CFG=VisualPng - Win32 Debug LIB
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
!MESSAGE use the Export Makefile command and run
!MESSAGE
!MESSAGE NMAKE /f "VisualPng.mak".
!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE NMAKE /f "VisualPng.mak" CFG="VisualPng - Win32 Debug LIB"
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE "VisualPng - Win32 DLL" (based on "Win32 (x86) Application")
!MESSAGE "VisualPng - Win32 Debug DLL" (based on "Win32 (x86) Application")
!MESSAGE "VisualPng - Win32 LIB" (based on "Win32 (x86) Application")
!MESSAGE "VisualPng - Win32 Debug LIB" (based on "Win32 (x86) Application")
!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
# PROP Scc_ProjName ""
# PROP Scc_LocalPath ""
CPP=cl.exe
MTL=midl.exe
RSC=rc.exe
!IF "$(CFG)" == "VisualPng - Win32 DLL"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "VisualPng___Win32_DLL"
# PROP BASE Intermediate_Dir "VisualPng___Win32_DLL"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "dll"
# PROP Intermediate_Dir "dll"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /I "libpng" /I "zlib" /D "PNG_USE_DLL" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /W3 /GX /O2 /I "..\..\..\libpng" /I "..\..\..\zlib" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "PNG_USE_DLL" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /c
# SUBTRACT CPP /YX
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 libpng1.lib zlibd.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 /libpath:"libpng" /libpath:"zlib"
# ADD LINK32 libpng1.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 /libpath:"..\..\dll\msvc\win32\libpng\dll"
# Begin Special Build Tool
OutDir=.\dll
SOURCE="$(InputPath)"
PostBuild_Cmds=set path=..\..\dll\msvc\win32\libpng\dll;..\..\dll\msvc\win32\zlib\dll; $(outdir)\VisualPng.exe ..\..\contrib\pngsuite\basn6a16.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "VisualPng - Win32 Debug DLL"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "VisualPng___Win32_Debug_DLL"
# PROP BASE Intermediate_Dir "VisualPng___Win32_Debug_DLL"
# PROP BASE Ignore_Export_Lib 0
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "dll_dbg"
# PROP Intermediate_Dir "dll_dbg"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /I "libpng" /I "zlib" /D "PNG_USE_DLL" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "..\..\..\libpng" /I "..\..\..\zlib" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "PNG_USE_DLL" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /GZ /c
# SUBTRACT CPP /YX
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 libpng1.lib zlibd.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /nodefaultlib:"libc" /pdbtype:sept /libpath:"libpng" /libpath:"zlib"
# SUBTRACT BASE LINK32 /nodefaultlib
# ADD LINK32 libpng1d.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /nodefaultlib:"libc" /pdbtype:sept /libpath:"..\..\dll\msvc\win32\libpng\dll_dbg"
# SUBTRACT LINK32 /nodefaultlib
# Begin Special Build Tool
OutDir=.\dll_dbg
SOURCE="$(InputPath)"
PostBuild_Cmds=set path=..\..\dll\msvc\win32\libpng\dll_dbg;..\..\dll\msvc\win32\zlib\dll_dbg; $(outdir)\VisualPng.exe ..\..\contrib\pngsuite\basn6a16.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "VisualPng - Win32 LIB"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "VisualPng___Win32_LIB"
# PROP BASE Intermediate_Dir "VisualPng___Win32_LIB"
# PROP BASE Ignore_Export_Lib 0
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "lib"
# PROP Intermediate_Dir "lib"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /I "..\..\..\libpng" /I "..\..\..\zlib" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "PNG_USE_DLL" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /c
# SUBTRACT BASE CPP /YX
# ADD CPP /nologo /W3 /GX /O2 /I "..\..\..\libpng" /I "..\..\..\zlib" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /c
# SUBTRACT CPP /YX
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 libpng1.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 /libpath:"..\..\dll\msvc\win32\libpng\dll"
# ADD LINK32 libpng.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 /libpath:"..\..\dll\msvc\win32\libpng\lib"
# Begin Special Build Tool
OutDir=.\lib
SOURCE="$(InputPath)"
PostBuild_Cmds=$(outdir)\VisualPng.exe ..\..\contrib\pngsuite\basn6a16.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "VisualPng - Win32 Debug LIB"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "VisualPng___Win32_Debug_LIB"
# PROP BASE Intermediate_Dir "VisualPng___Win32_Debug_LIB"
# PROP BASE Ignore_Export_Lib 0
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "lib_dbg"
# PROP Intermediate_Dir "lib_dbg"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /I "..\..\..\libpng" /I "..\..\..\zlib" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "PNG_USE_DLL" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /YX /FD /GZ /c
# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "..\..\..\libpng" /I "..\..\..\zlib" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "PNG_NO_STDIO" /D "PNG_NO_GLOBAL_ARRAYS" /FD /GZ /c
# SUBTRACT CPP /YX
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 libpng1d.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /nodefaultlib:"libc" /pdbtype:sept /libpath:"..\..\dll\msvc\win32\libpng\dll_dbg"
# SUBTRACT BASE LINK32 /nodefaultlib
# ADD LINK32 libpng.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /nodefaultlib:"libc" /pdbtype:sept /libpath:"..\..\dll\msvc\win32\libpng\lib_dbg"
# SUBTRACT LINK32 /nodefaultlib
# Begin Special Build Tool
OutDir=.\lib_dbg
SOURCE="$(InputPath)"
PostBuild_Cmds=$(outdir)\VisualPng.exe ..\..\contrib\pngsuite\basn6a16.png
# End Special Build Tool
!ENDIF
# Begin Target
# Name "VisualPng - Win32 DLL"
# Name "VisualPng - Win32 Debug DLL"
# Name "VisualPng - Win32 LIB"
# Name "VisualPng - Win32 Debug LIB"
# Begin Group "Source Files"
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
# Begin Source File
SOURCE=.\PngFile.c
# End Source File
# Begin Source File
SOURCE=.\VisualPng.c
# End Source File
# End Group
# Begin Group "Header Files"
# PROP Default_Filter "h;hpp;hxx;hm;inl"
# Begin Source File
SOURCE=.\cexcept.h
# End Source File
# Begin Source File
SOURCE=.\PngFile.h
# End Source File
# Begin Source File
SOURCE=.\resource.h
# End Source File
# End Group
# Begin Group "Resource Files"
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
# Begin Source File
SOURCE=.\VisualPng.ico
# End Source File
# Begin Source File
SOURCE=.\VisualPng.rc
# End Source File
# End Group
# End Target
# End Project
# Microsoft Developer Studio Project File - Name="VisualPng" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Application" 0x0101
CFG=VisualPng - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
!MESSAGE use the Export Makefile command and run
!MESSAGE
!MESSAGE NMAKE /f "VisualPng.mak".
!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE NMAKE /f "VisualPng.mak" CFG="VisualPng - Win32 Debug"
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE "VisualPng - Win32 Release" (based on "Win32 (x86) Application")
!MESSAGE "VisualPng - Win32 Debug" (based on "Win32 (x86) Application")
!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
# PROP Scc_ProjName ""
# PROP Scc_LocalPath ""
CPP=cl.exe
MTL=midl.exe
RSC=rc.exe
!IF "$(CFG)" == "VisualPng - Win32 Release"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "Release"
# PROP BASE Intermediate_Dir "Release"
# PROP BASE Ignore_Export_Lib 0
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
# PROP Intermediate_Dir "Release"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /O2 /I "..\.." /I "..\..\..\zlib" /D "WIN32" /D "NDEBUG" /D "PNG_NO_STDIO" /FD /c
# SUBTRACT BASE CPP /YX
# ADD CPP /nologo /MD /W3 /O2 /I "..\.." /I "..\..\..\zlib" /D "WIN32" /D "NDEBUG" /D "PNG_NO_STDIO" /FD /c
# SUBTRACT CPP /YX
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
# ADD LINK32 ..\..\projects\visualc6\Win32_LIB_Release\libpng.lib ..\..\..\zlib\projects\visualc6\Win32_LIB_Release\zlib.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
# Begin Special Build Tool
OutDir=.\Release
SOURCE="$(InputPath)"
PostBuild_Cmds=$(outdir)\VisualPng.exe ..\..\contrib\pngsuite\basn6a16.png
# End Special Build Tool
!ELSEIF "$(CFG)" == "VisualPng - Win32 Debug"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "Debug"
# PROP BASE Intermediate_Dir "Debug"
# PROP BASE Ignore_Export_Lib 0
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "Debug"
# PROP Intermediate_Dir "Debug"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /ZI /Od /I "..\.." /I "..\..\..\zlib" /D "WIN32" /D "_DEBUG" /D "PNG_NO_STDIO" /FD /GZ /c
# SUBTRACT BASE CPP /YX
# ADD CPP /nologo /MDd /W3 /Gm /ZI /Od /I "..\.." /I "..\..\..\zlib" /D "WIN32" /D "_DEBUG" /D "PNG_NO_STDIO" /FD /GZ /c
# SUBTRACT CPP /YX
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept
# ADD LINK32 ..\..\projects\visualc6\Win32_LIB_Release\libpng.lib ..\..\..\zlib\projects\visualc6\Win32_LIB_Release\zlib.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /nodefaultlib:"msvcrt.lib" /pdbtype:sept
# Begin Special Build Tool
OutDir=.\Debug
SOURCE="$(InputPath)"
PostBuild_Cmds=$(outdir)\VisualPng.exe ..\..\contrib\pngsuite\basn6a16.png
# End Special Build Tool
!ENDIF
# Begin Target
# Name "VisualPng - Win32 Release"
# Name "VisualPng - Win32 Debug"
# Begin Group "Source Files"
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
# Begin Source File
SOURCE=.\PngFile.c
# End Source File
# Begin Source File
SOURCE=.\VisualPng.c
# End Source File
# End Group
# Begin Group "Header Files"
# PROP Default_Filter "h;hpp;hxx;hm;inl"
# Begin Source File
SOURCE=.\cexcept.h
# End Source File
# Begin Source File
SOURCE=.\PngFile.h
# End Source File
# Begin Source File
SOURCE=.\resource.h
# End Source File
# End Group
# Begin Group "Resource Files"
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
# Begin Source File
SOURCE=.\VisualPng.ico
# End Source File
# Begin Source File
SOURCE=.\VisualPng.rc
# End Source File
# End Group
# End Target
# End Project

View File

@@ -1,29 +1,29 @@
Microsoft Developer Studio Workspace File, Format Version 6.00
# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
###############################################################################
Project: "VisualPng"=.\VisualPng.dsp - Package Owner=<4>
Package=<5>
{{{
}}}
Package=<4>
{{{
}}}
###############################################################################
Global:
Package=<5>
{{{
}}}
Package=<3>
{{{
}}}
###############################################################################
Microsoft Developer Studio Workspace File, Format Version 6.00
# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
###############################################################################
Project: "VisualPng"=.\VisualPng.dsp - Package Owner=<4>
Package=<5>
{{{
}}}
Package=<4>
{{{
}}}
###############################################################################
Global:
Package=<5>
{{{
}}}
Package=<3>
{{{
}}}
###############################################################################

View File

@@ -1,152 +1,152 @@
//Microsoft Developer Studio generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE DISCARDABLE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE DISCARDABLE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE DISCARDABLE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Menu
//
VISUALPNG MENU DISCARDABLE
BEGIN
POPUP "&File"
BEGIN
MENUITEM "&Open Image...\tCtrl+O", IDM_FILE_OPEN
MENUITEM "Save &As...", IDM_FILE_SAVE
MENUITEM SEPARATOR
MENUITEM "&Next Image\tCtrl+N", IDM_FILE_NEXT
MENUITEM "Pre&vious Image\tCtrl+V", IDM_FILE_PREVIOUS
MENUITEM SEPARATOR
MENUITEM "E&xit\tAlt+X", IDM_FILE_EXIT
END
POPUP "&Options"
BEGIN
MENUITEM "&Stretch", IDM_OPTIONS_STRETCH, CHECKED
END
POPUP "&Help"
BEGIN
MENUITEM "&About", IDM_HELP_ABOUT
END
END
/////////////////////////////////////////////////////////////////////////////
//
// Accelerator
//
VISUALPNG ACCELERATORS DISCARDABLE
BEGIN
"N", IDM_FILE_NEXT, VIRTKEY, CONTROL, NOINVERT
"O", IDM_FILE_OPEN, VIRTKEY, CONTROL, NOINVERT
"P", IDM_FILE_PREVIOUS, VIRTKEY, CONTROL, NOINVERT
"V", IDM_FILE_PREVIOUS, VIRTKEY, CONTROL, NOINVERT
"X", IDM_FILE_EXIT, VIRTKEY, ALT, NOINVERT
END
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
VISUALPNG ICON DISCARDABLE "VisualPng.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
ABOUTBOX DIALOG DISCARDABLE 0, 0, 186, 94
STYLE DS_MODALFRAME | WS_POPUP
FONT 8, "MS Sans Serif"
BEGIN
DEFPUSHBUTTON "OK",IDOK,68,67,50,14
CTEXT "VisualPng 1.0 - June 2000",IDC_STATIC,49,14,88,8
LTEXT "a PNG image viewer",IDC_STATIC,60,30,66,8
LTEXT "(c) Willem van Schaik, 2000",IDC_STATIC,48,52,90,8
LTEXT "to demonstrate the use of libpng in Visual C",
IDC_STATIC,25,38,136,8
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO DISCARDABLE
BEGIN
"ABOUTBOX", DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 179
TOPMARGIN, 7
BOTTOMMARGIN, 87
END
END
#endif // APSTUDIO_INVOKED
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED
//Microsoft Developer Studio generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE DISCARDABLE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE DISCARDABLE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE DISCARDABLE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Menu
//
VISUALPNG MENU DISCARDABLE
BEGIN
POPUP "&File"
BEGIN
MENUITEM "&Open Image...\tCtrl+O", IDM_FILE_OPEN
MENUITEM "Save &As...", IDM_FILE_SAVE
MENUITEM SEPARATOR
MENUITEM "&Next Image\tCtrl+N", IDM_FILE_NEXT
MENUITEM "Pre&vious Image\tCtrl+V", IDM_FILE_PREVIOUS
MENUITEM SEPARATOR
MENUITEM "E&xit\tAlt+X", IDM_FILE_EXIT
END
POPUP "&Options"
BEGIN
MENUITEM "&Stretch", IDM_OPTIONS_STRETCH, CHECKED
END
POPUP "&Help"
BEGIN
MENUITEM "&About", IDM_HELP_ABOUT
END
END
/////////////////////////////////////////////////////////////////////////////
//
// Accelerator
//
VISUALPNG ACCELERATORS DISCARDABLE
BEGIN
"N", IDM_FILE_NEXT, VIRTKEY, CONTROL, NOINVERT
"O", IDM_FILE_OPEN, VIRTKEY, CONTROL, NOINVERT
"P", IDM_FILE_PREVIOUS, VIRTKEY, CONTROL, NOINVERT
"V", IDM_FILE_PREVIOUS, VIRTKEY, CONTROL, NOINVERT
"X", IDM_FILE_EXIT, VIRTKEY, ALT, NOINVERT
END
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
VISUALPNG ICON DISCARDABLE "VisualPng.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
ABOUTBOX DIALOG DISCARDABLE 0, 0, 186, 94
STYLE DS_MODALFRAME | WS_POPUP
FONT 8, "MS Sans Serif"
BEGIN
DEFPUSHBUTTON "OK",IDOK,68,67,50,14
CTEXT "VisualPng 1.0 - June 2000",IDC_STATIC,49,14,88,8
LTEXT "a PNG image viewer",IDC_STATIC,60,30,66,8
LTEXT "(c) Willem van Schaik, 2000",IDC_STATIC,48,52,90,8
LTEXT "to demonstrate the use of libpng in Visual C",
IDC_STATIC,25,38,136,8
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO DISCARDABLE
BEGIN
"ABOUTBOX", DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 179
TOPMARGIN, 7
BOTTOMMARGIN, 87
END
END
#endif // APSTUDIO_INVOKED
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@@ -1,22 +1,30 @@
/*===
cexcept.h 1.0.0 (2000-Jun-21-Wed)
Adam M. Costello <amc@cs.berkeley.edu>
cexcept.h 2.0.1 (2008-Jul-19-Sat)
http://www.nicemice.net/cexcept/
Adam M. Costello
http://www.nicemice.net/amc/
An interface for exception-handling in ANSI C, developed jointly with
Cosmin Truta <cosmin@cs.toronto.edu>.
An interface for exception-handling in ANSI C (C89 and subsequent ISO
standards), developed jointly with Cosmin Truta.
Copyright (c) 2000 Adam M. Costello and Cosmin Truta. Everyone
is hereby granted permission to do whatever they like with this
file, provided that if they modify it they take reasonable steps to
avoid confusing or misleading people about the authors, version,
and terms of use of the derived file. The copyright holders make
no guarantees about the correctness of this file, and are not
responsible for any damage resulting from its use.
Copyright (c) 2000-2008 Adam M. Costello and Cosmin Truta.
This software may be modified only if its author and version
information is updated accurately, and may be redistributed
only if accompanied by this unaltered notice. Subject to those
restrictions, permission is granted to anyone to do anything
with this software. The copyright holders make no guarantees
regarding this software, and are not responsible for any damage
resulting from its use.
If this interface is used by multiple .c files, they shouldn't include
The cexcept interface is not compatible with and cannot interact
with system exceptions (like division by zero or memory segmentation
violation), compiler-generated exceptions (like C++ exceptions), or
other exception-handling interfaces.
When using this interface across multiple .c files, do not include
this header file directly. Instead, create a wrapper header file that
includes this header file and then invokes the define_exception_type
macro (see below), and let your .c files include that header file.
macro (see below). The .c files should then include that header file.
The interface consists of one type, one well-known name, and six macros.
@@ -37,6 +45,10 @@ define_exception_type(type_name);
struct exception { int code; const char *msg; };
define_exception_type(struct exception);
Because throwing an exception causes the object to be copied (not
just once, but twice), programmers may wish to consider size when
choosing the exception type.
struct exception_context;
@@ -62,7 +74,7 @@ struct exception_context *the_exception_context;
application may declare a variable of this name anywhere it likes
(inside a function, in a parameter list, or externally), and may
use whatever storage class specifiers (static, extern, etc) or type
qualifiers (const, volatile) it likes. Examples:
qualifiers (const, volatile, etc) it likes. Examples:
static struct exception_context
* const the_exception_context = &foo;
@@ -107,15 +119,15 @@ Catch (expression) statement
confusion with the C++ keywords, which have subtly different
semantics.
A Try/Catch statement has a syntax similar to an if/else
statement, except that the parenthesized expression goes after
the second keyword rather than the first. As with if/else,
there are two clauses, each of which may be a simple statement
ending with a semicolon or a brace-enclosed compound statement.
But whereas the else clause is optional, the Catch clause is
required. The expression must be a modifiable lvalue (something
capable of being assigned to) of the exact same type passed to
define_exception_type().
A Try/Catch statement has a syntax similar to an if/else statement,
except that the parenthesized expression goes after the second
keyword rather than the first. As with if/else, there are two
clauses, each of which may be a simple statement ending with a
semicolon or a brace-enclosed compound statement. But whereas
the else clause is optional, the Catch clause is required. The
expression must be a modifiable lvalue (something capable of being
assigned to) of the same type (disregarding type qualifiers) that
was passed to define_exception_type().
If a Throw that uses the same exception context as the Try/Catch is
executed within the Try clause (typically within a function called
@@ -125,9 +137,8 @@ Catch (expression) statement
such Throw is executed, then the assignment is not performed, and
the Catch clause is not executed.
Regardless of whether an exception is caught, the expression is
always evaluated exactly once, which is significant if it has side
effects, for example:
The expression is not evaluated unless and until the exception is
caught, which is significant if it has side effects, for example:
Try foo();
Catch (p[++i].e) { ... }
@@ -158,7 +169,7 @@ Throw expression;
be compatible with the type passed to define_exception_type(). The
exception must be caught, otherwise the program may crash.
Slight limitation: If the expression is a comma-expression it must
Slight limitation: If the expression is a comma-expression, it must
be enclosed in parentheses.
@@ -183,62 +194,55 @@ is subject to change.
#include <setjmp.h>
#define define_exception_type(etype) \
struct exception__state { \
etype *exception; \
jmp_buf env; \
struct exception_context { \
jmp_buf *penv; \
int caught; \
volatile struct { etype etmp; } v; \
}
struct exception_context { \
struct exception__state *last; \
int caught; \
};
/* etmp must be volatile because the application might use automatic */
/* storage for the_exception_context, and etmp is modified between */
/* the calls to setjmp() and longjmp(). A wrapper struct is used to */
/* avoid warnings about a duplicate volatile qualifier in case etype */
/* already includes it. */
#define init_exception_context(ec) ((void)((ec)->last = 0))
#define Catch(e) exception__catch(&(e))
#define Catch_anonymous exception__catch(0)
#define init_exception_context(ec) ((void)((ec)->penv = 0))
#define Try \
{ \
struct exception__state *exception__p, exception__s; \
int exception__i; \
exception__p = the_exception_context->last; \
the_exception_context->last = &exception__s; \
for (exception__i = 0; ; exception__i = 1) \
if (exception__i) { \
if (setjmp(exception__s.env) == 0) { \
if (&exception__s)
jmp_buf *exception__prev, exception__env; \
exception__prev = the_exception_context->penv; \
the_exception_context->penv = &exception__env; \
if (setjmp(exception__env) == 0) { \
do
#define exception__catch(e_addr) \
else { } \
the_exception_context->caught = 0; \
} \
else the_exception_context->caught = 1; \
the_exception_context->last = exception__p; \
break; \
} \
else exception__s.exception = e_addr; \
#define exception__catch(action) \
while (the_exception_context->caught = 0, \
the_exception_context->caught); \
} \
else { \
the_exception_context->caught = 1; \
} \
the_exception_context->penv = exception__prev; \
} \
if (!the_exception_context->caught) { } \
if (!the_exception_context->caught || action) { } \
else
/* Try ends with if(), and Catch begins and ends with else. This */
/* ensures that the Try/Catch syntax is really the same as the */
/* if/else syntax. */
#define Catch(e) exception__catch(((e) = the_exception_context->v.etmp, 0))
#define Catch_anonymous exception__catch(0)
/* Try ends with do, and Catch begins with while(0) and ends with */
/* else, to ensure that Try/Catch syntax is similar to if/else */
/* syntax. */
/* */
/* We use &exception__s instead of 1 to appease compilers that */
/* warn about constant expressions inside if(). Most compilers */
/* should still recognize that &exception__s is never zero and avoid */
/* generating test code. */
/* */
/* We use the variable exception__i to start the loop at the bottom, */
/* rather than jump into the loop using a switch statement, to */
/* appease compilers that warn about jumping into loops. */
/* The 0 in while(0) is expressed as x=0,x in order to appease */
/* compilers that warn about constant expressions inside while(). */
/* Most compilers should still recognize that the condition is always */
/* false and avoid generating code for it. */
#define Throw \
for (;; longjmp(the_exception_context->last->env, 1)) \
if (the_exception_context->last->exception) \
*the_exception_context->last->exception =
for (;; longjmp(*the_exception_context->penv, 1)) \
the_exception_context->v.etmp =
#endif /* CEXCEPT_H */

630
depcomp Executable file
View File

@@ -0,0 +1,630 @@
#! /bin/sh
# depcomp - compile a program generating dependencies as side-effects
scriptversion=2009-04-28.21; # UTC
# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009 Free
# Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>.
case $1 in
'')
echo "$0: No command. Try \`$0 --help' for more information." 1>&2
exit 1;
;;
-h | --h*)
cat <<\EOF
Usage: depcomp [--help] [--version] PROGRAM [ARGS]
Run PROGRAMS ARGS to compile a file, generating dependencies
as side-effects.
Environment variables:
depmode Dependency tracking mode.
source Source file read by `PROGRAMS ARGS'.
object Object file output by `PROGRAMS ARGS'.
DEPDIR directory where to store dependencies.
depfile Dependency file to output.
tmpdepfile Temporary file to use when outputing dependencies.
libtool Whether libtool is used (yes/no).
Report bugs to <bug-automake@gnu.org>.
EOF
exit $?
;;
-v | --v*)
echo "depcomp $scriptversion"
exit $?
;;
esac
if test -z "$depmode" || test -z "$source" || test -z "$object"; then
echo "depcomp: Variables source, object and depmode must be set" 1>&2
exit 1
fi
# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po.
depfile=${depfile-`echo "$object" |
sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`}
tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
rm -f "$tmpdepfile"
# Some modes work just like other modes, but use different flags. We
# parameterize here, but still list the modes in the big case below,
# to make depend.m4 easier to write. Note that we *cannot* use a case
# here, because this file can only contain one case statement.
if test "$depmode" = hp; then
# HP compiler uses -M and no extra arg.
gccflag=-M
depmode=gcc
fi
if test "$depmode" = dashXmstdout; then
# This is just like dashmstdout with a different argument.
dashmflag=-xM
depmode=dashmstdout
fi
cygpath_u="cygpath -u -f -"
if test "$depmode" = msvcmsys; then
# This is just like msvisualcpp but w/o cygpath translation.
# Just convert the backslash-escaped backslashes to single forward
# slashes to satisfy depend.m4
cygpath_u="sed s,\\\\\\\\,/,g"
depmode=msvisualcpp
fi
case "$depmode" in
gcc3)
## gcc 3 implements dependency tracking that does exactly what
## we want. Yay! Note: for some reason libtool 1.4 doesn't like
## it if -MD -MP comes after the -MF stuff. Hmm.
## Unfortunately, FreeBSD c89 acceptance of flags depends upon
## the command line argument order; so add the flags where they
## appear in depend2.am. Note that the slowdown incurred here
## affects only configure: in makefiles, %FASTDEP% shortcuts this.
for arg
do
case $arg in
-c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;;
*) set fnord "$@" "$arg" ;;
esac
shift # fnord
shift # $arg
done
"$@"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
mv "$tmpdepfile" "$depfile"
;;
gcc)
## There are various ways to get dependency output from gcc. Here's
## why we pick this rather obscure method:
## - Don't want to use -MD because we'd like the dependencies to end
## up in a subdir. Having to rename by hand is ugly.
## (We might end up doing this anyway to support other compilers.)
## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
## -MM, not -M (despite what the docs say).
## - Using -M directly means running the compiler twice (even worse
## than renaming).
if test -z "$gccflag"; then
gccflag=-MD,
fi
"$@" -Wp,"$gccflag$tmpdepfile"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
echo "$object : \\" > "$depfile"
alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
## The second -e expression handles DOS-style file names with drive letters.
sed -e 's/^[^:]*: / /' \
-e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
## This next piece of magic avoids the `deleted header file' problem.
## The problem is that when a header file which appears in a .P file
## is deleted, the dependency causes make to die (because there is
## typically no way to rebuild the header). We avoid this by adding
## dummy dependencies for each header file. Too bad gcc doesn't do
## this for us directly.
tr ' ' '
' < "$tmpdepfile" |
## Some versions of gcc put a space before the `:'. On the theory
## that the space means something, we add a space to the output as
## well.
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
hp)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
sgi)
if test "$libtool" = yes; then
"$@" "-Wp,-MDupdate,$tmpdepfile"
else
"$@" -MDupdate "$tmpdepfile"
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
echo "$object : \\" > "$depfile"
# Clip off the initial element (the dependent). Don't try to be
# clever and replace this with sed code, as IRIX sed won't handle
# lines with more than a fixed number of characters (4096 in
# IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
# the IRIX cc adds comments like `#:fec' to the end of the
# dependency line.
tr ' ' '
' < "$tmpdepfile" \
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
tr '
' ' ' >> "$depfile"
echo >> "$depfile"
# The second pass generates a dummy entry for each header file.
tr ' ' '
' < "$tmpdepfile" \
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
>> "$depfile"
else
# The sourcefile does not contain any dependencies, so just
# store a dummy comment line, to avoid errors with the Makefile
# "include basename.Plo" scheme.
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
aix)
# The C for AIX Compiler uses -M and outputs the dependencies
# in a .u file. In older versions, this file always lives in the
# current directory. Also, the AIX compiler puts `$object:' at the
# start of each line; $object doesn't have directory information.
# Version 6 uses the directory in both cases.
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
test "x$dir" = "x$object" && dir=
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
if test "$libtool" = yes; then
tmpdepfile1=$dir$base.u
tmpdepfile2=$base.u
tmpdepfile3=$dir.libs/$base.u
"$@" -Wc,-M
else
tmpdepfile1=$dir$base.u
tmpdepfile2=$dir$base.u
tmpdepfile3=$dir$base.u
"$@" -M
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
do
test -f "$tmpdepfile" && break
done
if test -f "$tmpdepfile"; then
# Each line is of the form `foo.o: dependent.h'.
# Do two passes, one to just change these to
# `$object: dependent.h' and one to simply `dependent.h:'.
sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
# That's a tab and a space in the [].
sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
else
# The sourcefile does not contain any dependencies, so just
# store a dummy comment line, to avoid errors with the Makefile
# "include basename.Plo" scheme.
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
icc)
# Intel's C compiler understands `-MD -MF file'. However on
# icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c
# ICC 7.0 will fill foo.d with something like
# foo.o: sub/foo.c
# foo.o: sub/foo.h
# which is wrong. We want:
# sub/foo.o: sub/foo.c
# sub/foo.o: sub/foo.h
# sub/foo.c:
# sub/foo.h:
# ICC 7.1 will output
# foo.o: sub/foo.c sub/foo.h
# and will wrap long lines using \ :
# foo.o: sub/foo.c ... \
# sub/foo.h ... \
# ...
"$@" -MD -MF "$tmpdepfile"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
# Each line is of the form `foo.o: dependent.h',
# or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'.
# Do two passes, one to just change these to
# `$object: dependent.h' and one to simply `dependent.h:'.
sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile"
# Some versions of the HPUX 10.20 sed can't process this invocation
# correctly. Breaking it into two sed invocations is a workaround.
sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" |
sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
hp2)
# The "hp" stanza above does not work with aCC (C++) and HP's ia64
# compilers, which have integrated preprocessors. The correct option
# to use with these is +Maked; it writes dependencies to a file named
# 'foo.d', which lands next to the object file, wherever that
# happens to be.
# Much of this is similar to the tru64 case; see comments there.
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
test "x$dir" = "x$object" && dir=
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
if test "$libtool" = yes; then
tmpdepfile1=$dir$base.d
tmpdepfile2=$dir.libs/$base.d
"$@" -Wc,+Maked
else
tmpdepfile1=$dir$base.d
tmpdepfile2=$dir$base.d
"$@" +Maked
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile1" "$tmpdepfile2"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2"
do
test -f "$tmpdepfile" && break
done
if test -f "$tmpdepfile"; then
sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile"
# Add `dependent.h:' lines.
sed -ne '2,${
s/^ *//
s/ \\*$//
s/$/:/
p
}' "$tmpdepfile" >> "$depfile"
else
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile" "$tmpdepfile2"
;;
tru64)
# The Tru64 compiler uses -MD to generate dependencies as a side
# effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'.
# At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
# dependencies in `foo.d' instead, so we check for that too.
# Subdirectories are respected.
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
test "x$dir" = "x$object" && dir=
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
if test "$libtool" = yes; then
# With Tru64 cc, shared objects can also be used to make a
# static library. This mechanism is used in libtool 1.4 series to
# handle both shared and static libraries in a single compilation.
# With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d.
#
# With libtool 1.5 this exception was removed, and libtool now
# generates 2 separate objects for the 2 libraries. These two
# compilations output dependencies in $dir.libs/$base.o.d and
# in $dir$base.o.d. We have to check for both files, because
# one of the two compilations can be disabled. We should prefer
# $dir$base.o.d over $dir.libs/$base.o.d because the latter is
# automatically cleaned when .libs/ is deleted, while ignoring
# the former would cause a distcleancheck panic.
tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4
tmpdepfile2=$dir$base.o.d # libtool 1.5
tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5
tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504
"$@" -Wc,-MD
else
tmpdepfile1=$dir$base.o.d
tmpdepfile2=$dir$base.d
tmpdepfile3=$dir$base.d
tmpdepfile4=$dir$base.d
"$@" -MD
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
do
test -f "$tmpdepfile" && break
done
if test -f "$tmpdepfile"; then
sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
# That's a tab and a space in the [].
sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
else
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
#nosideeffect)
# This comment above is used by automake to tell side-effect
# dependency tracking mechanisms from slower ones.
dashmstdout)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout, regardless of -o.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# Remove `-o $object'.
IFS=" "
for arg
do
case $arg in
-o)
shift
;;
$object)
shift
;;
*)
set fnord "$@" "$arg"
shift # fnord
shift # $arg
;;
esac
done
test -z "$dashmflag" && dashmflag=-M
# Require at least two characters before searching for `:'
# in the target name. This is to cope with DOS-style filenames:
# a dependency such as `c:/foo/bar' could be seen as target `c' otherwise.
"$@" $dashmflag |
sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile"
rm -f "$depfile"
cat < "$tmpdepfile" > "$depfile"
tr ' ' '
' < "$tmpdepfile" | \
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
dashXmstdout)
# This case only exists to satisfy depend.m4. It is never actually
# run, as this mode is specially recognized in the preamble.
exit 1
;;
makedepend)
"$@" || exit $?
# Remove any Libtool call
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# X makedepend
shift
cleared=no eat=no
for arg
do
case $cleared in
no)
set ""; shift
cleared=yes ;;
esac
if test $eat = yes; then
eat=no
continue
fi
case "$arg" in
-D*|-I*)
set fnord "$@" "$arg"; shift ;;
# Strip any option that makedepend may not understand. Remove
# the object too, otherwise makedepend will parse it as a source file.
-arch)
eat=yes ;;
-*|$object)
;;
*)
set fnord "$@" "$arg"; shift ;;
esac
done
obj_suffix=`echo "$object" | sed 's/^.*\././'`
touch "$tmpdepfile"
${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
rm -f "$depfile"
cat < "$tmpdepfile" > "$depfile"
sed '1,2d' "$tmpdepfile" | tr ' ' '
' | \
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile" "$tmpdepfile".bak
;;
cpp)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# Remove `-o $object'.
IFS=" "
for arg
do
case $arg in
-o)
shift
;;
$object)
shift
;;
*)
set fnord "$@" "$arg"
shift # fnord
shift # $arg
;;
esac
done
"$@" -E |
sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \
-e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' |
sed '$ s: \\$::' > "$tmpdepfile"
rm -f "$depfile"
echo "$object : \\" > "$depfile"
cat < "$tmpdepfile" >> "$depfile"
sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
msvisualcpp)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
IFS=" "
for arg
do
case "$arg" in
-o)
shift
;;
$object)
shift
;;
"-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
set fnord "$@"
shift
shift
;;
*)
set fnord "$@" "$arg"
shift
shift
;;
esac
done
"$@" -E 2>/dev/null |
sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile"
rm -f "$depfile"
echo "$object : \\" > "$depfile"
sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile"
echo " " >> "$depfile"
sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile"
rm -f "$tmpdepfile"
;;
msvcmsys)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
none)
exec "$@"
;;
*)
echo "Unknown depmode $depmode" 1>&2
exit 1
;;
esac
exit 0
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-end: "; # UTC"
# End:

View File

@@ -1,47 +0,0 @@
Microsoft Developer Studio Build File, Format Version 6.00 for
libpng 1.0.9beta1 (November 10, 2000) and zlib
Copyright (C) 2000 Simon-Pierre Cadieux
For conditions of distribution and use, see copyright notice in png.h
Assumes that libpng sources are in ..\..
Assumes that zlib sources have been copied to ..\..\..\zlib
To build:
1) On the main menu Select "Build|Set Active configuration".
Among the configurations beginning with "libpng" select the
one you wish to build (the corresponding "zlib" configuration
will be built automatically).
2) Select "Build|Clean"
3) Select "Build|Rebuild All"
4) Look in the appropriate "win32" subdirectories for both "zlib"
and "libpng" binaries.
This project will build the PNG Development Group's "official" versions of
libpng and zlib libraries:
libpng1.dll (default version, currently C code only)
libpng1a.dll (C + Assembler version)
libpng1b.dll (C + Assembler debug version)
libpng1d.dll (C code debug version)
libpng1[c,e-m].dll (reserved for official versions)
libpng1[n-z].dll (available for private versions)
zlib.dll (default version, currently C code only)
zlibd.dll (debug version)
If you change anything in libpng, or select different compiler settings,
please change the library name to an unreserved name, and define
DLLFNAME_POSTFIX and (PRIVATEBUILD or SPECIALBUILD) accordingly. DLLFNAME_POSTFIX
should correspond to a string in the range of "N" to "Z" depending on the letter
you choose for your private version.
All DLLs built by this project use the Microsoft dynamic C runtime library
MSVCRT.DLL (MSVCRTD.DLL for debug versions). If you distribute any of the
above mentioned libraries you should also include this DLL in your package.
For a list of files that are redistributable in Visual C++ 6.0, see
Common\Redist\Redist.txt on Disc 1 of the Visual C++ 6.0 product CDs.

View File

@@ -1,367 +0,0 @@
# Microsoft Developer Studio Project File - Name="libpng" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
# TARGTYPE "Win32 (x86) Static Library" 0x0104
CFG=libpng - Win32 DLL
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
!MESSAGE use the Export Makefile command and run
!MESSAGE
!MESSAGE NMAKE /f "libpng.mak".
!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE NMAKE /f "libpng.mak" CFG="libpng - Win32 DLL"
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE "libpng - Win32 DLL" (based on "Win32 (x86) Dynamic-Link Library")
!MESSAGE "libpng - Win32 DLL Debug" (based on "Win32 (x86) Dynamic-Link Library")
!MESSAGE "libpng - Win32 DLL ASM" (based on "Win32 (x86) Dynamic-Link Library")
!MESSAGE "libpng - Win32 DLL Debug ASM" (based on "Win32 (x86) Dynamic-Link Library")
!MESSAGE "libpng - Win32 LIB" (based on "Win32 (x86) Static Library")
!MESSAGE "libpng - Win32 LIB Debug" (based on "Win32 (x86) Static Library")
!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
# PROP Scc_ProjName ""
# PROP Scc_LocalPath ""
!IF "$(CFG)" == "libpng - Win32 DLL"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "Release"
# PROP BASE Intermediate_Dir "Release"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir ".\win32\libpng\dll"
# PROP Intermediate_Dir ".\win32\libpng\dll"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
CPP=cl.exe
# ADD BASE CPP /nologo /MD /W3 /O1 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_USRDLL" /FD /c
# ADD CPP /nologo /MD /W3 /O1 /I "..\.." /I "..\..\..\zlib" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "PNG_BUILD_DLL" /D "ZLIB_DLL" /Yu"png.h" /FD /c
MTL=midl.exe
RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /i "..\.." /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /dll /machine:I386
# ADD LINK32 /nologo /dll /machine:I386 /out:".\win32\libpng\dll\libpng1.dll"
# SUBTRACT LINK32 /pdb:none
!ELSEIF "$(CFG)" == "libpng - Win32 DLL Debug"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "Debug"
# PROP BASE Intermediate_Dir "Debug"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir ".\win32\libpng\dll_dbg"
# PROP Intermediate_Dir ".\win32\libpng\dll_dbg"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
CPP=cl.exe
# ADD BASE CPP /nologo /MDd /W3 /Zi /Od /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_USRDLL" /FD /GZ /c
# ADD CPP /nologo /MDd /W3 /Zi /Od /I "..\.." /I "..\..\..\zlib" /D "DEBUG" /D "_DEBUG" /D PNG_DEBUG=1 /D "WIN32" /D "_WINDOWS" /D "PNG_BUILD_DLL" /D "ZLIB_DLL" /Yu"png.h" /FD /GZ /c
MTL=midl.exe
RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /i "..\.." /d "_DEBUG" /d PNG_DEBUG=1
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /dll /debug /machine:I386 /pdbtype:sept
# ADD LINK32 /nologo /dll /debug /machine:I386 /out:".\win32\libpng\dll_dbg\libpng1d.dll"
!ELSEIF "$(CFG)" == "libpng - Win32 DLL ASM"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "Release"
# PROP BASE Intermediate_Dir "Release"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir ".\win32\libpng\dll_asm"
# PROP Intermediate_Dir ".\win32\libpng\dll_asm"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
CPP=cl.exe
# ADD BASE CPP /nologo /MD /W3 /O1 /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_USRDLL" /FD /c
# ADD CPP /nologo /MD /W3 /O1 /I "..\.." /I "..\..\..\zlib" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "PNG_USE_PNGVCRD" /D "PNG_BUILD_DLL" /D "ZLIB_DLL" /Yu"png.h" /FD /c
MTL=midl.exe
RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /i "..\.." /d "NDEBUG" /d "PNG_USE_PNGVCRD"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /dll /machine:I386
# ADD LINK32 /nologo /dll /machine:I386 /out:".\win32\libpng\dll_asm\libpng1a.dll"
# SUBTRACT LINK32 /pdb:none
!ELSEIF "$(CFG)" == "libpng - Win32 DLL Debug ASM"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "Debug"
# PROP BASE Intermediate_Dir "Debug"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir ".\win32\libpng\dll_dbga"
# PROP Intermediate_Dir ".\win32\libpng\dll_dbga"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
CPP=cl.exe
# ADD BASE CPP /nologo /MDd /W3 /Zi /Od /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_USRDLL" /FD /GZ /c
# ADD CPP /nologo /MDd /W3 /Zi /Od /I "..\.." /I "..\..\..\zlib" /D "DEBUG" /D "_DEBUG" /D PNG_DEBUG=1 /D "WIN32" /D "_WINDOWS" /D "PNG_USE_PNGVCRD" /D "PNG_BUILD_DLL" /D "ZLIB_DLL" /Yu"png.h" /FD /GZ /c
MTL=midl.exe
RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /i "..\.." /d "_DEBUG" /d PNG_DEBUG=1 /d "PNG_USE_PNGVCRD"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 /nologo /dll /debug /machine:I386 /pdbtype:sept
# ADD LINK32 /nologo /dll /debug /machine:I386 /out:".\win32\libpng\dll_dbga\libpng1b.dll"
!ELSEIF "$(CFG)" == "libpng - Win32 LIB"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "Release"
# PROP BASE Intermediate_Dir "Release"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir ".\win32\libpng\lib"
# PROP Intermediate_Dir ".\win32\libpng\lib"
# PROP Target_Dir ""
MTL=midl.exe
CPP=cl.exe
# ADD BASE CPP /nologo /W3 /O1 /D "WIN32" /D "NDEBUG" /D "_LIB" /FD /c
# ADD CPP /nologo /W3 /O1 /I "..\.." /I "..\..\..\zlib" /D "WIN32" /D "NDEBUG" /Yu"png.h" /FD /c
RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /i "..\.." /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
# ADD LIB32 /nologo
!ELSEIF "$(CFG)" == "libpng - Win32 LIB Debug"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "Debug"
# PROP BASE Intermediate_Dir "Debug"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir ".\win32\libpng\lib_dbg"
# PROP Intermediate_Dir ".\win32\libpng\lib_dbg"
# PROP Target_Dir ""
MTL=midl.exe
CPP=cl.exe
# ADD BASE CPP /nologo /W3 /Zi /Od /D "_DEBUG" /D "WIN32" /D "_LIB" /FD /GZ /c
# ADD CPP /nologo /W3 /Zi /Od /I "..\.." /I "..\..\..\zlib" /D "DEBUG" /D "_DEBUG" /D PNG_DEBUG=1 /D "WIN32" /Yu"png.h" /FD /GZ /c
RSC=rc.exe
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
# ADD LIB32 /nologo
!ENDIF
# Begin Target
# Name "libpng - Win32 DLL"
# Name "libpng - Win32 DLL Debug"
# Name "libpng - Win32 DLL ASM"
# Name "libpng - Win32 DLL Debug ASM"
# Name "libpng - Win32 LIB"
# Name "libpng - Win32 LIB Debug"
# Begin Group "Source Files"
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
# Begin Source File
SOURCE=..\..\png.c
# SUBTRACT CPP /YX /Yc /Yu
# End Source File
# Begin Source File
SOURCE=.\png.rc
!IF "$(CFG)" == "libpng - Win32 DLL"
!ELSEIF "$(CFG)" == "libpng - Win32 DLL Debug"
!ELSEIF "$(CFG)" == "libpng - Win32 DLL ASM"
!ELSEIF "$(CFG)" == "libpng - Win32 DLL Debug ASM"
!ELSEIF "$(CFG)" == "libpng - Win32 LIB"
# PROP Exclude_From_Build 1
!ELSEIF "$(CFG)" == "libpng - Win32 LIB Debug"
# PROP Exclude_From_Build 1
!ENDIF
# End Source File
# Begin Source File
SOURCE=.\png32ms.def
!IF "$(CFG)" == "libpng - Win32 DLL"
!ELSEIF "$(CFG)" == "libpng - Win32 DLL Debug"
!ELSEIF "$(CFG)" == "libpng - Win32 DLL ASM"
!ELSEIF "$(CFG)" == "libpng - Win32 DLL Debug ASM"
!ELSEIF "$(CFG)" == "libpng - Win32 LIB"
# PROP Exclude_From_Build 1
!ELSEIF "$(CFG)" == "libpng - Win32 LIB Debug"
# PROP Exclude_From_Build 1
!ENDIF
# End Source File
# Begin Source File
SOURCE=..\..\pngerror.c
# ADD CPP /Yc"png.h"
# End Source File
# Begin Source File
SOURCE=..\..\pngget.c
# End Source File
# Begin Source File
SOURCE=..\..\pngmem.c
# End Source File
# Begin Source File
SOURCE=..\..\pngpread.c
# End Source File
# Begin Source File
SOURCE=..\..\pngread.c
# End Source File
# Begin Source File
SOURCE=..\..\pngrio.c
# End Source File
# Begin Source File
SOURCE=..\..\pngrtran.c
# End Source File
# Begin Source File
SOURCE=..\..\pngrutil.c
# End Source File
# Begin Source File
SOURCE=..\..\pngset.c
# End Source File
# Begin Source File
SOURCE=..\..\pngtrans.c
# End Source File
# Begin Source File
SOURCE=..\..\pngvcrd.c
!IF "$(CFG)" == "libpng - Win32 DLL"
# PROP Exclude_From_Build 1
!ELSEIF "$(CFG)" == "libpng - Win32 DLL Debug"
# PROP Exclude_From_Build 1
!ELSEIF "$(CFG)" == "libpng - Win32 DLL ASM"
!ELSEIF "$(CFG)" == "libpng - Win32 DLL Debug ASM"
!ELSEIF "$(CFG)" == "libpng - Win32 LIB"
# PROP Exclude_From_Build 1
!ELSEIF "$(CFG)" == "libpng - Win32 LIB Debug"
# PROP Exclude_From_Build 1
!ENDIF
# End Source File
# Begin Source File
SOURCE=..\..\pngwio.c
# End Source File
# Begin Source File
SOURCE=..\..\pngwrite.c
# End Source File
# Begin Source File
SOURCE=..\..\pngwtran.c
# End Source File
# Begin Source File
SOURCE=..\..\pngwutil.c
# End Source File
# End Group
# Begin Group "Header Files"
# PROP Default_Filter "h;hpp;hxx;hm;inl"
# Begin Source File
SOURCE=..\..\png.h
# End Source File
# Begin Source File
SOURCE=..\..\pngconf.h
# End Source File
# End Group
# Begin Group "Resource Files"
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
# End Group
# Begin Source File
SOURCE=.\readme.txt
# PROP Exclude_From_Build 1
# End Source File
# End Target
# End Project

Some files were not shown because too many files have changed in this diff Show More