Lines Matching refs:cquantize
277 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in create_colormap() local
283 total_colors = select_ncolors(cinfo, cquantize->Ncolors); in create_colormap()
288 total_colors, cquantize->Ncolors[0], in create_colormap()
289 cquantize->Ncolors[1], cquantize->Ncolors[2]); in create_colormap()
307 nci = cquantize->Ncolors[i]; /* # of distinct values for this color */ in create_colormap()
325 cquantize->sv_colormap = colormap; in create_colormap()
326 cquantize->sv_actual = total_colors; in create_colormap()
337 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in create_colorindex() local
348 cquantize->is_padded = TRUE; in create_colorindex()
351 cquantize->is_padded = FALSE; in create_colorindex()
354 cquantize->colorindex = (*cinfo->mem->alloc_sarray) in create_colorindex()
360 blksize = cquantize->sv_actual; in create_colorindex()
364 nci = cquantize->Ncolors[i]; /* # of distinct values for this color */ in create_colorindex()
369 cquantize->colorindex[i] += MAXJSAMPLE; in create_colorindex()
373 indexptr = cquantize->colorindex[i]; in create_colorindex()
436 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in create_odither_tables() local
441 nci = cquantize->Ncolors[i]; /* # of distinct values for this color */ in create_odither_tables()
444 if (nci == cquantize->Ncolors[j]) { in create_odither_tables()
445 odither = cquantize->odither[j]; in create_odither_tables()
451 cquantize->odither[i] = odither; in create_odither_tables()
465 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in color_quantize() local
466 JSAMPARRAY colorindex = cquantize->colorindex; in color_quantize()
493 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in color_quantize3() local
496 JSAMPROW colorindex0 = cquantize->colorindex[0]; in color_quantize3()
497 JSAMPROW colorindex1 = cquantize->colorindex[1]; in color_quantize3()
498 JSAMPROW colorindex2 = cquantize->colorindex[2]; in color_quantize3()
521 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in quantize_ord_dither() local
536 row_index = cquantize->row_index; in quantize_ord_dither()
540 colorindex_ci = cquantize->colorindex[ci]; in quantize_ord_dither()
541 dither = cquantize->odither[ci][row_index]; in quantize_ord_dither()
560 cquantize->row_index = row_index; in quantize_ord_dither()
570 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in quantize3_ord_dither() local
574 JSAMPROW colorindex0 = cquantize->colorindex[0]; in quantize3_ord_dither()
575 JSAMPROW colorindex1 = cquantize->colorindex[1]; in quantize3_ord_dither()
576 JSAMPROW colorindex2 = cquantize->colorindex[2]; in quantize3_ord_dither()
586 row_index = cquantize->row_index; in quantize3_ord_dither()
589 dither0 = cquantize->odither[0][row_index]; in quantize3_ord_dither()
590 dither1 = cquantize->odither[1][row_index]; in quantize3_ord_dither()
591 dither2 = cquantize->odither[2][row_index]; in quantize3_ord_dither()
605 cquantize->row_index = row_index; in quantize3_ord_dither()
615 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in quantize_fs_dither() local
643 if (cquantize->on_odd_row) { in quantize_fs_dither()
649 errorptr = cquantize->fserrors[ci] + (width+1); /* => entry after last column */ in quantize_fs_dither()
654 errorptr = cquantize->fserrors[ci]; /* => entry before first column */ in quantize_fs_dither()
656 colorindex_ci = cquantize->colorindex[ci]; in quantize_fs_dither()
657 colormap_ci = cquantize->sv_colormap[ci]; in quantize_fs_dither()
712 cquantize->on_odd_row = (cquantize->on_odd_row ? FALSE : TRUE); in quantize_fs_dither()
724 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in alloc_fs_workspace() local
730 cquantize->fserrors[i] = (FSERRPTR) in alloc_fs_workspace()
743 my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize; in start_pass_1_quant() local
748 cinfo->colormap = cquantize->sv_colormap; in start_pass_1_quant()
749 cinfo->actual_number_of_colors = cquantize->sv_actual; in start_pass_1_quant()
755 cquantize->pub.color_quantize = color_quantize3; in start_pass_1_quant()
757 cquantize->pub.color_quantize = color_quantize; in start_pass_1_quant()
761 cquantize->pub.color_quantize = quantize3_ord_dither; in start_pass_1_quant()
763 cquantize->pub.color_quantize = quantize_ord_dither; in start_pass_1_quant()
764 cquantize->row_index = 0; /* initialize state for ordered dither */ in start_pass_1_quant()
769 if (! cquantize->is_padded) in start_pass_1_quant()
772 if (cquantize->odither[0] == NULL) in start_pass_1_quant()
776 cquantize->pub.color_quantize = quantize_fs_dither; in start_pass_1_quant()
777 cquantize->on_odd_row = FALSE; /* initialize state for F-S dither */ in start_pass_1_quant()
779 if (cquantize->fserrors[0] == NULL) in start_pass_1_quant()
784 jzero_far((void *) cquantize->fserrors[i], arraysize); in start_pass_1_quant()
823 my_cquantize_ptr cquantize; in jinit_1pass_quantizer() local
825 cquantize = (my_cquantize_ptr) in jinit_1pass_quantizer()
828 cinfo->cquantize = (struct jpeg_color_quantizer *) cquantize; in jinit_1pass_quantizer()
829 cquantize->pub.start_pass = start_pass_1_quant; in jinit_1pass_quantizer()
830 cquantize->pub.finish_pass = finish_pass_1_quant; in jinit_1pass_quantizer()
831 cquantize->pub.new_color_map = new_color_map_1_quant; in jinit_1pass_quantizer()
832 cquantize->fserrors[0] = NULL; /* Flag FS workspace not allocated */ in jinit_1pass_quantizer()
833 cquantize->odither[0] = NULL; /* Also flag odither arrays not allocated */ in jinit_1pass_quantizer()