[devel] Changed several "#ifdef PNG_UNKNOWN_CHUNK_SUPPORTED" to

to "#ifdef PNG_HANDLE_AS_UNKNOWN_SUPPORTED", to make the png_set_keep
    mechanism available for ignoring known chunks even when not saving
    unknown chunks.
This commit is contained in:
Glenn Randers-Pehrson
2009-06-13 10:05:05 -05:00
parent b5444a1779
commit 7824a70c1d
7 changed files with 67 additions and 51 deletions

View File

@@ -1,7 +1,7 @@
/* pngconf.h - machine configurable file for libpng
*
* libpng version 1.4.0beta63 - June 5, 2009
* libpng version 1.4.0beta63 - June 12, 2009
* For conditions of distribution and use, see copyright notice in png.h
* Copyright (c) 1998-2009 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
@@ -32,7 +32,7 @@
/*
* Added at libpng-1.2.8
*
*
* PNG_USER_CONFIG has to be defined on the compiler command line. This
* includes the resource compiler for Windows DLL configurations.
*/
@@ -48,7 +48,7 @@
# define PNG_CALLOC_SUPPORTED
#endif
/*
/*
* If you create a private DLL you need to define in "pngusr.h" the followings:
* #define PNG_USER_PRIVATEBUILD <Describes by whom and why this version of
* the DLL was built>
@@ -59,8 +59,8 @@
* number and must match your private DLL name>
* e.g. // private DLL "libpng13gx.dll"
* #define PNG_USER_DLLFNAME_POSTFIX "gx"
*
* The following macros are also at your disposal if you want to complete the
*
* The following macros are also at your disposal if you want to complete the
* DLL VERSIONINFO structure.
* - PNG_USER_VERSIONINFO_COMMENTS
* - PNG_USER_VERSIONINFO_COMPANYNAME
@@ -159,9 +159,9 @@
* 'Cygwin' defines/defaults:
* PNG_BUILD_DLL -- (ignored) building the dll
* (no define) -- (ignored) building an application, linking to the dll
* PNG_STATIC -- (ignored) building the static lib, or building an
* PNG_STATIC -- (ignored) building the static lib, or building an
* application that links to the static lib.
* ALL_STATIC -- (ignored) building various static libs, or building an
* ALL_STATIC -- (ignored) building various static libs, or building an
* application that links to the static libs.
* Thus,
* a cygwin user should define either PNG_BUILD_DLL or PNG_STATIC, and
@@ -174,12 +174,12 @@
* PNG_BUILD_DLL
* PNG_STATIC
* (nothing) == PNG_USE_DLL
*
*
* CYGWIN (2002-01-20): The preceding is now obsolete. With the advent
* of auto-import in binutils, we no longer need to worry about
* of auto-import in binutils, we no longer need to worry about
* __declspec(dllexport) / __declspec(dllimport) and friends. Therefore,
* we don't need to worry about PNG_STATIC or ALL_STATIC when it comes
* to __declspec() stuff. However, we DO need to worry about
* to __declspec() stuff. However, we DO need to worry about
* PNG_BUILD_DLL and PNG_STATIC because those change some defaults
* such as CONSOLE_IO and whether GLOBAL_ARRAYS are allowed.
*/
@@ -223,8 +223,8 @@
# if !defined(PNG_DLL)
# define PNG_DLL
# endif
# endif
# endif
# endif
# endif
# endif
#endif
@@ -853,9 +853,6 @@
# ifndef PNG_UNKNOWN_CHUNKS_SUPPORTED
# define PNG_UNKNOWN_CHUNKS_SUPPORTED
# endif
# ifndef PNG_NO_HANDLE_AS_UNKNOWN
# define PNG_HANDLE_AS_UNKNOWN_SUPPORTED
# endif
#endif
#if !defined(PNG_NO_READ_USER_CHUNKS) && \
defined(PNG_READ_UNKNOWN_CHUNKS_SUPPORTED)
@@ -868,6 +865,11 @@
# undef PNG_NO_HANDLE_AS_UNKNOWN
# endif
#endif
#ifndef PNG_NO_HANDLE_AS_UNKNOWN
# ifndef PNG_HANDLE_AS_UNKNOWN_SUPPORTED
# define PNG_HANDLE_AS_UNKNOWN_SUPPORTED
# endif
#endif
#ifndef PNG_NO_READ_OPT_PLTE
# define PNG_READ_OPT_PLTE_SUPPORTED /* only affects support of the */
#endif /* optional PLTE chunk in RGB and RGBA images */
@@ -995,10 +997,10 @@
# ifndef PNG_UNKNOWN_CHUNKS_SUPPORTED
# define PNG_UNKNOWN_CHUNKS_SUPPORTED
# endif
# ifndef PNG_NO_HANDLE_AS_UNKNOWN
# ifndef PNG_HANDLE_AS_UNKNOWN_SUPPORTED
# define PNG_HANDLE_AS_UNKNOWN_SUPPORTED
# endif
#endif
#ifndef PNG_NO_HANDLE_AS_UNKNOWN
# ifndef PNG_HANDLE_AS_UNKNOWN_SUPPORTED
# define PNG_HANDLE_AS_UNKNOWN_SUPPORTED
# endif
#endif
#if defined(PNG_WRITE_iTXt_SUPPORTED) || defined(PNG_WRITE_tEXt_SUPPORTED) || \
@@ -1217,7 +1219,7 @@ typedef char FAR * FAR * FAR * png_charppp;
# define PNGAPI __cdecl
# undef PNG_IMPEXP
# define PNG_IMPEXP
#endif
#endif
/* If you define PNGAPI, e.g., with compiler option "-DPNGAPI=__stdcall",
* you may get warnings regarding the linkage of png_zalloc and png_zfree.