Lines Matching refs:cinfo
88 j_compress_ptr cinfo; /* dump_buffer needs access to this */
93 METHODDEF(boolean) encode_mcu_huff JPP((j_compress_ptr cinfo,
95 METHODDEF(void) finish_pass_huff JPP((j_compress_ptr cinfo));
97 METHODDEF(boolean) encode_mcu_gather JPP((j_compress_ptr cinfo,
99 METHODDEF(void) finish_pass_gather JPP((j_compress_ptr cinfo));
110 start_pass_huff (j_compress_ptr cinfo, boolean gather_statistics)
112 huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
121 ERREXIT(cinfo, JERR_NOT_COMPILED);
128 for (ci = 0; ci < cinfo->comps_in_scan; ci++) {
129 compptr = cinfo->cur_comp_info[ci];
137 ERREXIT1(cinfo, JERR_NO_HUFF_TABLE, dctbl);
139 ERREXIT1(cinfo, JERR_NO_HUFF_TABLE, actbl);
144 (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE,
149 (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE,
156 jpeg_make_c_derived_tbl(cinfo, TRUE, dctbl,
158 jpeg_make_c_derived_tbl(cinfo, FALSE, actbl,
170 entropy->restarts_to_go = cinfo->restart_interval;
183 jpeg_make_c_derived_tbl (j_compress_ptr cinfo, boolean isDC, int tblno,
199 ERREXIT1(cinfo, JERR_NO_HUFF_TABLE, tblno);
201 isDC ? cinfo->dc_huff_tbl_ptrs[tblno] : cinfo->ac_huff_tbl_ptrs[tblno];
203 ERREXIT1(cinfo, JERR_NO_HUFF_TABLE, tblno);
208 (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE,
218 ERREXIT(cinfo, JERR_BAD_HUFF_TABLE);
240 ERREXIT(cinfo, JERR_BAD_HUFF_TABLE);
264 ERREXIT(cinfo, JERR_BAD_HUFF_TABLE);
285 struct jpeg_destination_mgr * dest = state->cinfo->dest;
287 if (! (*dest->empty_output_buffer) (state->cinfo))
315 ERREXIT(state->cinfo, JERR_HUFF_MISSING_CODE);
385 ERREXIT(state->cinfo, JERR_BAD_DCT_COEF);
425 ERREXIT(state->cinfo, JERR_BAD_DCT_COEF);
466 for (ci = 0; ci < state->cinfo->comps_in_scan; ci++)
480 encode_mcu_huff (j_compress_ptr cinfo, JBLOCKROW *MCU_data)
482 huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
488 state.next_output_byte = cinfo->dest->next_output_byte;
489 state.free_in_buffer = cinfo->dest->free_in_buffer;
491 state.cinfo = cinfo;
494 if (cinfo->restart_interval) {
501 for (blkn = 0; blkn < cinfo->blocks_in_MCU; blkn++) {
502 ci = cinfo->MCU_membership[blkn];
503 compptr = cinfo->cur_comp_info[ci];
514 cinfo->dest->next_output_byte = state.next_output_byte;
515 cinfo->dest->free_in_buffer = state.free_in_buffer;
519 if (cinfo->restart_interval) {
521 entropy->restarts_to_go = cinfo->restart_interval;
537 finish_pass_huff (j_compress_ptr cinfo)
539 huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
543 state.next_output_byte = cinfo->dest->next_output_byte;
544 state.free_in_buffer = cinfo->dest->free_in_buffer;
546 state.cinfo = cinfo;
550 ERREXIT(cinfo, JERR_CANT_SUSPEND);
553 cinfo->dest->next_output_byte = state.next_output_byte;
554 cinfo->dest->free_in_buffer = state.free_in_buffer;
576 htest_one_block (j_compress_ptr cinfo, JCOEFPTR block, int last_dc_val,
599 ERREXIT(cinfo, JERR_BAD_DCT_COEF);
628 ERREXIT(cinfo, JERR_BAD_DCT_COEF);
649 encode_mcu_gather (j_compress_ptr cinfo, JBLOCKROW *MCU_data)
651 huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
656 if (cinfo->restart_interval) {
659 for (ci = 0; ci < cinfo->comps_in_scan; ci++)
662 entropy->restarts_to_go = cinfo->restart_interval;
667 for (blkn = 0; blkn < cinfo->blocks_in_MCU; blkn++) {
668 ci = cinfo->MCU_membership[blkn];
669 compptr = cinfo->cur_comp_info[ci];
670 htest_one_block(cinfo, MCU_data[blkn][0], entropy->saved.last_dc_val[ci],
709 jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[])
788 ERREXIT(cinfo, JERR_HUFF_CLEN_OVERFLOW);
850 finish_pass_gather (j_compress_ptr cinfo)
852 huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
865 for (ci = 0; ci < cinfo->comps_in_scan; ci++) {
866 compptr = cinfo->cur_comp_info[ci];
870 htblptr = & cinfo->dc_huff_tbl_ptrs[dctbl];
872 *htblptr = jpeg_alloc_huff_table((j_common_ptr) cinfo);
873 jpeg_gen_optimal_table(cinfo, *htblptr, entropy->dc_count_ptrs[dctbl]);
877 htblptr = & cinfo->ac_huff_tbl_ptrs[actbl];
879 *htblptr = jpeg_alloc_huff_table((j_common_ptr) cinfo);
880 jpeg_gen_optimal_table(cinfo, *htblptr, entropy->ac_count_ptrs[actbl]);
895 jinit_huff_encoder (j_compress_ptr cinfo)
901 (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE,
903 cinfo->entropy = (struct jpeg_entropy_encoder *) entropy;