blob: 75bb2dc69c5bfc251df5dfc44467ad057004ac79 [file] [log] [blame]
Glenn Randers-Pehrsonb6ce43d1998-01-01 07:13:13 -06001README for libpng 1.10
Andreas Dilger02ad0ef1997-01-17 01:34:35 -06002
Glenn Randers-Pehrsonb6ce43d1998-01-01 07:13:13 -06003This first official release of libpng. Don't let the fact that
4it's the first release fool you. The libpng library has been in
5extensive use and testing for about two years. However, it's
6finally gotten to the stage where there haven't been significant
7changes to the API in some time, and people have a bad feeling about
8libraries with versions < 1.0.
9
10Note that the version number is 1.10 to avoid potential problems
11with shared libraries created for Linux ELF under version 0.89,
12which mistakenly used 1.0.89 as the library version number in
13false anticipation of an imminent 1.0 release.
Andreas Dilger02ad0ef1997-01-17 01:34:35 -060014
Andreas Dilger47a0c421997-05-16 02:46:07 -050015****
16Note that some of the changes to the png_info structure render this
17version of the library binary incompatible with libpng-0.89 or
18earlier versions if you are using a shared library. The type of the
19"filler" parameter for png_set_filler() has changed from png_byte to
20png_uint_32, which will affect shared-library applications which use
21this function.
Andreas Dilger02ad0ef1997-01-17 01:34:35 -060022
Andreas Dilger47a0c421997-05-16 02:46:07 -050023To avoid problems with changes to the internals of png_info_struct,
24new APIs have been made available in 0.95 to avoid direct application
25access to info_ptr. These functions are the png_set_<chunk> and
26png_get_<chunk> functions. These functions should be used when
27accessing/storing the info_struct data, rather than manipulating it
28directly, to avoid such problems in the future.
Glenn Randers-Pehrsonb6ce43d1998-01-01 07:13:13 -060029
30It is important to note that the APIs do not make current programs
31which access the info struct directly incompatible with the new
32library. However, it is strongly suggested that new programs use
33the new APIs (as shown in example.c), and older programs be converted
34to the new format, to facilitate upgrades in the future.
Andreas Dilger47a0c421997-05-16 02:46:07 -050035****
Andreas Dilger02ad0ef1997-01-17 01:34:35 -060036
Andreas Dilger47a0c421997-05-16 02:46:07 -050037Additions since 0.90 include the ability to compile libpng as a
38Windows DLL, and new APIs for accessing data in the info struct.
39Experimental functions include the ability to set weighting and cost
40factors for row filter selection, direct reads of integers from buffers
41on big-endian processors that support misaligned data access, faster
42methods of doing alpha composition, and more accurate 16->8 bit color
43conversion.
Andreas Dilger02ad0ef1997-01-17 01:34:35 -060044
Andreas Dilger47a0c421997-05-16 02:46:07 -050045The additions since 0.89 include the ability to read from a PNG stream
46which has had some (or all) of the signature bytes read by the calling
47application. This also allows the reading of embedded PNG streams that
48do not have the PNG file signature. As well, it is now possible to set
49the library action on the detection of chunk CRC errors. It is possible
50to set different actions based on whether the CRC error occurred in a
51critical or an ancillary chunk.
Andreas Dilger02ad0ef1997-01-17 01:34:35 -060052
53The changes made to the library, and bugs fixed are based on discussions
54on the PNG implementation mailing list <png-implement@dworking.wustl.edu>
55and not on material submitted to Guy.
56
57For a detailed description on using libpng, read libpng.txt. For
Andreas Dilger47a0c421997-05-16 02:46:07 -050058examples of libpng in a program, see example.c and pngtest.c. For usage
59information and restrictions (what little they are) on libpng, see
60png.h. For a description on using zlib (the compression library used by
61libpng) and zlib's restrictions, see zlib.h
Andreas Dilger02ad0ef1997-01-17 01:34:35 -060062
Andreas Dilger47a0c421997-05-16 02:46:07 -050063I have included a general makefile, as well as several machine and
64compiler specific ones, but you may have to modify one for your own needs.
Andreas Dilger02ad0ef1997-01-17 01:34:35 -060065
66You should use zlib 1.0.4 or later to run this, but it MAY work with
67versions as old as zlib 0.95. Even so, there are bugs in older zlib
68versions which can cause the output of invalid compression streams for
69some images. You will definitely need zlib 1.0.4 or later if you are
70taking advantage of the MS-DOS "far" structure allocation for the small
71and medium memory models. You should also note that zlib is a
72compression library that is useful for more things than just PNG files.
73You can use zlib as a drop-in replacement for fread() and fwrite() if
74you are so inclined.
75
76zlib should be available at the same place that libpng is.
77If not, it should be at ftp.uu.net in /graphics/png
78Eventually, it will be at ftp.uu.net in /pub/archiving/zip/zlib
79
80You may also want a copy of the PNG specification. It is available
81as an Internet Draft, and RFC, and a W3C Recommendation. Failing
82these resources you can try ftp.uu.net in the /graphics/png directory.
83
84This code is currently being archived at ftp.uu.net in the
85/graphics/png directory, and on CompuServe, Lib 20 (PNG SUPPORT)
86at GO GRAPHSUP. If you can't find it in any of those places,
87e-mail me, and I'll help you find it.
88
89If you have any code changes, requests, problems, etc., please e-mail
90them to me. Also, I'd appreciate any make files or project files,
91and any modifications you needed to make to get libpng to compile,
92along with a #define variable to tell what compiler/system you are on.
93If you needed to add transformations to libpng, or wish libpng would
94provide the image in a different way, drop me a note (and code, if
95possible), so I can consider supporting the transformation.
96Finally, if you get any warning messages when compiling libpng
97(note: not zlib), and they are easy to fix, I'd appreciate the
98fix. Please mention "libpng" somewhere in the subject line. Thanks.
99
100This release was created and will be supported by myself (of course
101based in a large way on Guy's earlier work), and the PNG group.
102
103adilger@enel.ucalgary.ca
104png-implement@dworkin.wustl.edu
105
106You can reach Guy, the original libpng author, at (internet preferred):
107
108internet: schalnat@group42.com
109CompuServe: 75501,1625
110
111Please do not send general questions about PNG. Send them to
112the address in the specification. At the same time, please do
113not send libpng questions to that address, send them to me. I'll
114get them in the end anyway. If you have a question about something
115in the PNG specification that is related to using libpng, send it
116to me. Send me any questions that start with "I was using libpng,
117and ...". If in doubt, send questions to me. I'll bounce them
118to others, if necessary.
119
120Please do not send suggestions on how to change PNG. We have
121been discussing PNG for a couple years now, and it is official and
122finished. If you have suggestions for libpng, however, I'll
123gladly listen. Even if your suggestion is not used for version
1241.0, it may be used later.
125
126Files in this distribution:
127
Andreas Dilger47a0c421997-05-16 02:46:07 -0500128 CHANGES => Description of changes between libpng versions
Andreas Dilger02ad0ef1997-01-17 01:34:35 -0600129 README => This file
130 TODO => Things not implemented in the current library
131 ansi2knr.c => Converts files to K&R style function declarations
132 build.bat => MS-DOS batch file for Borland compiler
133 descrip.mms => VMS project file
134 example.c => Example code for using libpng functions
135 libpng.txt => Description of libpng and its functions
Andreas Dilger47a0c421997-05-16 02:46:07 -0500136 makefile => Default Unixish makefile
Andreas Dilger02ad0ef1997-01-17 01:34:35 -0600137 makefile.aco => ACORN makefile
138 makefile.ama => Amiga makefile
139 makefile.atr => Atari makefile
140 makefile.bor => Borland makefile
141 makefile.dj2 => DJGPP 2 makefile
142 makefile.elf => Unix ELF makefile
143 makefile.knr => Makefile which calls ansi2knr to convert files
144 makefile.mip => MIPS makefile
145 makefile.msc => Microsoft C makefile
146 makefile.std => Standard Unix makefile
147 makefile.tc => Turbo C makefile
148 makevms.com => VMS make program
149 png.c => Basic interface functions common to library
150 png.h => Library function and interface declarations
151 pngconf.h => System specific library configuration
152 pngerror.c => Error/warning message I/O functions
153 pngmem.c => Memory handling functions
154 pngpread.c => Progressive reading functions
Andreas Dilger02ad0ef1997-01-17 01:34:35 -0600155 pngread.c => Read data/helper high-level functions
156 pngrio.c => Lowest-level data read I/O functions
157 pngrtran.c => Read data transformation functions
158 pngrutil.c => Read data utility functions
Andreas Dilger47a0c421997-05-16 02:46:07 -0500159 pngset.c => Functions for storing data into the info_struct
Andreas Dilger02ad0ef1997-01-17 01:34:35 -0600160 pngtest.c => Library test program
161 pngtest.png => Library test sample image
162 pngtrans.c => Common data transformation functions
163 pngwio.c => Lowest-level write I/O functions
164 pngwrite.c => High-level write functions
165 pngwtran.c => Write data transformations
166 pngwutil.c => Write utility functions
167
168Good luck, and happy coding.
169
170-Andreas Eric Dilger
Andreas Dilger02ad0ef1997-01-17 01:34:35 -0600171 Internet: adilger@enel.ucalgary.ca
Andreas Dilger47a0c421997-05-16 02:46:07 -0500172 Web: http://www-mddsp.enel.ucalgary.ca/People/adilger/
Andreas Dilger02ad0ef1997-01-17 01:34:35 -0600173
174-Guy Eric Schalnat
175 Group 42, Inc.
176 Internet: schalnat@group42.com
177 CompuServe: 75501,1625
Andreas Dilger47a0c421997-05-16 02:46:07 -0500178 Web: http://www.group42.com/
Andreas Dilger02ad0ef1997-01-17 01:34:35 -0600179