src/java.desktop/share/native/libsplashscreen/libpng/pngstruct.h
author erikj
Tue, 12 Sep 2017 19:03:39 +0200
changeset 47216 71c04702a3d5
parent 43321 jdk/src/java.desktop/share/native/libsplashscreen/libpng/pngstruct.h@2b8d397c03a4
child 48280 791d551bcdb8
permissions -rw-r--r--
8187443: Forest Consolidation: Move files to unified layout Reviewed-by: darcy, ihse
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     1
/*
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     2
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     3
 *
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     4
 * This code is free software; you can redistribute it and/or modify it
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     5
 * under the terms of the GNU General Public License version 2 only, as
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     6
 * published by the Free Software Foundation.  Oracle designates this
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     7
 * particular file as subject to the "Classpath" exception as provided
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     8
 * by Oracle in the LICENSE file that accompanied this code.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
     9
 *
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    10
 * This code is distributed in the hope that it will be useful, but WITHOUT
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    11
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    12
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    13
 * version 2 for more details (a copy is included in the LICENSE file that
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    14
 * accompanied this code).
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    15
 *
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    16
 * You should have received a copy of the GNU General Public License version
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    17
 * 2 along with this work; if not, write to the Free Software Foundation,
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    18
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    19
 *
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    20
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    21
 * or visit www.oracle.com if you need additional information or have any
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    22
 * questions.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    23
 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    24
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    25
/* pngstruct.h - header file for PNG reference library
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    26
 *
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    27
 * This file is available under and governed by the GNU General Public
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    28
 * License version 2 only, as published by the Free Software Foundation.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    29
 * However, the following notice accompanied the original version of this
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    30
 * file and, per its terms, should not be removed:
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    31
 *
43321
2b8d397c03a4 8167228: Update to libpng 1.6.28
prr
parents: 40436
diff changeset
    32
 * Last changed in libpng 1.6.28 [January 5, 2017]
2b8d397c03a4 8167228: Update to libpng 1.6.28
prr
parents: 40436
diff changeset
    33
 * Copyright (c) 1998-2002,2004,2006-2017 Glenn Randers-Pehrson
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    34
 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    35
 * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    36
 *
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    37
 * This code is released under the libpng license.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    38
 * For conditions of distribution and use, see the disclaimer
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    39
 * and license in png.h
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    40
 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    41
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    42
/* The structure that holds the information to read and write PNG files.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    43
 * The only people who need to care about what is inside of this are the
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    44
 * people who will be modifying the library for their own special needs.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    45
 * It should NOT be accessed directly by an application.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    46
 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    47
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    48
#ifndef PNGSTRUCT_H
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    49
#define PNGSTRUCT_H
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    50
/* zlib.h defines the structure z_stream, an instance of which is included
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    51
 * in this structure and is required for decompressing the LZ compressed
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    52
 * data in PNG files.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    53
 */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    54
#ifndef ZLIB_CONST
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    55
   /* We must ensure that zlib uses 'const' in declarations. */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    56
#  define ZLIB_CONST
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    57
#endif
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
    58
#include "zlib.h"
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    59
#ifdef const
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    60
   /* zlib.h sometimes #defines const to nothing, undo this. */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    61
