[master] Restored PNG_USE_LOCAL_ARRAYS block of pngread.c

that was inadvertently deleted by the previous checkin.
This commit is contained in:
Glenn Randers-Pehrson 2009-10-18 08:03:07 -05:00
parent 41cad5fbed
commit 7f9f605781

View File

@ -366,61 +366,63 @@ png_read_info(png_structp png_ptr, png_infop info_ptr)
for (;;) for (;;)
{ {
PNG_IHDR; #ifdef PNG_USE_LOCAL_ARRAYS
PNG_IDAT; PNG_CONST PNG_IHDR;
PNG_IEND; PNG_CONST PNG_IDAT;
PNG_PLTE; PNG_CONST PNG_IEND;
PNG_CONST PNG_PLTE;
#ifdef PNG_READ_bKGD_SUPPORTED #ifdef PNG_READ_bKGD_SUPPORTED
PNG_bKGD; PNG_CONST PNG_bKGD;
#endif #endif
#ifdef PNG_READ_cHRM_SUPPORTED #ifdef PNG_READ_cHRM_SUPPORTED
PNG_cHRM; PNG_CONST PNG_cHRM;
#endif #endif
#ifdef PNG_READ_gAMA_SUPPORTED #ifdef PNG_READ_gAMA_SUPPORTED
PNG_gAMA; PNG_CONST PNG_gAMA;
#endif #endif
#ifdef PNG_READ_hIST_SUPPORTED #ifdef PNG_READ_hIST_SUPPORTED
PNG_hIST; PNG_CONST PNG_hIST;
#endif #endif
#ifdef PNG_READ_iCCP_SUPPORTED #ifdef PNG_READ_iCCP_SUPPORTED
PNG_iCCP; PNG_CONST PNG_iCCP;
#endif #endif
#ifdef PNG_READ_iTXt_SUPPORTED #ifdef PNG_READ_iTXt_SUPPORTED
PNG_iTXt; PNG_CONST PNG_iTXt;
#endif #endif
#ifdef PNG_READ_oFFs_SUPPORTED #ifdef PNG_READ_oFFs_SUPPORTED
PNG_oFFs; PNG_CONST PNG_oFFs;
#endif #endif
#ifdef PNG_READ_pCAL_SUPPORTED #ifdef PNG_READ_pCAL_SUPPORTED
PNG_pCAL; PNG_CONST PNG_pCAL;
#endif #endif
#ifdef PNG_READ_pHYs_SUPPORTED #ifdef PNG_READ_pHYs_SUPPORTED
PNG_pHYs; PNG_CONST PNG_pHYs;
#endif #endif
#ifdef PNG_READ_sBIT_SUPPORTED #ifdef PNG_READ_sBIT_SUPPORTED
PNG_sBIT; PNG_CONST PNG_sBIT;
#endif #endif
#ifdef PNG_READ_sCAL_SUPPORTED #ifdef PNG_READ_sCAL_SUPPORTED
PNG_sCAL; PNG_CONST PNG_sCAL;
#endif #endif
#ifdef PNG_READ_sPLT_SUPPORTED #ifdef PNG_READ_sPLT_SUPPORTED
PNG_sPLT; PNG_CONST PNG_sPLT;
#endif #endif
#ifdef PNG_READ_sRGB_SUPPORTED #ifdef PNG_READ_sRGB_SUPPORTED
PNG_sRGB; PNG_CONST PNG_sRGB;
#endif #endif
#ifdef PNG_READ_tEXt_SUPPORTED #ifdef PNG_READ_tEXt_SUPPORTED
PNG_tEXt; PNG_CONST PNG_tEXt;
#endif #endif
#ifdef PNG_READ_tIME_SUPPORTED #ifdef PNG_READ_tIME_SUPPORTED
PNG_tIME; PNG_CONST PNG_tIME;
#endif #endif
#ifdef PNG_READ_tRNS_SUPPORTED #ifdef PNG_READ_tRNS_SUPPORTED
PNG_tRNS; PNG_CONST PNG_tRNS;
#endif #endif
#ifdef PNG_READ_zTXt_SUPPORTED #ifdef PNG_READ_zTXt_SUPPORTED
PNG_zTXt; PNG_CONST PNG_zTXt;
#endif #endif
#endif /* PNG_USE_LOCAL_ARRAYS */
png_uint_32 length = png_read_chunk_header(png_ptr); png_uint_32 length = png_read_chunk_header(png_ptr);
PNG_CONST png_bytep chunk_name = png_ptr->chunk_name; PNG_CONST png_bytep chunk_name = png_ptr->chunk_name;
@ -580,7 +582,7 @@ png_start_read_image(png_structp png_ptr)
void PNGAPI void PNGAPI
png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row) png_read_row(png_structp png_ptr, png_bytep row, png_bytep dsp_row)
{ {
PNG_IDAT; PNG_CONST PNG_IDAT;
PNG_CONST int png_pass_dsp_mask[7] = {0xff, 0x0f, 0xff, 0x33, 0xff, 0x55, PNG_CONST int png_pass_dsp_mask[7] = {0xff, 0x0f, 0xff, 0x33, 0xff, 0x55,
0xff}; 0xff};
PNG_CONST int png_pass_mask[7] = {0x80, 0x08, 0x88, 0x22, 0xaa, 0x55, 0xff}; PNG_CONST int png_pass_mask[7] = {0x80, 0x08, 0x88, 0x22, 0xaa, 0x55, 0xff};
@ -938,61 +940,63 @@ png_read_end(png_structp png_ptr, png_infop info_ptr)
do do
{ {
PNG_IHDR; #ifdef PNG_USE_LOCAL_ARRAYS
PNG_IDAT; PNG_CONST PNG_IHDR;
PNG_IEND; PNG_CONST PNG_IDAT;
PNG_PLTE; PNG_CONST PNG_IEND;
PNG_CONST PNG_PLTE;
#ifdef PNG_READ_bKGD_SUPPORTED #ifdef PNG_READ_bKGD_SUPPORTED
PNG_bKGD; PNG_CONST PNG_bKGD;
#endif #endif
#ifdef PNG_READ_cHRM_SUPPORTED #ifdef PNG_READ_cHRM_SUPPORTED
PNG_cHRM; PNG_CONST PNG_cHRM;
#endif #endif
#ifdef PNG_READ_gAMA_SUPPORTED #ifdef PNG_READ_gAMA_SUPPORTED
PNG_gAMA; PNG_CONST PNG_gAMA;
#endif #endif
#ifdef PNG_READ_hIST_SUPPORTED #ifdef PNG_READ_hIST_SUPPORTED
PNG_hIST; PNG_CONST PNG_hIST;
#endif #endif
#ifdef PNG_READ_iCCP_SUPPORTED #ifdef PNG_READ_iCCP_SUPPORTED
PNG_iCCP; PNG_CONST PNG_iCCP;
#endif #endif
#ifdef PNG_READ_iTXt_SUPPORTED #ifdef PNG_READ_iTXt_SUPPORTED
PNG_iTXt; PNG_CONST PNG_iTXt;
#endif #endif
#ifdef PNG_READ_oFFs_SUPPORTED #ifdef PNG_READ_oFFs_SUPPORTED
PNG_oFFs; PNG_CONST PNG_oFFs;
#endif #endif
#ifdef PNG_READ_pCAL_SUPPORTED #ifdef PNG_READ_pCAL_SUPPORTED
PNG_pCAL; PNG_CONST PNG_pCAL;
#endif #endif
#ifdef PNG_READ_pHYs_SUPPORTED #ifdef PNG_READ_pHYs_SUPPORTED
PNG_pHYs; PNG_CONST PNG_pHYs;
#endif #endif
#ifdef PNG_READ_sBIT_SUPPORTED #ifdef PNG_READ_sBIT_SUPPORTED
PNG_sBIT; PNG_CONST PNG_sBIT;
#endif #endif
#ifdef PNG_READ_sCAL_SUPPORTED #ifdef PNG_READ_sCAL_SUPPORTED
PNG_sCAL; PNG_CONST PNG_sCAL;
#endif #endif
#ifdef PNG_READ_sPLT_SUPPORTED #ifdef PNG_READ_sPLT_SUPPORTED
PNG_sPLT; PNG_CONST PNG_sPLT;
#endif #endif
#ifdef PNG_READ_sRGB_SUPPORTED #ifdef PNG_READ_sRGB_SUPPORTED
PNG_sRGB; PNG_CONST PNG_sRGB;
#endif #endif
#ifdef PNG_READ_tEXt_SUPPORTED #ifdef PNG_READ_tEXt_SUPPORTED
PNG_tEXt; PNG_CONST PNG_tEXt;
#endif #endif
#ifdef PNG_READ_tIME_SUPPORTED #ifdef PNG_READ_tIME_SUPPORTED
PNG_tIME; PNG_CONST PNG_tIME;
#endif #endif
#ifdef PNG_READ_tRNS_SUPPORTED #ifdef PNG_READ_tRNS_SUPPORTED
PNG_tRNS; PNG_CONST PNG_tRNS;
#endif #endif
#ifdef PNG_READ_zTXt_SUPPORTED #ifdef PNG_READ_zTXt_SUPPORTED
PNG_zTXt; PNG_CONST PNG_zTXt;
#endif #endif
#endif /* PNG_USE_LOCAL_ARRAYS */
png_uint_32 length = png_read_chunk_header(png_ptr); png_uint_32 length = png_read_chunk_header(png_ptr);
PNG_CONST png_bytep chunk_name = png_ptr->chunk_name; PNG_CONST png_bytep chunk_name = png_ptr->chunk_name;