X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e19291405ff3995a32c965da9694f2f20aa02468..fad92e2f367f5c37ba4d80c9b57a4453e86c6ac2:/src/jpeg/jcphuff.c diff --git a/src/jpeg/jcphuff.c b/src/jpeg/jcphuff.c index 07f9178b01..84e53f4032 100644 --- a/src/jpeg/jcphuff.c +++ b/src/jpeg/jcphuff.c @@ -25,14 +25,14 @@ typedef struct { struct jpeg_entropy_encoder pub; /* public fields */ /* Mode flag: TRUE for optimization, FALSE for actual data output */ - boolean gather_statistics; + wxjpeg_boolean gather_statistics; /* Bit-level coding status. * next_output_byte/free_in_buffer are local copies of cinfo->dest fields. */ JOCTET * next_output_byte; /* => next byte to write in buffer */ size_t free_in_buffer; /* # of byte spaces remaining in buffer */ - INT32 put_buffer; /* current bit-accumulation buffer */ + JPEG_INT32 put_buffer; /* current bit-accumulation buffer */ int put_bits; /* # of bits now in it */ j_compress_ptr cinfo; /* link to cinfo (needed for dump_buffer) */ @@ -86,13 +86,13 @@ typedef phuff_entropy_encoder * phuff_entropy_ptr; #endif /* Forward declarations */ -METHODDEF(boolean) encode_mcu_DC_first JPP((j_compress_ptr cinfo, +METHODDEF(wxjpeg_boolean) encode_mcu_DC_first JPP((j_compress_ptr cinfo, JBLOCKROW *MCU_data)); -METHODDEF(boolean) encode_mcu_AC_first JPP((j_compress_ptr cinfo, +METHODDEF(wxjpeg_boolean) encode_mcu_AC_first JPP((j_compress_ptr cinfo, JBLOCKROW *MCU_data)); -METHODDEF(boolean) encode_mcu_DC_refine JPP((j_compress_ptr cinfo, +METHODDEF(wxjpeg_boolean) encode_mcu_DC_refine JPP((j_compress_ptr cinfo, JBLOCKROW *MCU_data)); -METHODDEF(boolean) encode_mcu_AC_refine JPP((j_compress_ptr cinfo, +METHODDEF(wxjpeg_boolean) encode_mcu_AC_refine JPP((j_compress_ptr cinfo, JBLOCKROW *MCU_data)); METHODDEF(void) finish_pass_phuff JPP((j_compress_ptr cinfo)); METHODDEF(void) finish_pass_gather_phuff JPP((j_compress_ptr cinfo)); @@ -103,10 +103,10 @@ METHODDEF(void) finish_pass_gather_phuff JPP((j_compress_ptr cinfo)); */ METHODDEF(void) -start_pass_phuff (j_compress_ptr cinfo, boolean gather_statistics) +start_pass_phuff (j_compress_ptr cinfo, wxjpeg_boolean gather_statistics) { phuff_entropy_ptr entropy = (phuff_entropy_ptr) cinfo->entropy; - boolean is_DC_band; + wxjpeg_boolean is_DC_band; int ci, tbl; jpeg_component_info * compptr; @@ -229,7 +229,7 @@ emit_bits (phuff_entropy_ptr entropy, unsigned int code, int size) /* Emit some bits, unless we are in gather mode */ { /* This routine is heavily used, so it's worth coding tightly. */ - register INT32 put_buffer = (INT32) code; + register JPEG_INT32 put_buffer = (JPEG_INT32) code; register int put_bits = entropy->put_bits; /* if size is 0, caller used an invalid Huffman table entry */ @@ -239,7 +239,7 @@ emit_bits (phuff_entropy_ptr entropy, unsigned int code, int size) if (entropy->gather_statistics) return; /* do nothing if we're only getting stats */ - put_buffer &= (((INT32) 1)<entropy; @@ -460,7 +460,7 @@ encode_mcu_DC_first (j_compress_ptr cinfo, JBLOCKROW *MCU_data) * or first pass of successive approximation). */ -METHODDEF(boolean) +METHODDEF(wxjpeg_boolean) encode_mcu_AC_first (j_compress_ptr cinfo, JBLOCKROW *MCU_data) { phuff_entropy_ptr entropy = (phuff_entropy_ptr) cinfo->entropy; @@ -567,7 +567,7 @@ encode_mcu_AC_first (j_compress_ptr cinfo, JBLOCKROW *MCU_data) * is not very clear on the point. */ -METHODDEF(boolean) +METHODDEF(wxjpeg_boolean) encode_mcu_DC_refine (j_compress_ptr cinfo, JBLOCKROW *MCU_data) { phuff_entropy_ptr entropy = (phuff_entropy_ptr) cinfo->entropy; @@ -614,7 +614,7 @@ encode_mcu_DC_refine (j_compress_ptr cinfo, JBLOCKROW *MCU_data) * MCU encoding for AC successive approximation refinement scan. */ -METHODDEF(boolean) +METHODDEF(wxjpeg_boolean) encode_mcu_AC_refine (j_compress_ptr cinfo, JBLOCKROW *MCU_data) { phuff_entropy_ptr entropy = (phuff_entropy_ptr) cinfo->entropy; @@ -767,11 +767,11 @@ METHODDEF(void) finish_pass_gather_phuff (j_compress_ptr cinfo) { phuff_entropy_ptr entropy = (phuff_entropy_ptr) cinfo->entropy; - boolean is_DC_band; + wxjpeg_boolean is_DC_band; int ci, tbl; jpeg_component_info * compptr; JHUFF_TBL **htblptr; - boolean did[NUM_HUFF_TBLS]; + wxjpeg_boolean did[NUM_HUFF_TBLS]; /* Flush out buffered data (all we care about is counting the EOB symbol) */ emit_eobrun(entropy);