mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
Imported from libpng-1.0.10beta1.tar
This commit is contained in:
361
libpng.3
361
libpng.3
@@ -1,6 +1,6 @@
|
||||
.TH LIBPNG 3 "January 31, 2001"
|
||||
.TH LIBPNG 3 "March 14, 2001"
|
||||
.SH NAME
|
||||
libpng \- Portable Network Graphics (PNG) Reference Library 1.0.9
|
||||
libpng \- Portable Network Graphics (PNG) Reference Library 1.0.10beta1
|
||||
.SH SYNOPSIS
|
||||
\fI\fB
|
||||
|
||||
@@ -747,7 +747,7 @@ Following is a copy of the libpng.txt file that accompanies libpng.
|
||||
.SH LIBPNG.TXT
|
||||
libpng.txt - A description on how to use and modify libpng
|
||||
|
||||
libpng version 1.0.9 - January 31, 2001
|
||||
libpng version 1.0.10beta1 - March 14, 2001
|
||||
Updated and distributed by Glenn Randers-Pehrson
|
||||
<randeg@alum.rpi.edu>
|
||||
Copyright (c) 1998, 1999, 2000 Glenn Randers-Pehrson
|
||||
@@ -1004,10 +1004,11 @@ input stream. You must supply the function
|
||||
png_byte name[5];
|
||||
png_byte *data;
|
||||
png_size_t size;
|
||||
/* Note that libpng has already taken care of the
|
||||
CRC handling */
|
||||
/* Note that libpng has already taken care of
|
||||
the CRC handling */
|
||||
|
||||
/* put your code here. Return one of the following: */
|
||||
/* put your code here. Return one of the
|
||||
following: */
|
||||
|
||||
return (-n); /* chunk had an error */
|
||||
return (0); /* did not recognize */
|
||||
@@ -1078,16 +1079,23 @@ the entire image into memory, and (b) the input transformations
|
||||
you want to do are limited to the following set:
|
||||
|
||||
PNG_TRANSFORM_IDENTITY No transformation
|
||||
PNG_TRANSFORM_STRIP_16 Strip 16-bit samples to 8 bits
|
||||
PNG_TRANSFORM_STRIP_16 Strip 16-bit samples to
|
||||
8 bits
|
||||
PNG_TRANSFORM_STRIP_ALPHA Discard the alpha channel
|
||||
PNG_TRANSFORM_PACKING Expand 1, 2 and 4-bit samples to bytes
|
||||
PNG_TRANSFORM_PACKSWAP Change order of packed pixels to LSB first
|
||||
PNG_TRANSFORM_PACKING Expand 1, 2 and 4-bit
|
||||
samples to bytes
|
||||
PNG_TRANSFORM_PACKSWAP Change order of packed
|
||||
pixels to LSB first
|
||||
PNG_TRANSFORM_EXPAND Perform set_expand()
|
||||
PNG_TRANSFORM_INVERT_MONO Invert monochrome images
|
||||
PNG_TRANSFORM_SHIFT Normalize pixels to the sBIT depth
|
||||
PNG_TRANSFORM_BGR Flip RGB to BGR, RGBA to BGRA
|
||||
PNG_TRANSFORM_SWAP_ALPHA Flip RGBA to ARGB or GA to AG
|
||||
PNG_TRANSFORM_INVERT_ALPHA Change alpha from opacity to transparency
|
||||
PNG_TRANSFORM_SHIFT Normalize pixels to the
|
||||
sBIT depth
|
||||
PNG_TRANSFORM_BGR Flip RGB to BGR, RGBA
|
||||
to BGRA
|
||||
PNG_TRANSFORM_SWAP_ALPHA Flip RGBA to ARGB or GA
|
||||
to AG
|
||||
PNG_TRANSFORM_INVERT_ALPHA Change alpha from opacity
|
||||
to transparency
|
||||
PNG_TRANSFORM_SWAP_ENDIAN Byte-swap 16-bit samples
|
||||
|
||||
(This excludes setting a background color, doing gamma transformation,
|
||||
@@ -1115,9 +1123,11 @@ where row_pointers is an array of pointers to the pixel data for each row:
|
||||
If you know your image size and pixel size ahead of time, you can allocate
|
||||
row_pointers prior to calling png_read_png() with
|
||||
|
||||
row_pointers = png_malloc(png_ptr, height*sizeof(png_bytep));
|
||||
row_pointers = png_malloc(png_ptr,
|
||||
height*sizeof(png_bytep));
|
||||
for (int i=0; i<height, i++)
|
||||
row_pointers[i]=png_malloc(png_ptr, width*pixel_size);
|
||||
row_pointers[i]=png_malloc(png_ptr,
|
||||
width*pixel_size);
|
||||
png_set_rows(png_ptr, info_ptr, &row_pointers);
|
||||
|
||||
Alternatively you could allocate your image in one big block and define
|
||||
@@ -1185,8 +1195,8 @@ in until png_read_end() has read the chunk data following the image.
|
||||
interlace_type - (PNG_INTERLACE_NONE or
|
||||
PNG_INTERLACE_ADAM7)
|
||||
Any or all of interlace_type, compression_type, of
|
||||
filter_method can be NULL if you are
|
||||
not interested in their values.
|
||||
filter_method can be NULL if you are
|
||||
not interested in their values.
|
||||
|
||||
channels = png_get_channels(png_ptr, info_ptr);
|
||||
channels - number of channels of info for the
|
||||
@@ -1249,14 +1259,15 @@ into the info_ptr is returned for any complex types.
|
||||
implies specific values of gAMA and
|
||||
cHRM.
|
||||
|
||||
png_get_iCCP(png_ptr, info_ptr, &name, &compression_type,
|
||||
&profile, &proflen);
|
||||
png_get_iCCP(png_ptr, info_ptr, &name,
|
||||
&compression_type, &profile, &proflen);
|
||||
name - The profile name.
|
||||
compression - The compression type; always PNG_COMPRESSION_TYPE_BASE
|
||||
for PNG 1.0. You may give NULL to this argument
|
||||
to ignore it.
|
||||
profile - International Color Consortium color profile
|
||||
data. May contain NULs.
|
||||
compression - The compression type; always
|
||||
PNG_COMPRESSION_TYPE_BASE for PNG 1.0.
|
||||
You may give NULL to this argument to
|
||||
ignore it.
|
||||
profile - International Color Consortium color
|
||||
profile data. May contain NULs.
|
||||
proflen - length of profile data in bytes.
|
||||
|
||||
png_get_sBIT(png_ptr, info_ptr, &sig_bit);
|
||||
@@ -1312,21 +1323,24 @@ into the info_ptr is returned for any complex types.
|
||||
string for unknown).
|
||||
text_ptr[i].translated_keyword - keyword in UTF-8
|
||||
(empty string for unknown).
|
||||
num_text - number of comments (same as num_comments;
|
||||
you can put NULL here to avoid the duplication)
|
||||
Note while png_set_text() will accept text, language, and
|
||||
translated keywords that can be NULL pointers, the structure
|
||||
returned by png_get_text will always contain regular
|
||||
zero-terminated C strings. They might be empty strings but
|
||||
they will never be NULL pointers.
|
||||
num_text - number of comments (same as
|
||||
num_comments; you can put NULL here
|
||||
to avoid the duplication)
|
||||
Note while png_set_text() will accept text, language,
|
||||
and translated keywords that can be NULL pointers, the
|
||||
structure returned by png_get_text will always contain
|
||||
regular zero-terminated C strings. They might be
|
||||
empty strings but they will never be NULL pointers.
|
||||
|
||||
num_spalettes = png_get_sPLT(png_ptr, info_ptr, &palette_ptr);
|
||||
num_spalettes = png_get_sPLT(png_ptr, info_ptr,
|
||||
&palette_ptr);
|
||||
palette_ptr - array of palette structures holding
|
||||
contents of one or more sPLT chunks read.
|
||||
contents of one or more sPLT chunks
|
||||
read.
|
||||
num_spalettes - number of sPLT chunks read.
|
||||
|
||||
png_get_oFFs(png_ptr, info_ptr, &offset_x, &offset_y,
|
||||
&unit_type);
|
||||
&unit_type);
|
||||
offset_x - positive offset from the left edge
|
||||
of the screen
|
||||
offset_y - positive offset from the top edge
|
||||
@@ -1334,7 +1348,7 @@ into the info_ptr is returned for any complex types.
|
||||
unit_type - PNG_OFFSET_PIXEL, PNG_OFFSET_MICROMETER
|
||||
|
||||
png_get_pHYs(png_ptr, info_ptr, &res_x, &res_y,
|
||||
&unit_type);
|
||||
&unit_type);
|
||||
res_x - pixels/unit physical resolution in
|
||||
x direction
|
||||
res_y - pixels/unit physical resolution in
|
||||
@@ -1342,47 +1356,50 @@ into the info_ptr is returned for any complex types.
|
||||
unit_type - PNG_RESOLUTION_UNKNOWN,
|
||||
PNG_RESOLUTION_METER
|
||||
|
||||
png_get_sCAL(png_ptr, info_ptr, &unit, &width, &height)
|
||||
png_get_sCAL(png_ptr, info_ptr, &unit, &width,
|
||||
&height)
|
||||
unit - physical scale units (an integer)
|
||||
width - width of a pixel in physical scale units
|
||||
height - height of a pixel in physical scale units
|
||||
(width and height are doubles)
|
||||
|
||||
png_get_sCAL_s(png_ptr, info_ptr, &unit, &width, &height)
|
||||
png_get_sCAL_s(png_ptr, info_ptr, &unit, &width,
|
||||
&height)
|
||||
unit - physical scale units (an integer)
|
||||
width - width of a pixel in physical scale units
|
||||
height - height of a pixel in physical scale units
|
||||
(width and height are strings like "2.54")
|
||||
|
||||
num_unknown_chunks = png_get_unknown_chunks(png_ptr, info_ptr,
|
||||
&unknowns)
|
||||
unknowns - array of png_unknown_chunk structures holding
|
||||
unknown chunks
|
||||
num_unknown_chunks = png_get_unknown_chunks(png_ptr,
|
||||
info_ptr, &unknowns)
|
||||
unknowns - array of png_unknown_chunk
|
||||
structures holding unknown chunks
|
||||
unknowns[i].name - name of unknown chunk
|
||||
unknowns[i].data - data of unknown chunk
|
||||
unknowns[i].size - size of unknown chunk's data
|
||||
unknowns[i].location - position of chunk in file
|
||||
|
||||
The value of "i" corresponds to the order in which the chunks were read
|
||||
from the PNG file or inserted with the png_set_unknown_chunks() function.
|
||||
The value of "i" corresponds to the order in which the
|
||||
chunks were read from the PNG file or inserted with the
|
||||
png_set_unknown_chunks() function.
|
||||
|
||||
The data from the pHYs chunk can be retrieved in several convenient
|
||||
forms:
|
||||
|
||||
res_x = png_get_x_pixels_per_meter(png_ptr,
|
||||
info_ptr)
|
||||
info_ptr)
|
||||
res_y = png_get_y_pixels_per_meter(png_ptr,
|
||||
info_ptr)
|
||||
info_ptr)
|
||||
res_x_and_y = png_get_pixels_per_meter(png_ptr,
|
||||
info_ptr)
|
||||
info_ptr)
|
||||
res_x = png_get_x_pixels_per_inch(png_ptr,
|
||||
info_ptr)
|
||||
info_ptr)
|
||||
res_y = png_get_y_pixels_per_inch(png_ptr,
|
||||
info_ptr)
|
||||
info_ptr)
|
||||
res_x_and_y = png_get_pixels_per_inch(png_ptr,
|
||||
info_ptr)
|
||||
info_ptr)
|
||||
aspect_ratio = png_get_pixel_aspect_ratio(png_ptr,
|
||||
info_ptr)
|
||||
info_ptr)
|
||||
|
||||
(Each of these returns 0 [signifying "unknown"] if
|
||||
the data is not present or if res_x is 0;
|
||||
@@ -1397,8 +1414,8 @@ forms:
|
||||
y_offset = png_get_y_offset_inches(png_ptr, info_ptr);
|
||||
|
||||
(Each of these returns 0 [signifying "unknown" if both
|
||||
x and y are 0] if the data is not present or if the chunk
|
||||
is present but the unit is the pixel)
|
||||
x and y are 0] if the data is not present or if the
|
||||
chunk is present but the unit is the pixel)
|
||||
|
||||
For more information, see the png_info definition in png.h and the
|
||||
PNG specification for chunk contents. Be careful with trusting
|
||||
@@ -1932,7 +1949,7 @@ When you are done, you can free all memory allocated by libpng like this:
|
||||
It is also possible to individually free the info_ptr members that
|
||||
point to libpng-allocated storage with the following function:
|
||||
|
||||
png_free_data(png_ptr, info_ptr, mask, n)
|
||||
png_free_data(png_ptr, info_ptr, mask, seq)
|
||||
mask - identifies data to be freed, a mask
|
||||
containing the logical OR of one or
|
||||
more of
|
||||
@@ -1942,16 +1959,17 @@ point to libpng-allocated storage with the following function:
|
||||
PNG_FREE_SCAL, PNG_FREE_SPLT,
|
||||
PNG_FREE_TEXT, PNG_FREE_UNKN,
|
||||
or simply PNG_FREE_ALL
|
||||
n - sequence number of item to be freed
|
||||
seq - sequence number of item to be freed
|
||||
(-1 for all items)
|
||||
|
||||
This function may be safely called when the relevant storage has
|
||||
already been freed, or has not yet been allocated, or was allocated
|
||||
by the user and not by libpng, and will in those
|
||||
cases do nothing. The "n" parameter is ignored if only one item
|
||||
of the selected data type, such as PLTE, is allowed. If "n" is not
|
||||
cases do nothing. The "seq" parameter is ignored if only one item
|
||||
of the selected data type, such as PLTE, is allowed. If "seq" is not
|
||||
-1, and multiple items are allowed for the data type identified in
|
||||
the mask, such as text or sPLT, only the n'th item is freed.
|
||||
the mask, such as text or sPLT, only the n'th item in the structure
|
||||
is freed, where n is "seq".
|
||||
|
||||
The default behavior is only to free data that was allocated internally
|
||||
by libpng. This can be changed, so that libpng will not free the data,
|
||||
@@ -2124,9 +2142,10 @@ png_infop info_ptr;
|
||||
|
||||
/* This function is called when each row of image
|
||||
data is complete */
|
||||
|
||||
void
|
||||
row_callback(png_structp png_ptr, png_bytep new_row,
|
||||
png_uint_32 row_num, int pass)
|
||||
png_uint_32 row_num, int pass)
|
||||
{
|
||||
/* If the image is interlaced, and you turned
|
||||
on the interlace handler, this function will
|
||||
@@ -2270,7 +2289,8 @@ called after each row has been written, which you can use to control
|
||||
a progress meter or the like. It's demonstrated in pngtest.c.
|
||||
You must supply a function
|
||||
|
||||
void write_row_callback(png_ptr, png_uint_32 row, int pass);
|
||||
void write_row_callback(png_ptr, png_uint_32 row,
|
||||
int pass);
|
||||
{
|
||||
/* put your code here */
|
||||
}
|
||||
@@ -2298,8 +2318,9 @@ types.
|
||||
|
||||
|
||||
/* turn on or off filtering, and/or choose
|
||||
specific filters. You can use either a single PNG_FILTER_VALUE_NAME
|
||||
or the logical OR of one or more PNG_FILTER_NAME masks. */
|
||||
specific filters. You can use either a single
|
||||
PNG_FILTER_VALUE_NAME or the logical OR of one
|
||||
or more PNG_FILTER_NAME masks. */
|
||||
png_set_filter(png_ptr, 0,
|
||||
PNG_FILTER_NONE | PNG_FILTER_VALUE_NONE |
|
||||
PNG_FILTER_SUB | PNG_FILTER_VALUE_SUB |
|
||||
@@ -2435,11 +2456,12 @@ Some of the more important parts of the png_info are:
|
||||
png_set_iCCP(png_ptr, info_ptr, name, compression_type,
|
||||
profile, proflen);
|
||||
name - The profile name.
|
||||
compression - The compression type; always PNG_COMPRESSION_TYPE_BASE
|
||||
for PNG 1.0. You may give NULL to this argument
|
||||
to ignore it.
|
||||
profile - International Color Consortium color profile
|
||||
data. May contain NULs.
|
||||
compression - The compression type; always
|
||||
PNG_COMPRESSION_TYPE_BASE for PNG 1.0.
|
||||
You may give NULL to this argument to
|
||||
ignore it.
|
||||
profile - International Color Consortium color
|
||||
profile data. May contain NULs.
|
||||
proflen - length of profile data in bytes.
|
||||
|
||||
png_set_sBIT(png_ptr, info_ptr, sig_bit);
|
||||
@@ -2493,11 +2515,13 @@ Some of the more important parts of the png_info are:
|
||||
or empty for unknown).
|
||||
num_text - number of comments
|
||||
|
||||
png_set_sPLT(png_ptr, info_ptr, &palette_ptr, num_spalettes);
|
||||
palette_ptr - array of png_sPLT_struct structures to be
|
||||
added to the list of palettes in the info
|
||||
structure.
|
||||
num_spalettes - number of palette structures to be added.
|
||||
png_set_sPLT(png_ptr, info_ptr, &palette_ptr,
|
||||
num_spalettes);
|
||||
palette_ptr - array of png_sPLT_struct structures
|
||||
to be added to the list of palettes
|
||||
in the info structure.
|
||||
num_spalettes - number of palette structures to be
|
||||
added.
|
||||
|
||||
png_set_oFFs(png_ptr, info_ptr, offset_x, offset_y,
|
||||
unit_type);
|
||||
@@ -2528,9 +2552,10 @@ Some of the more important parts of the png_info are:
|
||||
height - height of a pixel in physical scale units
|
||||
(width and height are strings like "2.54")
|
||||
|
||||
png_set_unknown_chunks(png_ptr, info_ptr, &unknowns, num_unknowns)
|
||||
unknowns - array of png_unknown_chunk structures holding
|
||||
unknown chunks
|
||||
png_set_unknown_chunks(png_ptr, info_ptr, &unknowns,
|
||||
num_unknowns)
|
||||
unknowns - array of png_unknown_chunk
|
||||
structures holding unknown chunks
|
||||
unknowns[i].name - name of unknown chunk
|
||||
unknowns[i].data - data of unknown chunk
|
||||
unknowns[i].size - size of unknown chunk's data
|
||||
@@ -2539,14 +2564,15 @@ Some of the more important parts of the png_info are:
|
||||
PNG_HAVE_IHDR: before PLTE
|
||||
PNG_HAVE_PLTE: before IDAT
|
||||
PNG_AFTER_IDAT: after IDAT
|
||||
The "location" member is set automatically according to
|
||||
what part of the output file has already been written.
|
||||
You can change its value after calling png_set_unknown_chunks()
|
||||
as demonstrated in pngtest.c. Within each of the "locations",
|
||||
the chunks are sequenced according to their position in the
|
||||
structure (that is, the value of "i", which is the order in which
|
||||
the chunk was either read from the input file or defined with
|
||||
png_set_unknown_chunks).
|
||||
|
||||
The "location" member is set automatically according to
|
||||
what part of the output file has already been written.
|
||||
You can change its value after calling png_set_unknown_chunks()
|
||||
as demonstrated in pngtest.c. Within each of the "locations",
|
||||
the chunks are sequenced according to their position in the
|
||||
structure (that is, the value of "i", which is the order in which
|
||||
the chunk was either read from the input file or defined with
|
||||
png_set_unknown_chunks).
|
||||
|
||||
A quick word about text and num_text. text is an array of png_text
|
||||
structures. num_text is the number of valid structures in the array.
|
||||
@@ -2647,12 +2673,17 @@ transformations are permitted, enabled by the following masks.
|
||||
|
||||
PNG_TRANSFORM_IDENTITY No transformation
|
||||
PNG_TRANSFORM_PACKING Pack 1, 2 and 4-bit samples
|
||||
PNG_TRANSFORM_PACKSWAP Change order of packed pixels to LSB first
|
||||
PNG_TRANSFORM_PACKSWAP Change order of packed
|
||||
pixels to LSB first
|
||||
PNG_TRANSFORM_INVERT_MONO Invert monochrome images
|
||||
PNG_TRANSFORM_SHIFT Normalize pixels to the sBIT depth
|
||||
PNG_TRANSFORM_BGR Flip RGB to BGR, RGBA to BGRA
|
||||
PNG_TRANSFORM_SWAP_ALPHA Flip RGBA to ARGB or GA to AG
|
||||
PNG_TRANSFORM_INVERT_ALPHA Change alpha from opacity to transparency
|
||||
PNG_TRANSFORM_SHIFT Normalize pixels to the
|
||||
sBIT depth
|
||||
PNG_TRANSFORM_BGR Flip RGB to BGR, RGBA
|
||||
to BGRA
|
||||
PNG_TRANSFORM_SWAP_ALPHA Flip RGBA to ARGB or GA
|
||||
to AG
|
||||
PNG_TRANSFORM_INVERT_ALPHA Change alpha from opacity
|
||||
to transparency
|
||||
PNG_TRANSFORM_SWAP_ENDIAN Byte-swap 16-bit samples
|
||||
PNG_TRANSFORM_STRIP_FILLER Strip out filler bytes.
|
||||
|
||||
@@ -2916,7 +2947,7 @@ When you are done, you can free all memory used by libpng like this:
|
||||
It is also possible to individually free the info_ptr members that
|
||||
point to libpng-allocated storage with the following function:
|
||||
|
||||
png_free_data(png_ptr, info_ptr, mask, n)
|
||||
png_free_data(png_ptr, info_ptr, mask, seq)
|
||||
mask - identifies data to be freed, a mask
|
||||
containing the logical OR of one or
|
||||
more of
|
||||
@@ -2926,16 +2957,17 @@ point to libpng-allocated storage with the following function:
|
||||
PNG_FREE_SCAL, PNG_FREE_SPLT,
|
||||
PNG_FREE_TEXT, PNG_FREE_UNKN,
|
||||
or simply PNG_FREE_ALL
|
||||
n - sequence number of item to be freed
|
||||
seq - sequence number of item to be freed
|
||||
(-1 for all items)
|
||||
|
||||
This function may be safely called when the relevant storage has
|
||||
already been freed, or has not yet been allocated, or was allocated
|
||||
by the user and not by libpng, and will in those
|
||||
cases do nothing. The "n" parameter is ignored if only one item
|
||||
of the selected data type, such as PLTE, is allowed. If "n" is not
|
||||
cases do nothing. The "seq" parameter is ignored if only one item
|
||||
of the selected data type, such as PLTE, is allowed. If "seq" is not
|
||||
-1, and multiple items are allowed for the data type identified in
|
||||
the mask, such as text or sPLT, only the n'th item is freed.
|
||||
the mask, such as text or sPLT, only the n'th item in the structure
|
||||
is freed, where n is "seq".
|
||||
|
||||
If you allocated data such as a palette that you passed
|
||||
in to libpng with png_set_*, you must not free it until just before the call to
|
||||
@@ -3016,8 +3048,8 @@ memory allocation on a platform will change between applications, these
|
||||
functions must be modified in the library at compile time. If you prefer
|
||||
to use a different method of allocating and freeing data, you can use
|
||||
|
||||
png_set_mem_fn(png_structp png_ptr, png_voidp mem_ptr, png_malloc_ptr
|
||||
malloc_fn, png_free_ptr free_fn)
|
||||
png_set_mem_fn(png_structp png_ptr, png_voidp mem_ptr,
|
||||
png_malloc_ptr malloc_fn, png_free_ptr free_fn)
|
||||
|
||||
This function also provides a void pointer that can be retrieved via
|
||||
|
||||
@@ -3025,7 +3057,8 @@ This function also provides a void pointer that can be retrieved via
|
||||
|
||||
Your replacement memory functions must have prototypes as follows:
|
||||
|
||||
png_voidp malloc_fn(png_structp png_ptr, png_uint_32 size);
|
||||
png_voidp malloc_fn(png_structp png_ptr,
|
||||
png_uint_32 size);
|
||||
void free_fn(png_structp png_ptr, png_voidp ptr);
|
||||
|
||||
Input/Output in libpng is done through png_read() and png_write(),
|
||||
@@ -3237,10 +3270,12 @@ structures appropriately for all of the filter types.
|
||||
|
||||
png_set_filter(png_ptr, PNG_FILTER_TYPE_BASE,
|
||||
filters);
|
||||
The second parameter can also be PNG_INTRAPIXEL_DIFFERENCING
|
||||
if you are writing a PNG to be embedded in a MNG
|
||||
datastream. This parameter must be the same as the
|
||||
value of filter_method used in png_set_IHDR().
|
||||
The second parameter can also be
|
||||
PNG_INTRAPIXEL_DIFFERENCING if you are
|
||||
writing a PNG to be embedded in a MNG
|
||||
datastream. This parameter must be the
|
||||
same as the value of filter_method used
|
||||
in png_set_IHDR().
|
||||
|
||||
It is also possible to influence how libpng chooses from among the
|
||||
available filters. This is done in two ways - by telling it how
|
||||
@@ -3429,13 +3464,13 @@ application:
|
||||
|
||||
.SH VIII. Y2K Compliance in libpng
|
||||
|
||||
January 31, 2001
|
||||
March 14, 2001
|
||||
|
||||
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.9 are Y2K compliant. It is my belief that earlier
|
||||
upward through 1.0.10beta1 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
|
||||
@@ -3453,7 +3488,8 @@ 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_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
|
||||
@@ -3492,43 +3528,63 @@ on the library has not always been consistent and straightforward.
|
||||
The following table summarizes matters since version 0.89c, which was
|
||||
the first widely used release:
|
||||
|
||||
source png.h png.h shared-lib
|
||||
version string int version
|
||||
------- ------ ----- ----------
|
||||
0.89c ("1.0 beta 3") 0.89 89 1.0.89
|
||||
0.90 ("1.0 beta 4") 0.90 90 0.90 [should have been 2.0.90]
|
||||
0.95 ("1.0 beta 5") 0.95 95 0.95 [should have been 2.0.95]
|
||||
0.96 ("1.0 beta 6") 0.96 96 0.96 [should have been 2.0.96]
|
||||
0.97b ("1.00.97 beta 7") 1.00.97 97 1.0.1 [should have been 2.0.97]
|
||||
0.97c 0.97 97 2.0.97
|
||||
0.98 0.98 98 2.0.98
|
||||
0.99 0.99 98 2.0.99
|
||||
0.99a-m 0.99 99 2.0.99
|
||||
1.00 1.00 100 2.1.0 [100 should be 10000]
|
||||
1.0.0 1.0.0 100 2.1.0 [100 should be 10000]
|
||||
1.0.1 1.0.1 10001 2.1.0
|
||||
1.0.1a-e 1.0.1a-e 10002 2.1.0.1a-e
|
||||
1.0.2 1.0.2 10002 2.1.0.2
|
||||
1.0.2a-b 1.0.2a-b 10003 2.1.0.2a-b
|
||||
1.0.3 1.0.3 10003 2.1.0.3
|
||||
1.0.3a-d 1.0.3a-d 10004 2.1.0.3a-d
|
||||
1.0.4 1.0.4 10004 2.1.0.4
|
||||
1.0.4a-f 1.0.4a-f 10005 2.1.0.4a-f
|
||||
1.0.5 (+ 2 patches) 1.0.5 10005 2.1.0.5
|
||||
1.0.5a-d 1.0.5a-d 10006 2.1.0.5a-d
|
||||
1.0.5e-r 1.0.5e-r 10100 2.1.0.5e-r (not compatible)
|
||||
1.0.5s-v 1.0.5s-v 10006 2.1.0.5s-v (compatible)
|
||||
1.0.6 (+ 3 patches) 1.0.6 10006 2.1.0.6
|
||||
1.0.6d 1.0.6d 10007 2.1.0.6d
|
||||
1.0.7 1.0.7 10007 2.1.0.7 (still compatible)
|
||||
source png.h png.h shared-lib
|
||||
version string int version
|
||||
------- ------ ----- ----------
|
||||
0.89c ("beta 3") 0.89 89 1.0.89
|
||||
0.90 ("beta 4") 0.90 90 0.90
|
||||
0.95 ("beta 5") 0.95 95 0.95
|
||||
0.96 ("beta 6") 0.96 96 0.96
|
||||
0.97b ("beta 7") 1.00.97 97 1.0.1
|
||||
0.97c 0.97 97 2.0.97
|
||||
0.98 0.98 98 2.0.98
|
||||
0.99 0.99 98 2.0.99
|
||||
0.99a-m 0.99 99 2.0.99
|
||||
1.00 1.00 100 2.1.0
|
||||
1.0.0 1.0.0 100 2.1.0
|
||||
1.0.0 (from here on, the 100 2.1.0
|
||||
1.0.1 png.h string is 10001 2.1.0
|
||||
1.0.1a-e identical to the 10002 from here on, the
|
||||
1.0.2 source version) 10002 shared library is 2.V
|
||||
1.0.2a-b 10003 where V is the source
|
||||
1.0.1 10001 code version except as
|
||||
1.0.1a-e 10002 2.1.0.1a-e noted.
|
||||
1.0.2 10002 2.1.0.2
|
||||
1.0.2a-b 10003 2.1.0.2a-b
|
||||
1.0.3 10003 2.1.0.3
|
||||
1.0.3a-d 10004 2.1.0.3a-d
|
||||
1.0.4 10004 2.1.0.4
|
||||
1.0.4a-f 10005 2.1.0.4a-f
|
||||
1.0.5 (+ 2 patches) 10005 2.1.0.5
|
||||
1.0.5a-d 10006 2.1.0.5a-d
|
||||
1.0.5e-r 10100 2.1.0.5e-r
|
||||
1.0.5s-v 10006 2.1.0.5s-v
|
||||
1.0.6 (+ 3 patches) 10006 2.1.0.6
|
||||
1.0.6d-g 10007 2.1.0.6d-g
|
||||
1.0.6h 10007 10.6h
|
||||
1.0.6i 10007 10.6i
|
||||
1.0.6j 10007 2.1.0.6j
|
||||
1.0.7beta11-14 DLLNUM 10007 2.1.0.7beta11-14
|
||||
1.0.7beta15-18 1 10007 2.1.0.7beta15-18
|
||||
1.0.7rc1-2 1 10007 2.1.0.7rc1-2
|
||||
1.0.7 1 10007 2.1.0.7
|
||||
1.0.8beta1-4 1 10008 2.1.0.8beta1-4
|
||||
1.0.8rc1 1 10008 2.1.0.8rc1
|
||||
1.0.8 1 10008 2.1.0.8
|
||||
1.0.9beta1-6 1 10009 2.1.0.9beta1-6
|
||||
1.0.9rc1 1 10009 2.1.0.9rc1
|
||||
1.0.9beta7-10 1 10009 2.1.0.9beta7-10
|
||||
1.0.9rc2 1 10009 2.1.0.9rc2
|
||||
1.0.9 1 10009 2.1.0.9
|
||||
1.0.10rc1 1 10010 2.1.0.10rc1
|
||||
|
||||
Henceforth the source version will match the shared-library minor
|
||||
and patch numbers; the shared-library major version number will be
|
||||
used for changes in backward compatibility, as it is intended. The
|
||||
PNG_PNGLIB_VER macro, which is not used within libpng but is available
|
||||
for applications, is an unsigned integer of the form xyyzz corresponding
|
||||
to the source version x.y.z (leading zeros in y and z). Beta versions
|
||||
are given the previous public release number plus a letter or two.
|
||||
Henceforth the source version will match the shared-library minor
|
||||
and patch numbers; the shared-library major version number will be
|
||||
used for changes in backward compatibility, as it is intended. The
|
||||
PNG_PNGLIB_VER macro, which is not used within libpng but is available
|
||||
for applications, is an unsigned integer of the form xyyzz corresponding
|
||||
to the source version x.y.z (leading zeros in y and z). Beta versions
|
||||
are given the previous public release number plus a letter or two.
|
||||
|
||||
.SH "SEE ALSO"
|
||||
libpngpf(3), png(5)
|
||||
@@ -3576,7 +3632,7 @@ possible without all of you.
|
||||
|
||||
Thanks to Frank J. T. Wojcik for helping with the documentation.
|
||||
|
||||
Libpng version 1.0.9 - January 31, 2001:
|
||||
Libpng version 1.0.10beta1 - March 14, 2001:
|
||||
Initially created in 1995 by Guy Eric Schalnat, then of Group 42, Inc.
|
||||
Currently maintained by Glenn Randers-Pehrson (randeg@alum.rpi.edu).
|
||||
|
||||
@@ -3593,8 +3649,8 @@ included in the libpng distribution, the latter shall prevail.)
|
||||
If you modify libpng you may insert additional notices immediately following
|
||||
this sentence.
|
||||
|
||||
libpng versions 1.0.7, July 1, 2000, through 1.0.9, January 31, 2001, are
|
||||
Copyright (c) 2000 Glenn Randers-Pehrson, and are
|
||||
libpng versions 1.0.7, July 1, 2000, through 1.0.10beta1, March 14, 2001, are
|
||||
Copyright (c) 2000-2001 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
|
||||
|
||||
@@ -3604,12 +3660,13 @@ with the following individuals added to the list of Contributing Authors
|
||||
|
||||
and with the following additions to the disclaimer:
|
||||
|
||||
There is no warranty against interference with your enjoyment of the
|
||||
library or against infringement. There is no warranty that our
|
||||
efforts or the library will fulfill any of your particular purposes
|
||||
or needs. This library is provided with all faults, and the entire
|
||||
risk of satisfactory quality, performance, accuracy, and effort is with
|
||||
the user.
|
||||
There is no warranty against interference with your
|
||||
enjoyment of the library or against infringement.
|
||||
There is no warranty that our efforts or the library
|
||||
will fulfill any of your particular purposes or needs.
|
||||
This library is provided with all faults, and the entire
|
||||
risk of satisfactory quality, performance, accuracy, and
|
||||
effort is with the user.
|
||||
|
||||
libpng versions 0.97, January 1998, through 1.0.6, March 20, 2000, are
|
||||
Copyright (c) 1998, 1999 Glenn Randers-Pehrson
|
||||
@@ -3658,11 +3715,11 @@ to the following restrictions:
|
||||
|
||||
1. The origin of this source code must not be misrepresented.
|
||||
|
||||
2. Altered versions must be plainly marked as such and must not
|
||||
be misrepresented as being the original source.
|
||||
2. Altered versions must be plainly marked as such and
|
||||
must not be misrepresented as being the original source.
|
||||
|
||||
3. This Copyright notice may not be removed or altered from any
|
||||
source or altered source distribution.
|
||||
3. This Copyright notice may not be removed or altered from
|
||||
any source or altered source distribution.
|
||||
|
||||
The Contributing Authors and Group 42, Inc. specifically permit, without
|
||||
fee, and encourage the use of this source code as a component to
|
||||
@@ -3684,7 +3741,7 @@ certification mark of the Open Source Initiative.
|
||||
|
||||
Glenn Randers-Pehrson
|
||||
randeg@alum.rpi.edu
|
||||
January 31, 2001
|
||||
March 14, 2001
|
||||
|
||||
.\" end of man page
|
||||
|
||||
|
||||
Reference in New Issue
Block a user