X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e19291405ff3995a32c965da9694f2f20aa02468..0055cc0e4a21e460eab83a79269f3fe5b0037239:/src/jpeg/jchuff.c diff --git a/src/jpeg/jchuff.c b/src/jpeg/jchuff.c index f235250548..45b3d2b6fb 100644 --- a/src/jpeg/jchuff.c +++ b/src/jpeg/jchuff.c @@ -27,7 +27,7 @@ */ typedef struct { - INT32 put_buffer; /* current bit-accumulation buffer */ + JPEG_INT32 put_buffer; /* current bit-accumulation buffer */ int put_bits; /* # of bits now in it */ int last_dc_val[MAX_COMPS_IN_SCAN]; /* last DC coef for each component */ } savable_state; @@ -86,11 +86,11 @@ typedef struct { /* Forward declarations */ -METHODDEF(boolean) encode_mcu_huff JPP((j_compress_ptr cinfo, +METHODDEF(wxjpeg_boolean) encode_mcu_huff JPP((j_compress_ptr cinfo, JBLOCKROW *MCU_data)); METHODDEF(void) finish_pass_huff JPP((j_compress_ptr cinfo)); #ifdef ENTROPY_OPT_SUPPORTED -METHODDEF(boolean) encode_mcu_gather JPP((j_compress_ptr cinfo, +METHODDEF(wxjpeg_boolean) encode_mcu_gather JPP((j_compress_ptr cinfo, JBLOCKROW *MCU_data)); METHODDEF(void) finish_pass_gather JPP((j_compress_ptr cinfo)); #endif @@ -103,7 +103,7 @@ METHODDEF(void) finish_pass_gather JPP((j_compress_ptr cinfo)); */ METHODDEF(void) -start_pass_huff (j_compress_ptr cinfo, boolean gather_statistics) +start_pass_huff (j_compress_ptr cinfo, wxjpeg_boolean gather_statistics) { huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy; int ci, dctbl, actbl; @@ -176,7 +176,7 @@ start_pass_huff (j_compress_ptr cinfo, boolean gather_statistics) */ GLOBAL(void) -jpeg_make_c_derived_tbl (j_compress_ptr cinfo, boolean isDC, int tblno, +jpeg_make_c_derived_tbl (j_compress_ptr cinfo, wxjpeg_boolean isDC, int tblno, c_derived_tbl ** pdtbl) { JHUFF_TBL *htbl; @@ -232,7 +232,7 @@ jpeg_make_c_derived_tbl (j_compress_ptr cinfo, boolean isDC, int tblno, /* code is now 1 more than the last code used for codelength si; but * it must still fit in si bits, since no code is allowed to be all ones. */ - if (((INT32) code) >= (((INT32) 1) << si)) + if (((JPEG_INT32) code) >= (((JPEG_INT32) 1) << si)) ERREXIT(cinfo, JERR_BAD_HUFF_TABLE); code <<= 1; si++; @@ -274,7 +274,7 @@ jpeg_make_c_derived_tbl (j_compress_ptr cinfo, boolean isDC, int tblno, { action; } } -LOCAL(boolean) +LOCAL(wxjpeg_boolean) dump_buffer (working_state * state) /* Empty the output buffer; return TRUE if successful, FALSE if must suspend */ { @@ -298,19 +298,19 @@ dump_buffer (working_state * state) */ INLINE -LOCAL(boolean) +LOCAL(wxjpeg_boolean) emit_bits (working_state * state, unsigned int code, int size) /* Emit some bits; return TRUE if successful, FALSE if must suspend */ { /* 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 = state->cur.put_bits; /* if size is 0, caller used an invalid Huffman table entry */ if (size == 0) ERREXIT(state->cinfo, JERR_HUFF_MISSING_CODE); - put_buffer &= (((INT32) 1)<entropy; @@ -641,7 +641,7 @@ htest_one_block (j_compress_ptr cinfo, JCOEFPTR block, int last_dc_val, * No data is actually output, so no suspension return is possible. */ -METHODDEF(boolean) +METHODDEF(wxjpeg_boolean) encode_mcu_gather (j_compress_ptr cinfo, JBLOCKROW *MCU_data) { huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy; @@ -849,8 +849,8 @@ finish_pass_gather (j_compress_ptr cinfo) int ci, dctbl, actbl; jpeg_component_info * compptr; JHUFF_TBL **htblptr; - boolean did_dc[NUM_HUFF_TBLS]; - boolean did_ac[NUM_HUFF_TBLS]; + wxjpeg_boolean did_dc[NUM_HUFF_TBLS]; + wxjpeg_boolean did_ac[NUM_HUFF_TBLS]; /* It's important not to apply jpeg_gen_optimal_table more than once * per table, because it clobbers the input frequency counts!