#  undef const
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    62
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    63
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    64
/* zlib.h has mediocre z_const use before 1.2.6, this stuff is for compatibility
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    65
 * with older builds.
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    66
 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    67
#if ZLIB_VERNUM < 0x1260
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    68
#  define PNGZ_MSG_CAST(s) png_constcast(char*,s)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    69
#  define PNGZ_INPUT_CAST(b) png_constcast(png_bytep,b)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    70
#else
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    71
#  define PNGZ_MSG_CAST(s) (s)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    72
#  define PNGZ_INPUT_CAST(b) (b)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    73
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    74
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    75
/* zlib.h declares a magic type 'uInt' that limits the amount of data that zlib
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    76
 * can handle at once.  This type need be no larger than 16 bits (so maximum of
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    77
 * 65535), this define allows us to discover how big it is, but limited by the
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    78
 * maximuum for png_size_t.  The value can be overriden in a library build
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    79
 * (pngusr.h, or set it in CPPFLAGS) and it works to set it to a considerably
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    80
 * lower value (e.g. 255 works).  A lower value may help memory usage (slightly)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    81
 * and may even improve performance on some systems (and degrade it on others.)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    82
 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    83
#ifndef ZLIB_IO_MAX
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    84
#  define ZLIB_IO_MAX ((uInt)-1)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    85
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    86
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    87
#ifdef PNG_WRITE_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    88
/* The type of a compression buffer list used by the write code. */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    89
typedef struct png_compression_buffer
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    90
{
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    91
   struct png_compression_buffer *next;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    92
   png_byte                       output[1]; /* actually zbuf_size */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    93
} png_compression_buffer, *png_compression_bufferp;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    94
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    95
#define PNG_COMPRESSION_BUFFER_SIZE(pp)\
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    96
   (offsetof(png_compression_buffer, output) + (pp)->zbuffer_size)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    97
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    98
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
    99
