mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[libpng16] Bump version to 1.6.1beta05
This commit is contained in:
401
scripts/pnglibconf.dfa
Normal file → Executable file
401
scripts/pnglibconf.dfa
Normal file → Executable file
@@ -8,7 +8,7 @@ com pnglibconf.h - library build configuration
|
||||
com
|
||||
version
|
||||
com
|
||||
com Copyright (c) 1998-2011 Glenn Randers-Pehrson
|
||||
com Copyright (c) 1998-2012 Glenn Randers-Pehrson
|
||||
com
|
||||
com This code is released under the libpng license.
|
||||
com For conditions of distribution and use, see the disclaimer
|
||||
@@ -21,19 +21,28 @@ file pnglibconf.h scripts/pnglibconf.dfa PNGLCONF_H
|
||||
# C compiler to generate 'pnglibconf.h' - a list of all the
|
||||
# configuration options. The file lists the various options
|
||||
# that can *only* be specified during the libpng build;
|
||||
# pnglibconf.h freezes the definitons selected for the specific
|
||||
# pnglibconf.h freezes the definitions selected for the specific
|
||||
# build.
|
||||
#
|
||||
# The syntax is detailed in scripts/options.awk, this is a summary
|
||||
# The syntax is detailed in scripts/options.awk; this is a summary
|
||||
# only:
|
||||
#
|
||||
# setting <name> [requires ...] [default]
|
||||
# setting <name> [default]
|
||||
# #define PNG_<name> <value> /* value comes from current setting */
|
||||
# option <name> [requires ...] [if ...] [enables ...] [disabled]
|
||||
# #define PNG_<name>_SUPPORTED if the requirements are met and
|
||||
# enable the other options listed
|
||||
# chunk <name> [requires ...] [disabled]
|
||||
# Enable chunk processing for the given ancillary chunk
|
||||
# chunk <name> [requires ...] [enables ...] [disabled]
|
||||
# Enable chunk processing for the given ancillary chunk; any
|
||||
# 'requires something' expands to READ_something for read and
|
||||
# WRITE_something for write, but the enables list members are
|
||||
# used as given (e.g. enables GAMMA just expands to that on the
|
||||
# correspond READ_name and WRITE_name lines.)
|
||||
#
|
||||
# "," may be used to separate options on an 'option' line and is ignored; it
|
||||
# doesn't change the meaning of the line. (NOT setting, where "," becomes
|
||||
# part of the setting!) A comma at the end of an option line causes a
|
||||
# continuation (the next line is included in the option too.)
|
||||
#
|
||||
# Note that the 'on' and 'off' keywords, while valid on both option
|
||||
# and chunk, should not be used in this file because they force the
|
||||
@@ -44,7 +53,7 @@ file pnglibconf.h scripts/pnglibconf.dfa PNGLCONF_H
|
||||
# The following setting, option and chunk values can all be changed
|
||||
# while building libpng:
|
||||
#
|
||||
# setting: change 'setting' lines to fine tune library performance,
|
||||
# setting: change 'setting' lines to fine tune library performance;
|
||||
# changes to the settings don't affect the libpng API functionally
|
||||
#
|
||||
# option: change 'option' lines to remove or add capabilities from
|
||||
@@ -127,6 +136,12 @@ logunsupported = 1
|
||||
# - PNG_USER_VERSIONINFO_COMPANYNAME
|
||||
# - PNG_USER_VERSIONINFO_LEGALTRADEMARKS
|
||||
|
||||
# It is necessary to include configures definitions here so that AC_DEFINE
|
||||
# in configure.ac works in a comprehensible way
|
||||
@#if defined(HAVE_CONFIG_H) && !defined(PNG_NO_CONFIG_H)
|
||||
@# include "config.h"
|
||||
@#endif
|
||||
|
||||
@#ifdef PNG_USER_CONFIG
|
||||
@# include "pngusr.h"
|
||||
@#endif
|
||||
@@ -143,6 +158,12 @@ logunsupported = 1
|
||||
@# endif
|
||||
@#endif
|
||||
|
||||
# IN DEVELOPMENT
|
||||
# These are currently experimental features; define them if you want (NOTE:
|
||||
# experimental options must be disabled before they are defined in this file!)
|
||||
|
||||
# NONE
|
||||
|
||||
# Note that PNG_USR_CONFIG only has an effect when building
|
||||
# pnglibconf.h
|
||||
|
||||
@@ -161,10 +182,49 @@ setting USER_VERSIONINFO_LEGALTRADEMARKS
|
||||
|
||||
setting API_RULE default 0
|
||||
|
||||
# This allows a prefix to be added to the front of every API functon name (and
|
||||
# therefore every symbol) by redefining all the function names with the prefix
|
||||
# at the end of pnglibconf.h. It also turns on similar internal symbol renaming
|
||||
# by causing a similar build-time only file, pngprefix.h, to be generated.
|
||||
|
||||
setting PREFIX
|
||||
|
||||
# Default to using the read macros
|
||||
|
||||
setting DEFAULT_READ_MACROS default 1
|
||||
|
||||
# This setting allows a hardware or configuration specific filter optimization
|
||||
# function to be specified, the argument is the name of the filter initializaion
|
||||
# function to use.
|
||||
|
||||
setting FILTER_OPTIMIZATIONS
|
||||
|
||||
# This option turns on runtime checks for ARM NEON support, it is irrelevant
|
||||
# on other platforms and it is irrelevant unless NEON code is turned on. Checks
|
||||
# are on by default
|
||||
|
||||
option ARM_NEON_CHECK
|
||||
|
||||
# These settings configure the default compression level (0-9) and 'strategy';
|
||||
# strategy is as defined by the implementors of zlib, it describes the input
|
||||
# data and modifies the zlib parameters in an attempt to optimize the balance
|
||||
# between search and huffman encoding in the zlib algorithms. The defaults are
|
||||
# the zlib.h defaults - the apparently recursive definition does not arise
|
||||
# because the name of the setting is prefixed by PNG_
|
||||
#
|
||||
# The TEXT values are the defaults when writing compressed text (all forms)
|
||||
#
|
||||
# Include the zlib header too, so that the defaults below are known
|
||||
@# include <zlib.h>
|
||||
|
||||
# The '@' here means to substitute the value when pnglibconf.h is built
|
||||
setting Z_DEFAULT_COMPRESSION default @Z_DEFAULT_COMPRESSION
|
||||
setting Z_DEFAULT_STRATEGY default @Z_FILTERED
|
||||
setting Z_DEFAULT_NOFILTER_STRATEGY default @Z_DEFAULT_STRATEGY
|
||||
|
||||
setting TEXT_Z_DEFAULT_COMPRESSION default @Z_DEFAULT_COMPRESSION
|
||||
setting TEXT_Z_DEFAULT_STRATEGY default @Z_DEFAULT_STRATEGY
|
||||
|
||||
# The alternative is to call functions to read PNG values, if
|
||||
# the functions are turned *off* the read macros must always
|
||||
# be enabled, so turning this off will actually force the
|
||||
@@ -179,10 +239,36 @@ option READ_INT_FUNCTIONS requires READ
|
||||
option WRITE_INT_FUNCTIONS disabled
|
||||
option WRITE enables WRITE_INT_FUNCTIONS
|
||||
|
||||
# Generic options - affect both read and write.
|
||||
# Error controls
|
||||
#
|
||||
# WARNINGS: normally on, if off no warnings are generated
|
||||
# ERROR_TEXT: normally on, if off errors happen but there is no message
|
||||
# ERROR_NUMBERS: unimplemented feature, therefore disabled
|
||||
# BENIGN_ERRORS: support for just issuing warnings for recoverable errors
|
||||
#
|
||||
# BENIGN_READ_ERRORS:
|
||||
# By default recoverable errors on read should just generate warnings,
|
||||
# generally safe but PNG files that don't conform to the specification will
|
||||
# be accepted if a meaningful result can be produced.
|
||||
#
|
||||
# BENIGN_WRITE_ERRORS:
|
||||
# By default recoverable errors on write should just generate warnings,
|
||||
# not generally safe because this allows the application to write invalid
|
||||
# PNG files. Applications should enable this themselves; it's useful
|
||||
# because it means that a failure to write an ancilliary chunk can often be
|
||||
# ignored.
|
||||
|
||||
option WARNINGS
|
||||
option ERROR_TEXT
|
||||
option ERROR_NUMBERS disabled
|
||||
|
||||
option BENIGN_ERRORS
|
||||
option BENIGN_WRITE_ERRORS requires BENIGN_ERRORS disabled
|
||||
option BENIGN_READ_ERRORS requires BENIGN_ERRORS
|
||||
|
||||
|
||||
# Generic options - affect both read and write.
|
||||
|
||||
option MNG_FEATURES
|
||||
|
||||
# Arithmetic options, the first is the big switch that chooses between internal
|
||||
@@ -193,10 +279,6 @@ option FLOATING_ARITHMETIC
|
||||
option FLOATING_POINT enables ok_math
|
||||
option FIXED_POINT enables ok_math
|
||||
|
||||
# Added at libpng version 1.4.0
|
||||
|
||||
option ERROR_TEXT
|
||||
|
||||
# The following is always on (defined empty)
|
||||
|
||||
setting CALLOC_SUPPORTED default
|
||||
@@ -223,10 +305,6 @@ option TIME_RFC1123
|
||||
option SETJMP
|
||||
= NO_SETJMP SETJMP_NOT_SUPPORTED
|
||||
|
||||
# For the moment this is disabled (no code support):
|
||||
|
||||
option ERROR_NUMBERS disabled
|
||||
|
||||
# If this is disabled it is not possible for apps to get the
|
||||
# values from the 'info' structure, this effectively removes
|
||||
# quite a lot of the READ API.
|
||||
@@ -266,20 +344,22 @@ option SET_USER_LIMITS enables SET_CHUNK_CACHE_LIMIT
|
||||
|
||||
option SET_USER_LIMITS enables SET_CHUNK_MALLOC_LIMIT
|
||||
|
||||
# Added at libpng-1.0.16 and 1.2.6. To accept all valid PNGs no matter
|
||||
# how large, set these two limits to 0x7fffffff
|
||||
# Libpng limits.
|
||||
#
|
||||
# If these settings are *not* set libpng will not limit the size of
|
||||
# images or the size of data in ancilliary chunks. This does lead to
|
||||
# security issues if PNG files come from untrusted sources.
|
||||
setting USER_WIDTH_MAX
|
||||
setting USER_HEIGHT_MAX
|
||||
setting USER_CHUNK_CACHE_MAX
|
||||
setting USER_CHUNK_MALLOC_MAX
|
||||
|
||||
setting USER_WIDTH_MAX default 1000000
|
||||
setting USER_HEIGHT_MAX default 1000000
|
||||
|
||||
# Added at libpng-1.2.43. To accept all valid PNGs no matter
|
||||
# how large, set these two limits to 0.
|
||||
|
||||
setting USER_CHUNK_CACHE_MAX default 0
|
||||
|
||||
# Added at libpng-1.2.43
|
||||
|
||||
setting USER_CHUNK_MALLOC_MAX default 0
|
||||
# To default all these settings to values that are large but probably
|
||||
# safe turn the SAFE_LIMITS option on; this will cause the value in
|
||||
# pngpriv.h to be used. Individual values can also be set, simply set
|
||||
# them in pngusr.dfa with '@#define PNG_setting value' lines.
|
||||
option SAFE_LIMITS enables USER_LIMITS disabled
|
||||
= SAFE_LIMITS SAFE_LIMITS
|
||||
|
||||
# All of the following options relate to code capabilities for
|
||||
# processing image data before creating a PNG or after reading one.
|
||||
@@ -288,6 +368,19 @@ setting USER_CHUNK_MALLOC_MAX default 0
|
||||
# See the comments above about how to change options and settings.
|
||||
|
||||
# READ options
|
||||
#
|
||||
# WARNING: in libpng 1.5 maintained configuration compatibility with earlier
|
||||
# versions. In some cases turning off an option turned off other options, in
|
||||
# others it was ineffective unless dependent options were also turned off.
|
||||
# Libpng 1.6 changes this: in general if you turn off an option that affects
|
||||
# APIs it stays off and simply disables APIs that depend on it.
|
||||
#
|
||||
# As a result if you simply port the libpng 1.5 configuration to libpng 1.6 you
|
||||
# will probably see build failures due to missing APIs. Fixing these failures
|
||||
# requires some, perhaps considerable, knowledge of what your libpng using
|
||||
# applications are doing, fortunately there is no great reason for you to move
|
||||
# to libpng 1.6; the new interfaces in 1.6 will take several years to become
|
||||
# popular.
|
||||
|
||||
option READ enables READ_INTERLACING
|
||||
|
||||
@@ -305,27 +398,42 @@ option READ_QUANTIZE requires READ
|
||||
option READ_TRANSFORMS requires READ
|
||||
= NO_READ_TRANSFORMS READ_TRANSFORMS_NOT_SUPPORTED
|
||||
|
||||
option READ_EXPAND requires READ_TRANSFORMS
|
||||
option READ_EXPAND_16 requires READ_TRANSFORMS READ_16BIT enables READ_EXPAND
|
||||
option READ_SHIFT requires READ_TRANSFORMS
|
||||
option READ_PACK requires READ_TRANSFORMS
|
||||
option READ_BGR requires READ_TRANSFORMS
|
||||
option READ_SWAP requires READ_TRANSFORMS READ_16BIT
|
||||
option READ_PACKSWAP requires READ_TRANSFORMS
|
||||
option READ_INVERT requires READ_TRANSFORMS
|
||||
option READ_BACKGROUND requires READ_TRANSFORMS enables READ_STRIP_ALPHA
|
||||
option READ_STRIP_16_TO_8 requires READ_TRANSFORMS
|
||||
option READ_SCALE_16_TO_8 requires READ_TRANSFORMS
|
||||
option READ_FILLER requires READ_TRANSFORMS
|
||||
option READ_GAMMA requires READ_TRANSFORMS enables READ_gAMA
|
||||
option READ_GRAY_TO_RGB requires READ_TRANSFORMS
|
||||
# Read gamma handling. Gamma processing is a core part of libpng and many of
|
||||
# the capabilities are dependent on libpng performing gamma correction.
|
||||
#
|
||||
# In libpng 1.6 disabling gamma processing (setting PNG_NO_READ_GAMMA)
|
||||
# consistently disables those parts of the API that depend on it. Prior to
|
||||
# 1.6.0 this was not true; the results were unpredictable and varied between
|
||||
# releases.
|
||||
#
|
||||
# If you disable gamma processing and your program no longer compiles you need
|
||||
# to ask whether you really need the APIs that are missing. If you do then you
|
||||
# almost certainly need the gamma processing.
|
||||
#
|
||||
# If you handle gamma issues outside libpng then you do not need the libpng
|
||||
# gamma processing; and it is an enormous waste of space. You just need to
|
||||
# remove the use of libpng APIs that depend on it.
|
||||
option READ_GAMMA requires READ_TRANSFORMS, READ_gAMA
|
||||
|
||||
option READ_ALPHA_MODE requires READ_TRANSFORMS enables READ_GAMMA
|
||||
option READ_SWAP_ALPHA requires READ_TRANSFORMS
|
||||
option READ_ALPHA_MODE requires READ_TRANSFORMS, READ_GAMMA
|
||||
option READ_BACKGROUND requires READ_TRANSFORMS, READ_STRIP_ALPHA, READ_GAMMA
|
||||
option READ_BGR requires READ_TRANSFORMS
|
||||
option READ_EXPAND_16 requires READ_TRANSFORMS, READ_16BIT, READ_EXPAND
|
||||
option READ_EXPAND requires READ_TRANSFORMS
|
||||
option READ_FILLER requires READ_TRANSFORMS
|
||||
option READ_GRAY_TO_RGB requires READ_TRANSFORMS
|
||||
option READ_INVERT_ALPHA requires READ_TRANSFORMS
|
||||
option READ_INVERT requires READ_TRANSFORMS
|
||||
option READ_PACK requires READ_TRANSFORMS
|
||||
option READ_PACKSWAP requires READ_TRANSFORMS
|
||||
option READ_RGB_TO_GRAY requires READ_TRANSFORMS, READ_GAMMA
|
||||
option READ_SCALE_16_TO_8 requires READ_TRANSFORMS
|
||||
option READ_SHIFT requires READ_TRANSFORMS
|
||||
option READ_STRIP_16_TO_8 requires READ_TRANSFORMS
|
||||
option READ_STRIP_ALPHA requires READ_TRANSFORMS
|
||||
option READ_SWAP_ALPHA requires READ_TRANSFORMS
|
||||
option READ_SWAP requires READ_TRANSFORMS, READ_16BIT
|
||||
option READ_USER_TRANSFORM requires READ_TRANSFORMS
|
||||
option READ_RGB_TO_GRAY requires READ_TRANSFORMS
|
||||
|
||||
option PROGRESSIVE_READ requires READ
|
||||
option SEQUENTIAL_READ requires READ
|
||||
@@ -349,11 +457,6 @@ option INCH_CONVERSIONS
|
||||
|
||||
option BUILD_GRAYSCALE_PALETTE
|
||||
|
||||
# IN DEVELOPMENT
|
||||
# These are currently experimental features; define them if you want
|
||||
|
||||
# NOTHING HERE
|
||||
|
||||
# WRITE options
|
||||
|
||||
option WRITE
|
||||
@@ -368,7 +471,7 @@ option WRITE_TRANSFORMS requires WRITE
|
||||
option WRITE_SHIFT requires WRITE_TRANSFORMS
|
||||
option WRITE_PACK requires WRITE_TRANSFORMS
|
||||
option WRITE_BGR requires WRITE_TRANSFORMS
|
||||
option WRITE_SWAP requires WRITE_TRANSFORMS WRITE_16BIT
|
||||
option WRITE_SWAP requires WRITE_TRANSFORMS, WRITE_16BIT
|
||||
option WRITE_PACKSWAP requires WRITE_TRANSFORMS
|
||||
option WRITE_INVERT requires WRITE_TRANSFORMS
|
||||
option WRITE_FILLER requires WRITE_TRANSFORMS
|
||||
@@ -390,8 +493,8 @@ option WRITE_FLUSH requires WRITE
|
||||
|
||||
# Note: these can be turned off explicitly if not required by the
|
||||
# apps implementing the user transforms
|
||||
option USER_TRANSFORM_PTR if READ_USER_TRANSFORM WRITE_USER_TRANSFORM
|
||||
option USER_TRANSFORM_INFO if READ_USER_TRANSFORM WRITE_USER_TRANSFORM
|
||||
option USER_TRANSFORM_PTR if READ_USER_TRANSFORM, WRITE_USER_TRANSFORM
|
||||
option USER_TRANSFORM_INFO if READ_USER_TRANSFORM, WRITE_USER_TRANSFORM
|
||||
|
||||
# This enables API to set compression parameters for compressing
|
||||
# non-IDAT chunks (zTXt, iTXt, iCCP, and unknown chunks). This feature
|
||||
@@ -434,17 +537,65 @@ option WRITE_TEXT requires WRITE_ANCILLARY_CHUNKS enables TEXT
|
||||
# API is implemented, they get recorded in pnglibconf.h, but
|
||||
# can't be changed by the application.
|
||||
|
||||
# Check the correctness of cHRM chunks
|
||||
|
||||
option CHECK_cHRM requires cHRM
|
||||
|
||||
# Colorspace support (enabled as required); just the support for colorant
|
||||
# information. Gamma support, likewise, is just support for the gamma
|
||||
# information, READ_GAMMA is required for gamma transformations (so it
|
||||
# is possible to read PNG gamma without enabling all the libpng transform
|
||||
# code - do this for applications that do their own gamma processing)
|
||||
#
|
||||
# As of 1.6.0 COLORSPACE is only useful if the application processes the
|
||||
# information; this is because the library does not do any colorspace
|
||||
# processing, it just validates the data in the PNG file.
|
||||
|
||||
option GAMMA disabled
|
||||
option COLORSPACE enables GAMMA disabled
|
||||
|
||||
# When an ICC profile is read, or png_set, it will be checked for a match
|
||||
# against known sRGB profiles if the sRGB handling is enabled. This
|
||||
# setting controls how much work is done during the check:
|
||||
#
|
||||
# 0: Just validate the profile MD5 signature if present, otherwise use
|
||||
# the checks in option 1.
|
||||
#
|
||||
# 1: Additionally check the length, intent and adler32 checksum of the
|
||||
# actual data. If enabled this will reject known profiles that have
|
||||
# had the rendering intent in the header changed as well as other edits
|
||||
# done without updating the checksum. See the discussion below.
|
||||
#
|
||||
# 2: Additionally checksum all the data using the ethernet CRC32 algorithm.
|
||||
# This makes it more difficult to fake profiles and makes it less likely
|
||||
# to get a false positive on profiles with no signature, but is probably
|
||||
# just a waste of time since all currently approved ICC sRGB profiles have
|
||||
# a secure MD5 signature.
|
||||
#
|
||||
# The rendering intent. An ICC profile stores an intended rendering intent,
|
||||
# but does not include the value in the signature. The intent is documented
|
||||
# as the intent that should be used when combining two profiles. The sRGB
|
||||
# profile is intended, however, to be used with any of the four defined intents.
|
||||
# For this reason the sRGB chunk includes an 'intent' to be used when displaying
|
||||
# the image (intent is really a property of the image not the profile.)
|
||||
#
|
||||
# Unfortunately the iCCP chunk does not. It may therefore be that some
|
||||
# applications modify the intent in profiles (including sRGB profiles) to work
|
||||
# round this problem. Selecting an option other than option '0' will cause such
|
||||
# modified profiles to be rejected.
|
||||
#
|
||||
# Security. The use of Adler32 and CRC32 checksums does not help significantly
|
||||
# with any security issues. It is relatively easy to produce arbitrary profiles
|
||||
# with the required checksums on current computer systems. Nevertheless
|
||||
# security does not seem to be an issue because the only consequence of a false
|
||||
# positive is a false assertion that the profile is an sRGB profile. This might
|
||||
# be used to hide data from libpng using applications, but it doesn't seem
|
||||
# possible to damage them.
|
||||
|
||||
setting sRGB_PROFILE_CHECKS default 2
|
||||
|
||||
# Artificially align memory - the code typically aligns to 8 byte
|
||||
# boundaries if this is switched on, it's a small waste of space
|
||||
# but can help (in theory) on some architectures. Only affects
|
||||
# internal structures. Added at libpng 1.4.0
|
||||
|
||||
option ALIGN_MEMORY
|
||||
option ALIGNED_MEMORY
|
||||
|
||||
# Buggy compilers (e.g., gcc 2.7.2.2) need PNG_NO_POINTER_INDEXING
|
||||
# See png[wr]util.c, normally this should always be *on*
|
||||
@@ -507,20 +658,44 @@ setting sCAL_PRECISION default 5
|
||||
|
||||
setting ZBUF_SIZE default 8192
|
||||
|
||||
# This is the size of the decompression buffer used when counting or checking
|
||||
# the decompressed size of an LZ stream from a compressed ancilliary chunk; the
|
||||
# decompressed data is never used so a different size may be optimal. This size
|
||||
# was determined using contrib/libtests/timepng.c with compressed zTXt data
|
||||
# around 11MByte in size. Slight speed improvements (up to about 14% in
|
||||
# timepng) can be achieved by very large increases (to 32kbyte) on regular data,
|
||||
# but highly compressible data shows only around 2% improvement. The size is
|
||||
# chosen to minimize the effects of DoS attacks based on using very large
|
||||
# amounts of highly compressible data.
|
||||
|
||||
setting INFLATE_BUF_SIZE default 1024
|
||||
|
||||
# This is the maximum amount of IDAT data that the sequential reader will
|
||||
# process at one time. The setting does not affect the size of IDAT chunks
|
||||
# read, just the amount read at once. Neither does it affect the progressive
|
||||
# reader, which processes just the amount of data the application gives it.
|
||||
# The sequential reader is currently unable to process more than one IDAT at
|
||||
# once - it has to read and process each one in turn. There is no point setting
|
||||
# this to a value larger than the IDAT chunks typically encountered (it would
|
||||
# just waste memory) but there may be some point in reducing it below the value
|
||||
# of ZBUF_SIZE (the size of IDAT chunks written by libpng.)
|
||||
|
||||
setting IDAT_READ_SIZE default PNG_ZBUF_SIZE
|
||||
|
||||
# Ancillary chunks
|
||||
chunk bKGD
|
||||
chunk cHRM
|
||||
chunk gAMA
|
||||
chunk cHRM enables COLORSPACE
|
||||
chunk gAMA enables GAMMA
|
||||
chunk hIST
|
||||
chunk iCCP
|
||||
chunk iCCP enables COLORSPACE, GAMMA
|
||||
chunk iTXt
|
||||
chunk oFFs
|
||||
chunk pCAL
|
||||
chunk sCAL
|
||||
chunk pHYs
|
||||
chunk sBIT
|
||||
chunk sCAL
|
||||
chunk sPLT
|
||||
chunk sRGB
|
||||
chunk sRGB enables COLORSPACE, GAMMA
|
||||
chunk tEXt requires TEXT
|
||||
chunk tIME
|
||||
chunk tRNS
|
||||
@@ -532,9 +707,55 @@ chunk zTXt
|
||||
|
||||
option READ_OPT_PLTE requires READ_ANCILLARY_CHUNKS
|
||||
|
||||
option READ_UNKNOWN_CHUNKS requires READ
|
||||
option READ_UNKNOWN_CHUNKS enables UNKNOWN_CHUNKS READ_USER_CHUNKS
|
||||
option READ_USER_CHUNKS requires READ enables USER_CHUNKS
|
||||
# Unknown chunk handling
|
||||
#
|
||||
# 'UNKNOWN_CHUNKS' is a global option to disable all unknown chunk handling on
|
||||
# read or write; everything else below requires it (directly or indirectly).
|
||||
option UNKNOWN_CHUNKS
|
||||
|
||||
# There are three main options to control the ability to read and write unknown
|
||||
# chunks. If either read option is turned on then unknown chunks will be read,
|
||||
# otherwise they are skipped. If the write option is turned on unknown chunks
|
||||
# set by png_set_unknown_chunks will be written otherwise it is an error to call
|
||||
# that API on a write struct.
|
||||
option WRITE_UNKNOWN_CHUNKS requires WRITE requires UNKNOWN_CHUNKS
|
||||
option WRITE_UNKNOWN_CHUNKS enables STORE_UNKNOWN_CHUNKS
|
||||
|
||||
# The first way to read user chunks is to have libpng save them for a later call
|
||||
# to png_get_unknown_chunks, the application must call
|
||||
# png_set_keep_unknown_chunks to cause this to actually happen (see png.h)
|
||||
option SAVE_UNKNOWN_CHUNKS requires READ requires SET_UNKNOWN_CHUNKS
|
||||
option SAVE_UNKNOWN_CHUNKS enables READ_UNKNOWN_CHUNKS, STORE_UNKNOWN_CHUNKS
|
||||
|
||||
# The second approach is to use an application provided callback to process the
|
||||
# chunks, the callback can either handle the chunk entirely itself or request
|
||||
# that libpng store the chunk for later retrieval via png_get_unknown_chunks.
|
||||
#
|
||||
# Note that there is no 'WRITE_USER_CHUNKS' so the USER_CHUNKS option is always
|
||||
# the same as READ_USER_CHUNKS at present
|
||||
option READ_USER_CHUNKS requires READ, UNKNOWN_CHUNKS
|
||||
option READ_USER_CHUNKS enables READ_UNKNOWN_CHUNKS, USER_CHUNKS
|
||||
|
||||
# Two further options are provided to allow detailed control of the handling.
|
||||
# The first enables png_set_keep_unknown_chunks; this allows the default to be
|
||||
# changed from discarding unknown chunks and allows per-chunk control. This is
|
||||
# required to use the SAVE_UNKNOWN_CHUNKS option. If enabled this option also
|
||||
# applies to write (see png.h), otherwise the write API simply writes all the
|
||||
# chunks it is given.
|
||||
#
|
||||
# The second option extends the unknown handling to allow known chunks to be
|
||||
# handled as though they were unknown. This option doesn't change any APIs, it
|
||||
# merely turns on the code to check known as well as unknown chunks.
|
||||
#
|
||||
# This option no longer affects the write code. It can be safely disabled and
|
||||
# will prevent applications stopping libpng reading known chunks.
|
||||
option SET_UNKNOWN_CHUNKS requires UNKNOWN_CHUNKS
|
||||
option HANDLE_AS_UNKNOWN requires SET_UNKNOWN_CHUNKS
|
||||
|
||||
# The following options are derived from the above and should not be turned on
|
||||
# explicitly.
|
||||
option READ_UNKNOWN_CHUNKS requires UNKNOWN_CHUNKS disabled
|
||||
option STORE_UNKNOWN_CHUNKS requires UNKNOWN_CHUNKS disabled
|
||||
|
||||
option CONVERT_tIME requires WRITE_ANCILLARY_CHUNKS
|
||||
# The "tm" structure is not supported on WindowsCE
|
||||
@@ -545,13 +766,10 @@ option CONVERT_tIME requires WRITE_ANCILLARY_CHUNKS
|
||||
|
||||
option WRITE_FILTER requires WRITE
|
||||
|
||||
option WRITE_UNKNOWN_CHUNKS requires WRITE
|
||||
|
||||
option HANDLE_AS_UNKNOWN
|
||||
|
||||
option SAVE_INT_32 requires WRITE
|
||||
|
||||
# png_save_int_32 is required by the ancillary chunks oFFs and pCAL
|
||||
option SAVE_INT_32 disabled
|
||||
# png_save_int_32 is required internally for writing the ancillary chunks oFFs
|
||||
# and pCAL and for both reading and writing iCCP (for the generation/checking of
|
||||
# the corresponding cHRM/gAMA chunks) if full ICC is supported.
|
||||
|
||||
# added at libpng-1.5.4
|
||||
|
||||
@@ -577,13 +795,27 @@ option WRITE_COMPRESSED_TEXT enables WRITE_TEXT
|
||||
|
||||
option INFO_IMAGE
|
||||
|
||||
# Simplified API options
|
||||
# added at libpng-1.5.10
|
||||
# Turn this off to disable warning about invalid palette index and
|
||||
# leave the num_palette_max member out of the png structure.
|
||||
|
||||
option CHECK_FOR_INVALID_INDEX enables READ_CHECK_FOR_INVALID_INDEX
|
||||
option CHECK_FOR_INVALID_INDEX enables WRITE_CHECK_FOR_INVALID_INDEX
|
||||
option READ_CHECK_FOR_INVALID_INDEX requires READ, CHECK_FOR_INVALID_INDEX
|
||||
option WRITE_CHECK_FOR_INVALID_INDEX requires WRITE, CHECK_FOR_INVALID_INDEX
|
||||
|
||||
# added at libpng-1.5.15
|
||||
option GET_PALETTE_MAX enables READ_GET_PALETTE_MAX WRITE_GET_PALETTE_MAX
|
||||
option READ_GET_PALETTE_MAX requires READ_CHECK_FOR_INVALID_INDEX disabled
|
||||
option WRITE_GET_PALETTE_MAX requires WRITE_CHECK_FOR_INVALID_INDEX disabled
|
||||
|
||||
# Simplified API options (added at libpng-1.6.0)
|
||||
# Read:
|
||||
option SIMPLIFIED_READ requires SEQUENTIAL_READ READ_TRANSFORMS SETJMP
|
||||
option SIMPLIFIED_READ enables READ_EXPAND READ_16BIT READ_EXPAND_16
|
||||
option SIMPLIFIED_READ enables READ_SCALE_16_TO_8 READ_RGB_TO_GRAY
|
||||
option SIMPLIFIED_READ enables READ_ALPHA_MODE READ_BACKGROUND READ_STRIP_ALPHA
|
||||
option SIMPLIFIED_READ enables READ_FILLER READ_SWAP
|
||||
option SIMPLIFIED_READ,
|
||||
requires SEQUENTIAL_READ READ_TRANSFORMS, SETJMP, BENIGN_ERRORS READ_GAMMA,
|
||||
enables READ_EXPAND, READ_16BIT READ_EXPAND_16, READ_SCALE_16_TO_8,
|
||||
READ_RGB_TO_GRAY, READ_ALPHA_MODE READ_BACKGROUND READ_STRIP_ALPHA,
|
||||
READ_FILLER, READ_SWAP
|
||||
|
||||
option SIMPLIFIED_READ_AFIRST requires SIMPLIFIED_READ disabled
|
||||
option READ_SWAP_ALPHA enables SIMPLIFIED_READ_AFIRST
|
||||
@@ -592,8 +824,9 @@ option SIMPLIFIED_READ_BGR requires SIMPLIFIED_READ disabled
|
||||
option READ_BGR enables SIMPLIFIED_READ_BGR
|
||||
|
||||
# Write:
|
||||
option SIMPLIFIED_WRITE requires WRITE STDIO SETJMP
|
||||
option SIMPLIFIED_WRITE enables WRITE_SWAP WRITE_gAMA WRITE_sRGB WRITE_cHRM
|
||||
option SIMPLIFIED_WRITE,
|
||||
requires WRITE STDIO, SETJMP,
|
||||
enables WRITE_SWAP WRITE_gAMA, WRITE_sRGB WRITE_cHRM
|
||||
|
||||
option SIMPLIFIED_WRITE_AFIRST requires SIMPLIFIED_WRITE disabled
|
||||
option WRITE_SWAP_ALPHA enables SIMPLIFIED_WRITE_AFIRST
|
||||
@@ -602,5 +835,5 @@ option SIMPLIFIED_WRITE_BGR requires SIMPLIFIED_WRITE disabled
|
||||
option WRITE_BGR enables SIMPLIFIED_WRITE_BGR
|
||||
|
||||
# Formats:
|
||||
option FORMAT_AFIRST if SIMPLIFIED_READ_AFIRST SIMPLIFIED_WRITE_AFIRST
|
||||
option FORMAT_BGR if SIMPLIFIED_READ_BGR SIMPLIFIED_WRITE_BGR
|
||||
option FORMAT_AFIRST if SIMPLIFIED_READ_AFIRST, SIMPLIFIED_WRITE_AFIRST
|
||||
option FORMAT_BGR if SIMPLIFIED_READ_BGR, SIMPLIFIED_WRITE_BGR
|
||||
|
||||
Reference in New Issue
Block a user