19 #define JPEG_INTERNALS 52 #ifdef QUANT_2PASS_SUPPORTED 79 if (cinfo->quantize_colors) {
86 if (post->
buffer == NULL) {
87 post->
buffer = (*cinfo->mem->access_virt_sarray)
95 post->
pub.post_process_data = cinfo->upsample->upsample;
98 #ifdef QUANT_2PASS_SUPPORTED 102 ERREXIT(cinfo, JERR_BAD_BUFFER_MODE);
108 ERREXIT(cinfo, JERR_BAD_BUFFER_MODE);
113 ERREXIT(cinfo, JERR_BAD_BUFFER_MODE);
137 max_rows = out_rows_avail - *out_row_ctr;
141 (*cinfo->upsample->upsample) (cinfo,
142 input_buf, in_row_group_ctr, in_row_groups_avail,
143 post->
buffer, &num_rows, max_rows);
145 (*cinfo->cquantize->color_quantize) (cinfo,
151 #ifdef QUANT_2PASS_SUPPORTED 169 post->
buffer = (*cinfo->mem->access_virt_sarray)
176 (*cinfo->upsample->upsample) (cinfo,
177 input_buf, in_row_group_ctr, in_row_groups_avail,
182 if (post->
next_row > old_next_row) {
184 (*cinfo->cquantize->color_quantize) (cinfo, post->
buffer + old_next_row,
213 post->
buffer = (*cinfo->mem->access_virt_sarray)
220 max_rows = out_rows_avail - *out_row_ctr;
229 (*cinfo->cquantize->color_quantize) (cinfo,
258 post->
pub.start_pass = start_pass_dpost;
263 if (cinfo->quantize_colors) {
272 #ifdef QUANT_2PASS_SUPPORTED 273 post->
whole_image = (*cinfo->mem->request_virt_sarray)
275 cinfo->output_width * cinfo->out_color_components,
280 ERREXIT(cinfo, JERR_BAD_BUFFER_MODE);
284 post->
buffer = (*cinfo->mem->alloc_sarray)
286 cinfo->output_width * cinfo->out_color_components,
struct jpeg_common_struct * j_common_ptr
#define ERREXIT(cinfo, code)
jinit_d_post_controller(j_decompress_ptr cinfo, boolean need_full_buffer)
struct jpeg_d_post_controller pub
jround_up(long a, long b)
int JSAMPARRAY int int num_rows
post_process_prepass(j_decompress_ptr cinfo, JSAMPIMAGE input_buf, JDIMENSION *in_row_group_ctr, JDIMENSION in_row_groups_avail, JSAMPARRAY output_buf, JDIMENSION *out_row_ctr, JDIMENSION out_rows_avail)
post_process_1pass(j_decompress_ptr cinfo, JSAMPIMAGE input_buf, JDIMENSION *in_row_group_ctr, JDIMENSION in_row_groups_avail, JSAMPARRAY output_buf, JDIMENSION *out_row_ctr, JDIMENSION out_rows_avail)
jpeg_component_info JCOEFPTR JSAMPARRAY output_buf
post_process_2pass(j_decompress_ptr cinfo, JSAMPIMAGE input_buf, JDIMENSION *in_row_group_ctr, JDIMENSION in_row_groups_avail, JSAMPARRAY output_buf, JDIMENSION *out_row_ctr, JDIMENSION out_rows_avail)
jvirt_sarray_ptr whole_image
my_post_controller * my_post_ptr