/* Colorspace support; structures used in png_struct, png_info and in internal
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   100
 * functions to hold and communicate information about the color space.
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   101
 *
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   102
 * PNG_COLORSPACE_SUPPORTED is only required if the application will perform
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   103
 * colorspace corrections, otherwise all the colorspace information can be
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   104
 * skipped and the size of libpng can be reduced (significantly) by compiling
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   105
 * out the colorspace support.
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   106
 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   107
#ifdef PNG_COLORSPACE_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   108
/* The chromaticities of the red, green and blue colorants and the chromaticity
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   109
 * of the corresponding white point (i.e. of rgb(1.0,1.0,1.0)).
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   110
 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   111
typedef struct png_xy
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   112
{
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   113
   png_fixed_point redx, redy;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   114
   png_fixed_point greenx, greeny;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   115
   png_fixed_point bluex, bluey;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   116
   png_fixed_point whitex, whitey;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   117
} png_xy;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   118
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   119
/* The same data as above but encoded as CIE XYZ values.  When this data comes
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   120
 * from chromaticities the sum of the Y values is assumed to be 1.0
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   121
 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   122
typedef struct png_XYZ
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   123
{
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   124
   png_fixed_point red_X, red_Y, red_Z;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   125
   png_fixed_point green_X, green_Y, green_Z;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   126
   png_fixed_point blue_X, blue_Y, blue_Z;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   127
} png_XYZ;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   128
#endif /* COLORSPACE */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   129
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   130
#if defined(PNG_COLORSPACE_SUPPORTED) || defined(PNG_GAMMA_SUPPORTED)
35296
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   131
/* A colorspace is all the above plus, potentially, profile information;
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   132
 * however at present libpng does not use the profile internally so it is only
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   133
 * stored in the png_info struct (if iCCP is supported.)  The rendering intent
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   134
 * is retained here and is checked.
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   135
 *
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   136
 * The file gamma encoding information is also stored here and gamma correction
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   137
 * is done by libpng, whereas color correction must currently be done by the
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   138
 * application.
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   139
 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   140
typedef struct png_colorspace
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   141
{
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   142
#ifdef PNG_GAMMA_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   143
   png_fixed_point gamma;        /* File gamma */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   144
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   145
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   146
#ifdef PNG_COLORSPACE_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   147
   png_xy      end_points_xy;    /* End points as chromaticities */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   148
   png_XYZ     end_points_XYZ;   /* End points as CIE XYZ colorant values */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   149
   png_uint_16 rendering_intent; /* Rendering intent of a profile */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   150
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   151
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   152
   /* Flags are always defined to simplify the code. */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   153
   png_uint_16 flags;            /* As defined below */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   154
} png_colorspace, * PNG_RESTRICT png_colorspacerp;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   155
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   156
typedef const png_colorspace * PNG_RESTRICT png_const_colorspacerp;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   157
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   158
/* General flags for the 'flags' field */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   159
#define PNG_COLORSPACE_HAVE_GAMMA           0x0001
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   160
#define PNG_COLORSPACE_HAVE_ENDPOINTS       0x0002
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   161
#define PNG_COLORSPACE_HAVE_INTENT          0x0004
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   162
#define PNG_COLORSPACE_FROM_gAMA            0x0008
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   163
#define PNG_COLORSPACE_FROM_cHRM            0x0010
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   164
#define PNG_COLORSPACE_FROM_sRGB            0x0020
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   165
#define PNG_COLORSPACE_ENDPOINTS_MATCH_sRGB 0x0040
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   166
#define PNG_COLORSPACE_MATCHES_sRGB         0x0080 /* exact match on profile */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   167
#define PNG_COLORSPACE_INVALID              0x8000
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   168
#define PNG_COLORSPACE_CANCEL(flags)        (0xffff ^ (flags))
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   169
#endif /* COLORSPACE || GAMMA */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   170
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   171
struct png_struct_def
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   172
{
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   173
#ifdef PNG_SETJMP_SUPPORTED
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   174
   jmp_buf jmp_buf_local;     /* New name in 1.6.0 for jmp_buf in png_struct */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   175
   png_longjmp_ptr longjmp_fn;/* setjmp non-local goto function. */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   176
   jmp_buf *jmp_buf_ptr;      /* passed to longjmp_fn */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   177
   size_t jmp_buf_size;       /* size of the above, if allocated */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   178
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   179
   png_error_ptr error_fn;    /* function for printing errors and aborting */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   180
#ifdef PNG_WARNINGS_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   181
   png_error_ptr warning_fn;  /* function for printing warnings */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   182
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   183
   png_voidp error_ptr;       /* user supplied struct for error functions */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   184
   png_rw_ptr write_data_fn;  /* function for writing output data */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   185
   png_rw_ptr read_data_fn;   /* function for reading input data */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   186
   png_voidp io_ptr;          /* ptr to application struct for I/O functions */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   187
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   188
#ifdef PNG_READ_USER_TRANSFORM_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   189
   png_user_transform_ptr read_user_transform_fn; /* user read transform */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   190
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   191
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   192
#ifdef PNG_WRITE_USER_TRANSFORM_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   193
   png_user_transform_ptr write_user_transform_fn; /* user write transform */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   194
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   195
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   196
/* These were added in libpng-1.0.2 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   197
#ifdef PNG_USER_TRANSFORM_PTR_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   198
#if defined(PNG_READ_USER_TRANSFORM_SUPPORTED) || \
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   199
    defined(PNG_WRITE_USER_TRANSFORM_SUPPORTED)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   200
   png_voidp user_transform_ptr; /* user supplied struct for user transform */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   201
   png_byte user_transform_depth;    /* bit depth of user transformed pixels */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   202
   png_byte user_transform_channels; /* channels in user transformed pixels */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   203
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   204
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   205
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   206
   png_uint_32 mode;          /* tells us where we are in the PNG file */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   207
   png_uint_32 flags;         /* flags indicating various things to libpng */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   208
   png_uint_32 transformations; /* which transformations to perform */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   209
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   210
   png_uint_32 zowner;        /* ID (chunk type) of zstream owner, 0 if none */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   211
   z_stream    zstream;       /* decompression structure */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   212
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   213
#ifdef PNG_WRITE_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   214
   png_compression_bufferp zbuffer_list; /* Created on demand during write */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   215
   uInt                    zbuffer_size; /* size of the actual buffer */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   216
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   217
   int zlib_level;            /* holds zlib compression level */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   218
   int zlib_method;           /* holds zlib compression method */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   219
   int zlib_window_bits;      /* holds zlib compression window bits */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   220
   int zlib_mem_level;        /* holds zlib compression memory level */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   221
   int zlib_strategy;         /* holds zlib compression strategy */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   222
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   223
/* Added at libpng 1.5.4 */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   224
#ifdef PNG_WRITE_CUSTOMIZE_ZTXT_COMPRESSION_SUPPORTED
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   225
   int zlib_text_level;            /* holds zlib compression level */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   226
   int zlib_text_method;           /* holds zlib compression method */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   227
   int zlib_text_window_bits;      /* holds zlib compression window bits */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   228
   int zlib_text_mem_level;        /* holds zlib compression memory level */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   229
   int zlib_text_strategy;         /* holds zlib compression strategy */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   230
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   231
/* End of material added at libpng 1.5.4 */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   232
/* Added at libpng 1.6.0 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   233
#ifdef PNG_WRITE_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   234
   int zlib_set_level;        /* Actual values set into the zstream on write */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   235
   int zlib_set_method;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   236
   int zlib_set_window_bits;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   237
   int zlib_set_mem_level;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   238
   int zlib_set_strategy;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   239
#endif
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   240
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   241
   png_uint_32 width;         /* width of image in pixels */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   242
   png_uint_32 height;        /* height of image in pixels */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   243
   png_uint_32 num_rows;      /* number of rows in current pass */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   244
   png_uint_32 usr_width;     /* width of row at start of write */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   245
   png_size_t rowbytes;       /* size of row in bytes */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   246
   png_uint_32 iwidth;        /* width of current interlaced row in pixels */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   247
   png_uint_32 row_number;    /* current row in interlace pass */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   248
   png_uint_32 chunk_name;    /* PNG_CHUNK() id of current chunk */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   249
   png_bytep prev_row;        /* buffer to save previous (unfiltered) row.
35296
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   250
                               * While reading this is a pointer into
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   251
                               * big_prev_row; while writing it is separately
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   252
                               * allocated if needed.
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   253
                               */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   254
   png_bytep row_buf;         /* buffer to save current (unfiltered) row.
35296
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   255
                               * While reading, this is a pointer into
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   256
                               * big_row_buf; while writing it is separately
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   257
                               * allocated.
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   258
                               */
35296
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   259
#ifdef PNG_WRITE_FILTER_SUPPORTED
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   260
   png_bytep try_row;    /* buffer to save trial row when filtering */
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   261
   png_bytep tst_row;    /* buffer to save best trial row when filtering */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   262
#endif
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   263
   png_size_t info_rowbytes;  /* Added in 1.5.4: cache of updated row bytes */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   264
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   265
   png_uint_32 idat_size;     /* current IDAT size for read */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   266
   png_uint_32 crc;           /* current chunk CRC value */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   267
   png_colorp palette;        /* palette from the input file */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   268
   png_uint_16 num_palette;   /* number of color entries in palette */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   269
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   270
/* Added at libpng-1.5.10 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   271
#ifdef PNG_CHECK_FOR_INVALID_INDEX_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   272
   int num_palette_max;       /* maximum palette index found in IDAT */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   273
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   274
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   275
   png_uint_16 num_trans;     /* number of transparency values */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   276
   png_byte compression;      /* file compression type (always 0) */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   277
   png_byte filter;           /* file filter type (always 0) */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   278
   png_byte interlaced;       /* PNG_INTERLACE_NONE, PNG_INTERLACE_ADAM7 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   279
   png_byte pass;             /* current interlace pass (0 - 6) */
43321
2b8d397c03a4 8167228: Update to libpng 1.6.28
prr
parents: 40436
diff changeset
   280
   png_byte do_filter;        /* row filter flags (see PNG_FILTER_ in png.h ) */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   281
   png_byte color_type;       /* color type of file */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   282
   png_byte bit_depth;        /* bit depth of file */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   283
   png_byte usr_bit_depth;    /* bit depth of users row: write only */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   284
   png_byte pixel_depth;      /* number of bits per pixel */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   285
   png_byte channels;         /* number of channels in file */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   286
#ifdef PNG_WRITE_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   287
   png_byte usr_channels;     /* channels at start of write: write only */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   288
#endif
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   289
   png_byte sig_bytes;        /* magic bytes read/written from start of file */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   290
   png_byte maximum_pixel_depth;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   291
                              /* pixel depth used for the row buffers */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   292
   png_byte transformed_pixel_depth;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   293
                              /* pixel depth after read/write transforms */
43321
2b8d397c03a4 8167228: Update to libpng 1.6.28
prr
parents: 40436
diff changeset
   294
#if ZLIB_VERNUM >= 0x1240
35296
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   295
   png_byte zstream_start;    /* at start of an input zlib stream */
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   296
#endif /* Zlib >= 1.2.4 */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   297
#if defined(PNG_READ_FILLER_SUPPORTED) || defined(PNG_WRITE_FILLER_SUPPORTED)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   298
   png_uint_16 filler;           /* filler bytes for pixel expansion */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   299
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   300
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   301
#if defined(PNG_bKGD_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED) ||\
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   302
   defined(PNG_READ_ALPHA_MODE_SUPPORTED)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   303
   png_byte background_gamma_type;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   304
   png_fixed_point background_gamma;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   305
   png_color_16 background;   /* background color in screen gamma space */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   306
#ifdef PNG_READ_GAMMA_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   307
   png_color_16 background_1; /* background normalized to gamma 1.0 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   308
#endif
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   309
#endif /* bKGD */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   310
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   311
#ifdef PNG_WRITE_FLUSH_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   312
   png_flush_ptr output_flush_fn; /* Function for flushing output */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   313
   png_uint_32 flush_dist;    /* how many rows apart to flush, 0 - no flush */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   314
   png_uint_32 flush_rows;    /* number of rows written since last flush */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   315
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   316
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   317
#ifdef PNG_READ_GAMMA_SUPPORTED
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   318
   int gamma_shift;      /* number of "insignificant" bits in 16-bit gamma */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   319
   png_fixed_point screen_gamma; /* screen gamma value (display_exponent) */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   320
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   321
   png_bytep gamma_table;     /* gamma table for 8-bit depth files */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   322
   png_uint_16pp gamma_16_table; /* gamma table for 16-bit depth files */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   323
#if defined(PNG_READ_BACKGROUND_SUPPORTED) || \
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   324
   defined(PNG_READ_ALPHA_MODE_SUPPORTED) || \
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   325
   defined(PNG_READ_RGB_TO_GRAY_SUPPORTED)
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   326
   png_bytep gamma_from_1;    /* converts from 1.0 to screen */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   327
   png_bytep gamma_to_1;      /* converts from file to 1.0 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   328
   png_uint_16pp gamma_16_from_1; /* converts from 1.0 to screen */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   329
   png_uint_16pp gamma_16_to_1; /* converts from file to 1.0 */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   330
#endif /* READ_BACKGROUND || READ_ALPHA_MODE || RGB_TO_GRAY */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   331
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   332
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   333
#if defined(PNG_READ_GAMMA_SUPPORTED) || defined(PNG_sBIT_SUPPORTED)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   334
   png_color_8 sig_bit;       /* significant bits in each available channel */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   335
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   336
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   337
#if defined(PNG_READ_SHIFT_SUPPORTED) || defined(PNG_WRITE_SHIFT_SUPPORTED)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   338
   png_color_8 shift;         /* shift for significant bit tranformation */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   339
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   340
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   341
#if defined(PNG_tRNS_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED) \
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   342
 || defined(PNG_READ_EXPAND_SUPPORTED) || defined(PNG_READ_BACKGROUND_SUPPORTED)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   343
   png_bytep trans_alpha;           /* alpha values for paletted files */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   344
   png_color_16 trans_color;  /* transparent color for non-paletted files */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   345
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   346
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   347
   png_read_status_ptr read_row_fn;   /* called after each row is decoded */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   348
   png_write_status_ptr write_row_fn; /* called after each row is encoded */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   349
#ifdef PNG_PROGRESSIVE_READ_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   350
   png_progressive_info_ptr info_fn; /* called after header data fully read */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   351
   png_progressive_row_ptr row_fn;   /* called after a prog. row is decoded */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   352
   png_progressive_end_ptr end_fn;   /* called after image is complete */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   353
   png_bytep save_buffer_ptr;        /* current location in save_buffer */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   354
   png_bytep save_buffer;            /* buffer for previously read data */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   355
   png_bytep current_buffer_ptr;     /* current location in current_buffer */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   356
   png_bytep current_buffer;         /* buffer for recently used data */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   357
   png_uint_32 push_length;          /* size of current input chunk */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   358
   png_uint_32 skip_length;          /* bytes to skip in input data */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   359
   png_size_t save_buffer_size;      /* amount of data now in save_buffer */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   360
   png_size_t save_buffer_max;       /* total size of save_buffer */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   361
   png_size_t buffer_size;           /* total amount of available input data */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   362
   png_size_t current_buffer_size;   /* amount of data now in current_buffer */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   363
   int process_mode;                 /* what push library is currently doing */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   364
   int cur_palette;                  /* current push library palette index */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   365
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   366
#endif /* PROGRESSIVE_READ */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   367
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   368
#if defined(__TURBOC__) && !defined(_Windows) && !defined(__FLAT__)
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   369
/* For the Borland special 64K segment handler */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   370
   png_bytepp offset_table_ptr;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   371
   png_bytep offset_table;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   372
   png_uint_16 offset_table_number;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   373
   png_uint_16 offset_table_count;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   374
   png_uint_16 offset_table_count_free;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   375
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   376
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   377
#ifdef PNG_READ_QUANTIZE_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   378
   png_bytep palette_lookup; /* lookup table for quantizing */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   379
   png_bytep quantize_index; /* index translation for palette files */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   380
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   381
35296
659e92aaf7f4 8143941: Update splashscreen displays
azvegint
parents: 29913
diff changeset
   382
/* Options */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   383
#ifdef PNG_SET_OPTION_SUPPORTED
43321
2b8d397c03a4 8167228: Update to libpng 1.6.28
prr
parents: 40436
diff changeset
   384
   png_uint_32 options;           /* On/off state (up to 16 options) */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   385
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   386
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   387
#if PNG_LIBPNG_VER < 10700
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   388
/* To do: remove this from libpng-1.7 */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   389
#ifdef PNG_TIME_RFC1123_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   390
   char time_buffer[29]; /* String to hold RFC 1123 time text */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   391
#endif
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   392
#endif
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   393
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   394
/* New members added in libpng-1.0.6 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   395
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   396
   png_uint_32 free_me;    /* flags items libpng is responsible for freeing */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   397
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   398
#ifdef PNG_USER_CHUNKS_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   399
   png_voidp user_chunk_ptr;
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   400
#ifdef PNG_READ_USER_CHUNKS_SUPPORTED
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   401
   png_user_chunk_ptr read_user_chunk_fn; /* user read chunk handler */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   402
#endif
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   403
#endif
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   404
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   405
#ifdef PNG_SET_UNKNOWN_CHUNKS_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   406
   int          unknown_default; /* As PNG_HANDLE_* */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   407
   unsigned int num_chunk_list;  /* Number of entries in the list */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   408
   png_bytep    chunk_list;      /* List of png_byte[5]; the textual chunk name
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   409
                                  * followed by a PNG_HANDLE_* byte */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   410
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   411
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   412
/* New members added in libpng-1.0.3 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   413
#ifdef PNG_READ_RGB_TO_GRAY_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   414
   png_byte rgb_to_gray_status;
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   415
   /* Added in libpng 1.5.5 to record setting of coefficients: */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   416
   png_byte rgb_to_gray_coefficients_set;
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   417
   /* These were changed from png_byte in libpng-1.0.6 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   418
   png_uint_16 rgb_to_gray_red_coeff;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   419
   png_uint_16 rgb_to_gray_green_coeff;
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   420
   /* deleted in 1.5.5: rgb_to_gray_blue_coeff; */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   421
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   422
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   423
/* New member added in libpng-1.0.4 (renamed in 1.0.9) */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   424
#if defined(PNG_MNG_FEATURES_SUPPORTED)
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   425
/* Changed from png_byte to png_uint_32 at version 1.2.0 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   426
   png_uint_32 mng_features_permitted;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   427
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   428
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   429
/* New member added in libpng-1.0.9, ifdef'ed out in 1.0.12, enabled in 1.2.0 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   430
#ifdef PNG_MNG_FEATURES_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   431
   png_byte filter_type;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   432
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   433
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   434
/* New members added in libpng-1.2.0 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   435
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   436
/* New members added in libpng-1.0.2 but first enabled by default in 1.2.0 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   437
#ifdef PNG_USER_MEM_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   438
   png_voidp mem_ptr;             /* user supplied struct for mem functions */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   439
   png_malloc_ptr malloc_fn;      /* function for allocating memory */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   440
   png_free_ptr free_fn;          /* function for freeing memory */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   441
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   442
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   443
/* New member added in libpng-1.0.13 and 1.2.0 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   444
   png_bytep big_row_buf;         /* buffer to save current (unfiltered) row */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   445
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   446
#ifdef PNG_READ_QUANTIZE_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   447
/* The following three members were added at version 1.0.14 and 1.2.4 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   448
   png_bytep quantize_sort;          /* working sort array */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   449
   png_bytep index_to_palette;       /* where the original index currently is
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   450
                                        in the palette */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   451
   png_bytep palette_to_index;       /* which original index points to this
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   452
                                         palette color */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   453
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   454
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   455
/* New members added in libpng-1.0.16 and 1.2.6 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   456
   png_byte compression_type;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   457
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   458
#ifdef PNG_USER_LIMITS_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   459
   png_uint_32 user_width_max;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   460
   png_uint_32 user_height_max;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   461
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   462
   /* Added in libpng-1.4.0: Total number of sPLT, text, and unknown
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   463
    * chunks that can be stored (0 means unlimited).
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   464
    */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   465
   png_uint_32 user_chunk_cache_max;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   466
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   467
   /* Total memory that a zTXt, sPLT, iTXt, iCCP, or unknown chunk
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   468
    * can occupy when decompressed.  0 means unlimited.
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   469
    */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   470
   png_alloc_size_t user_chunk_malloc_max;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   471
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   472
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   473
/* New member added in libpng-1.0.25 and 1.2.17 */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   474
#ifdef PNG_READ_UNKNOWN_CHUNKS_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   475
   /* Temporary storage for unknown chunk that the library doesn't recognize,
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   476
    * used while reading the chunk.
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   477
    */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   478
   png_unknown_chunk unknown_chunk;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   479
#endif
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   480
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   481
/* New member added in libpng-1.2.26 */
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   482
  png_size_t old_big_row_buf_size;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   483
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   484
#ifdef PNG_READ_SUPPORTED
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   485
/* New member added in libpng-1.2.30 */
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   486
  png_bytep        read_buffer;      /* buffer for reading chunk data */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   487
  png_alloc_size_t read_buffer_size; /* current size of the buffer */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   488
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   489
#ifdef PNG_SEQUENTIAL_READ_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   490
  uInt             IDAT_read_size;   /* limit on read buffer size for IDAT */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   491
#endif
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   492
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   493
#ifdef PNG_IO_STATE_SUPPORTED
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   494
/* New member added in libpng-1.4.0 */
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   495
   png_uint_32 io_state;
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   496
#endif
29913
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   497
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   498
/* New member added in libpng-1.5.6 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   499
   png_bytep big_prev_row;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   500
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   501
/* New member added in libpng-1.5.7 */
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   502
   void (*read_filter[PNG_FILTER_VALUE_LAST-1])(png_row_infop row_info,
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   503
      png_bytep row, png_const_bytep prev_row);
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   504
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   505
#ifdef PNG_READ_SUPPORTED
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   506
#if defined(PNG_COLORSPACE_SUPPORTED) || defined(PNG_GAMMA_SUPPORTED)
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   507
   png_colorspace   colorspace;
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   508
#endif
95258013e132 8069198: Upgrade image library
azvegint
parents: 25859
diff changeset
   509
#endif
10576
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   510
};
db3409425573 7088287: libpng need to be updated.
bae
parents:
diff changeset
   511
#endif /* PNGSTRUCT_H */