Index: third_party/libpng/pnglibconf.h |
diff --git a/third_party/libpng/pngusr.h b/third_party/libpng/pnglibconf.h |
similarity index 91% |
copy from third_party/libpng/pngusr.h |
copy to third_party/libpng/pnglibconf.h |
index d080ea2a7a068a4718d905c1de388af3dfacbce9..51cd395c16a7dd00601f80c8459a4d29d96a6217 100644 |
--- a/third_party/libpng/pngusr.h |
+++ b/third_party/libpng/pnglibconf.h |
@@ -34,90 +34,80 @@ |
* |
* ***** END LICENSE BLOCK ***** */ |
-#ifndef CHROME_THIRD_PARTY_LIBPNG_PNGUSR_H__ |
-#define CHROME_THIRD_PARTY_LIBPNG_PNGUSR_H__ |
+#ifndef CHROME_THIRD_PARTY_LIBPNG_PNGLIBCONF_H__ |
+#define CHROME_THIRD_PARTY_LIBPNG_PNGLIBCONF_H__ |
-#define PNG_NO_GLOBAL_ARRAYS |
+// For libpng 1.6.3 |
+#define PNG_SAFE_LIMITS_SUPPORTED |
+#define PNG_SETJMP_SUPPORTED |
+#define PNG_PROGRESSIVE_READ_SUPPORTED |
+#define PNG_READ_INTERLACING_SUPPORTED |
+#define PNG_USER_TRANSFORM_PTR_SUPPORTED |
+#define PNG_WRITE_USER_TRANSFORM_SUPPORTED |
+#define PNG_READ_SUPPORTED |
+#define PNG_READ_USER_TRANSFORM_SUPPORTED |
+#define PNG_READ_GAMMA_SUPPORTED |
+#define PNG_GAMMA_SUPPORTED |
+#define PNG_COLORSPACE_SUPPORTED |
+#define PNG_READ_EXPAND_SUPPORTED |
+#define PNG_READ_STRIP_16_TO_8_SUPPORTED |
+#define PNG_READ_FILLER_SUPPORTED |
+#define PNG_READ_BGR_SUPPORTED |
+#define PNG_READ_STRIP_ALPHA_SUPPORTED |
+#define PNG_READ_GRAY_TO_RGB_SUPPORTED |
+#define PNG_gAMA_SUPPORTED |
+#define PNG_FLOATING_POINT_SUPPORTED |
+#define PNG_ERROR_TEXT_SUPPORTED |
+#define PNG_EASY_ACCESS_SUPPORTED |
+#define PNG_tRNS_SUPPORTED |
+#define PNG_READ_tRNS_SUPPORTED |
+#define PNG_WRITE_tRNS_SUPPORTED |
+#define PNG_WARNINGS_SUPPORTED |
+#define PNG_WRITE_INT_FUNCTIONS_SUPPORTED |
+#define PNG_WRITE_TRANSFORMS_SUPPORTED |
+#define PNG_READ_TRANSFORMS_SUPPORTED |
+#define PNG_INFO_IMAGE_SUPPORTED |
-#undef PNG_NO_INFO_IMAGE |
-#define PNG_NO_READ_BACKGROUND |
-#define PNG_NO_READ_DITHER |
-#define PNG_NO_READ_INVERT |
-#define PNG_NO_READ_SHIFT |
-#define PNG_NO_READ_PACK |
-#define PNG_NO_READ_PACKSWAP |
-#undef PNG_NO_READ_FILLER |
-#define PNG_NO_READ_SWAP |
-#define PNG_NO_READ_SWAP_ALPHA |
-#define PNG_NO_READ_INVERT_ALPHA |
-#define PNG_NO_READ_RGB_TO_GRAY |
-#define PNG_NO_READ_bKGD |
-#undef PNG_NO_READ_cHRM |
-#undef PNG_NO_READ_gAMA |
-#define PNG_NO_READ_hIST |
-#undef PNG_NO_READ_iCCP |
-#define PNG_NO_READ_oFFs |
-#define PNG_NO_READ_pCAL |
-#define PNG_NO_READ_pHYs |
-#define PNG_NO_READ_sBIT |
-#define PNG_NO_READ_sCAL |
-#define PNG_NO_READ_sPLT |
-#undef PNG_NO_READ_sRGB |
-#define PNG_NO_READ_TEXT |
-#define PNG_NO_READ_tIME |
-#define PNG_NO_READ_UNKNOWN_CHUNKS |
-#define PNG_NO_READ_USER_CHUNKS |
-#define PNG_NO_READ_EMPTY_PLTE |
-#define PNG_NO_READ_OPT_PLTE |
+#define PNG_TEXT_SUPPORTED |
+#define PNG_WRITE_TEXT_SUPPORTED |
+#define PNG_tEXt_SUPPORTED |
+#define PNG_READ_tEXt_SUPPORTED |
+#define PNG_WRITE_tEXt_SUPPORTED |
+#define PNG_cHRM_SUPPORTED |
+#define PNG_READ_cHRM_SUPPORTED |
+#define PNG_gAMA_SUPPORTED |
+#define PNG_READ_gAMA_SUPPORTED |
+#define PNG_iCCP_SUPPORTED |
+#define PNG_READ_iCCP_SUPPORTED |
+ |
+#define PNG_FORMAT_BGR_SUPPORTED |
+#define PNG_WRITE_BGR_SUPPORTED |
#ifdef CHROME_PNG_WRITE_SUPPORT |
-#define PNG_NO_WRITE_BACKGROUND |
-#define PNG_NO_WRITE_DITHER |
-#define PNG_NO_WRITE_INVERT |
-#define PNG_NO_WRITE_SHIFT |
-#define PNG_NO_WRITE_PACK |
-#define PNG_NO_WRITE_PACKSWAP |
-#undef PNG_NO_WRITE_FILLER |
-#define PNG_NO_WRITE_SWAP |
-#define PNG_NO_WRITE_SWAP_ALPHA |
-#define PNG_NO_WRITE_INVERT_ALPHA |
-#define PNG_NO_WRITE_RGB_TO_GRAY |
-#define PNG_NO_WRITE_USER_TRANSFORM |
-#define PNG_NO_WRITE_bKGD |
-#define PNG_NO_WRITE_cHRM |
-#define PNG_NO_WRITE_gAMA |
-#define PNG_NO_WRITE_hIST |
-#define PNG_NO_WRITE_iCCP |
-#define PNG_NO_WRITE_oFFs |
-#define PNG_NO_WRITE_pCAL |
-#define PNG_NO_WRITE_pHYs |
-#define PNG_NO_WRITE_sBIT |
-#define PNG_NO_WRITE_sCAL |
-#define PNG_NO_WRITE_sPLT |
-#define PNG_NO_WRITE_sRGB |
-#define PNG_NO_WRITE_tIME |
-#define PNG_NO_WRITE_UNKNOWN_CHUNKS |
-#define PNG_NO_WRITE_USER_CHUNKS |
-#define PNG_NO_WRITE_EMPTY_PLTE |
-#define PNG_NO_WRITE_OPT_PLTE |
-#else |
-#define PNG_NO_WRITE_SUPPORTED |
+#define PNG_WRITE_SUPPORTED |
+#define PNG_WRITE_FILLER_SUPPORTED |
#endif |
-#define PNG_NO_USER_MEM |
-#define PNG_NO_FIXED_POINT_SUPPORTED |
-#define PNG_NO_MNG_FEATURES |
-#define PNG_NO_HANDLE_AS_UNKNOWN |
-#define PNG_NO_CONSOLE_IO |
-#define PNG_NO_ZALLOC_ZERO |
-#define PNG_NO_ERROR_NUMBERS |
-#undef PNG_NO_EASY_ACCESS |
-#define PNG_NO_USER_LIMITS |
-#define PNG_NO_SET_USER_LIMITS |
-#define PNG_NO_TIME_RFC1123 |
-#undef PNG_NO_INFO_IMAGE |
-#undef PNG_NO_PROGRESSIVE_READ |
-#undef PNG_NO_SEQUENTIAL_READ |
+#define PNG_CORRECT_PALETTE_SUPPORTED |
+#define PNG_GET_PALETTE_MAX_SUPPORTED |
+ |
+// For NEON support on ARM |
+#ifdef __arm__ |
+#define PNG_ALIGNED_MEMORY_SUPPORTED |
+#define PNG_ARM_NEON_CHECK_SUPPORTED |
+#define PNG_ARM_NEON_OPT 2 |
+#endif /* __arm__ */ |
+ |
+// For libpng 1.6.3 obtained from scripts/pnglibconf.h.prebuilt. |
+#define PNG_INFLATE_BUF_SIZE 1024 |
+#define PNG_ZBUF_SIZE 8192 |
+#define PNG_IDAT_READ_SIZE PNG_ZBUF_SIZE |
+#define PNG_Z_DEFAULT_COMPRESSION (-1) |
+#define PNG_Z_DEFAULT_NOFILTER_STRATEGY 0 |
+#define PNG_Z_DEFAULT_STRATEGY 1 |
+#define PNG_GAMMA_THRESHOLD_FIXED 5000 |
+#define PNG_MAX_GAMMA_8 11 |
+ |
/* Mangle names of exported libpng functions so different libpng versions |
can coexist. It is recommended that if you do this, you give your |
@@ -134,7 +124,8 @@ |
#define png_check_cHRM_fixed wk_png_check_cHRM_fixed |
#define png_check_chunk_name wk_png_check_chunk_name |
#define png_check_keyword wk_png_check_keyword |
-#define png_check_sig wk_png_check_sig |
+// No exported on >=1.6.3 |
+//#define png_check_sig wk_png_check_sig |
#undef png_chunk_benign_error |
#define png_chunk_error wk_png_chunk_error |
#define png_chunk_warning wk_png_chunk_warning |
@@ -486,4 +477,4 @@ |
#define png_zalloc wk_png_zalloc |
#define png_zfree wk_png_zfree |
-#endif // CHROME_THIRD_PARTY_LIBPNG_PNGUSR_H__ |
+#endif // CHROME_THIRD_PARTY_LIBPNG_PNGLIBCONF_H__ |