亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來(lái)到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? jquant1.c

?? 一款最完整的工業(yè)組態(tài)軟源代碼
?? C
?? 第 1 頁(yè) / 共 3 頁(yè)
字號(hào):
	     cquantize->Ncolors[1], cquantize->Ncolors[2]);
  else
    TRACEMS1(cinfo, 1, JTRC_QUANT_NCOLORS, total_colors);

  /* Allocate and fill in the colormap. */
  /* The colors are ordered in the map in standard row-major order, */
  /* i.e. rightmost (highest-indexed) color changes most rapidly. */

  colormap = (*cinfo->mem->alloc_sarray)
    ((j_common_ptr) cinfo, JPOOL_IMAGE,
     (JDIMENSION) total_colors, (JDIMENSION) cinfo->out_color_components);

  /* blksize is number of adjacent repeated entries for a component */
  /* blkdist is distance between groups of identical entries for a component */
  blkdist = total_colors;

  for (i = 0; i < cinfo->out_color_components; i++) {
    /* fill in colormap entries for i'th color component */
    nci = cquantize->Ncolors[i]; /* # of distinct values for this color */
    blksize = blkdist / nci;
    for (j = 0; j < nci; j++) {
      /* Compute j'th output value (out of nci) for component */
      val = output_value(cinfo, i, j, nci-1);
      /* Fill in all colormap entries that have this value of this component */
      for (ptr = j * blksize; ptr < total_colors; ptr += blkdist) {
	/* fill in blksize entries beginning at ptr */
	for (k = 0; k < blksize; k++)
	  colormap[i][ptr+k] = (JSAMPLE) val;
      }
    }
    blkdist = blksize;		/* blksize of this color is blkdist of next */
  }

  /* Save the colormap in private storage,
   * where it will survive color quantization mode changes.
   */
  cquantize->sv_colormap = colormap;
  cquantize->sv_actual = total_colors;
}


/*
 * Create the color index table.
 */

LOCAL(void)
create_colorindex (j_decompress_ptr cinfo)
{
  my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize;
  JSAMPROW indexptr;
  int i,j,k, nci, blksize, val, pad;

  /* For ordered dither, we pad the color index tables by MAXJSAMPLE in
   * each direction (input index values can be -MAXJSAMPLE .. 2*MAXJSAMPLE).
   * This is not necessary in the other dithering modes.  However, we
   * flag whether it was done in case user changes dithering mode.
   */
  if (cinfo->dither_mode == JDITHER_ORDERED) {
    pad = MAXJSAMPLE*2;
    cquantize->is_padded = TRUE;
  } else {
    pad = 0;
    cquantize->is_padded = FALSE;
  }

  cquantize->colorindex = (*cinfo->mem->alloc_sarray)
    ((j_common_ptr) cinfo, JPOOL_IMAGE,
     (JDIMENSION) (MAXJSAMPLE+1 + pad),
     (JDIMENSION) cinfo->out_color_components);

  /* blksize is number of adjacent repeated entries for a component */
  blksize = cquantize->sv_actual;

  for (i = 0; i < cinfo->out_color_components; i++) {
    /* fill in colorindex entries for i'th color component */
    nci = cquantize->Ncolors[i]; /* # of distinct values for this color */
    blksize = blksize / nci;

    /* adjust colorindex pointers to provide padding at negative indexes. */
    if (pad)
      cquantize->colorindex[i] += MAXJSAMPLE;

    /* in loop, val = index of current output value, */
    /* and k = largest j that maps to current val */
    indexptr = cquantize->colorindex[i];
    val = 0;
    k = largest_input_value(cinfo, i, 0, nci-1);
    for (j = 0; j <= MAXJSAMPLE; j++) {
      while (j > k)		/* advance val if past boundary */
	k = largest_input_value(cinfo, i, ++val, nci-1);
      /* premultiply so that no multiplication needed in main processing */
      indexptr[j] = (JSAMPLE) (val * blksize);
    }
    /* Pad at both ends if necessary */
    if (pad)
      for (j = 1; j <= MAXJSAMPLE; j++) {
	indexptr[-j] = indexptr[0];
	indexptr[MAXJSAMPLE+j] = indexptr[MAXJSAMPLE];
      }
  }
}


/*
 * Create an ordered-dither array for a component having ncolors
 * distinct output values.
 */

LOCAL(ODITHER_MATRIX_PTR)
make_odither_array (j_decompress_ptr cinfo, int ncolors)
{
  ODITHER_MATRIX_PTR odither;
  int j,k;
  INT32 num,den;

  odither = (ODITHER_MATRIX_PTR)
    (*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_IMAGE,
				SIZEOF(ODITHER_MATRIX));
  /* The inter-value distance for this color is MAXJSAMPLE/(ncolors-1).
   * Hence the dither value for the matrix cell with fill order f
   * (f=0..N-1) should be (N-1-2*f)/(2*N) * MAXJSAMPLE/(ncolors-1).
   * On 16-bit-int machine, be careful to avoid overflow.
   */
  den = 2 * ODITHER_CELLS * ((INT32) (ncolors - 1));
  for (j = 0; j < ODITHER_SIZE; j++) {
    for (k = 0; k < ODITHER_SIZE; k++) {
      num = ((INT32) (ODITHER_CELLS-1 - 2*((int)base_dither_matrix[j][k])))
	    * MAXJSAMPLE;
      /* Ensure round towards zero despite C's lack of consistency
       * about rounding negative values in integer division...
       */
      odither[j][k] = (int) (num<0 ? -((-num)/den) : num/den);
    }
  }
  return odither;
}


/*
 * Create the ordered-dither tables.
 * Components having the same number of representative colors may 
 * share a dither table.
 */

LOCAL(void)
create_odither_tables (j_decompress_ptr cinfo)
{
  my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize;
  ODITHER_MATRIX_PTR odither;
  int i, j, nci;

  for (i = 0; i < cinfo->out_color_components; i++) {
    nci = cquantize->Ncolors[i]; /* # of distinct values for this color */
    odither = NULL;		/* search for matching prior component */
    for (j = 0; j < i; j++) {
      if (nci == cquantize->Ncolors[j]) {
	odither = cquantize->odither[j];
	break;
      }
    }
    if (odither == NULL)	/* need a new table? */
      odither = make_odither_array(cinfo, nci);
    cquantize->odither[i] = odither;
  }
}


/*
 * Map some rows of pixels to the output colormapped representation.
 */

METHODDEF(void)
color_quantize (j_decompress_ptr cinfo, JSAMPARRAY input_buf,
		JSAMPARRAY output_buf, int num_rows)
/* General case, no dithering */
{
  my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize;
  JSAMPARRAY colorindex = cquantize->colorindex;
  register int pixcode, ci;
  register JSAMPROW ptrin, ptrout;
  int row;
  JDIMENSION col;
  JDIMENSION width = cinfo->output_width;
  register int nc = cinfo->out_color_components;

  for (row = 0; row < num_rows; row++) {
    ptrin = input_buf[row];
    ptrout = output_buf[row];
    for (col = width; col > 0; col--) {
      pixcode = 0;
      for (ci = 0; ci < nc; ci++) {
	pixcode += GETJSAMPLE(colorindex[ci][GETJSAMPLE(*ptrin++)]);
      }
      *ptrout++ = (JSAMPLE) pixcode;
    }
  }
}


METHODDEF(void)
color_quantize3 (j_decompress_ptr cinfo, JSAMPARRAY input_buf,
		 JSAMPARRAY output_buf, int num_rows)
/* Fast path for out_color_components==3, no dithering */
{
  my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize;
  register int pixcode;
  register JSAMPROW ptrin, ptrout;
  JSAMPROW colorindex0 = cquantize->colorindex[0];
  JSAMPROW colorindex1 = cquantize->colorindex[1];
  JSAMPROW colorindex2 = cquantize->colorindex[2];
  int row;
  JDIMENSION col;
  JDIMENSION width = cinfo->output_width;

  for (row = 0; row < num_rows; row++) {
    ptrin = input_buf[row];
    ptrout = output_buf[row];
    for (col = width; col > 0; col--) {
      pixcode  = GETJSAMPLE(colorindex0[GETJSAMPLE(*ptrin++)]);
      pixcode += GETJSAMPLE(colorindex1[GETJSAMPLE(*ptrin++)]);
      pixcode += GETJSAMPLE(colorindex2[GETJSAMPLE(*ptrin++)]);
      *ptrout++ = (JSAMPLE) pixcode;
    }
  }
}


METHODDEF(void)
quantize_ord_dither (j_decompress_ptr cinfo, JSAMPARRAY input_buf,
		     JSAMPARRAY output_buf, int num_rows)
/* General case, with ordered dithering */
{
  my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize;
  register JSAMPROW input_ptr;
  register JSAMPROW output_ptr;
  JSAMPROW colorindex_ci;
  int * dither;			/* points to active row of dither matrix */
  int row_index, col_index;	/* current indexes into dither matrix */
  int nc = cinfo->out_color_components;
  int ci;
  int row;
  JDIMENSION col;
  JDIMENSION width = cinfo->output_width;

  for (row = 0; row < num_rows; row++) {
    /* Initialize output values to 0 so can process components separately */
    jzero_far((void FAR *) output_buf[row],
	      (size_t) (width * SIZEOF(JSAMPLE)));
    row_index = cquantize->row_index;
    for (ci = 0; ci < nc; ci++) {
      input_ptr = input_buf[row] + ci;
      output_ptr = output_buf[row];
      colorindex_ci = cquantize->colorindex[ci];
      dither = cquantize->odither[ci][row_index];
      col_index = 0;

      for (col = width; col > 0; col--) {
	/* Form pixel value + dither, range-limit to 0..MAXJSAMPLE,
	 * select output value, accumulate into output code for this pixel.
	 * Range-limiting need not be done explicitly, as we have extended
	 * the colorindex table to produce the right answers for out-of-range
	 * inputs.  The maximum dither is +- MAXJSAMPLE; this sets the
	 * required amount of padding.
	 */
	*output_ptr += colorindex_ci[GETJSAMPLE(*input_ptr)+dither[col_index]];
	input_ptr += nc;
	output_ptr++;
	col_index = (col_index + 1) & ODITHER_MASK;
      }
    }
    /* Advance row index for next row */
    row_index = (row_index + 1) & ODITHER_MASK;
    cquantize->row_index = row_index;
  }
}


METHODDEF(void)
quantize3_ord_dither (j_decompress_ptr cinfo, JSAMPARRAY input_buf,
		      JSAMPARRAY output_buf, int num_rows)
/* Fast path for out_color_components==3, with ordered dithering */
{
  my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize;
  register int pixcode;
  register JSAMPROW input_ptr;
  register JSAMPROW output_ptr;

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美电视剧免费全集观看| 国产美女精品人人做人人爽| 99久久99久久久精品齐齐| 中文字幕国产一区| jlzzjlzz亚洲日本少妇| 中文字幕在线观看不卡| 91免费版pro下载短视频| 中文字幕一区二区三区在线观看| 99视频国产精品| 一区二区三区丝袜| 欧美日本在线看| 麻豆成人91精品二区三区| 欧美精品一区二区久久久| 成人精品一区二区三区四区 | 成人综合在线视频| 中文字幕精品综合| 91国产精品成人| 日本三级亚洲精品| 国产色91在线| 在线视频你懂得一区| 日本成人在线电影网| 国产亚洲成av人在线观看导航| 9人人澡人人爽人人精品| 亚洲午夜日本在线观看| 久久亚洲春色中文字幕久久久| caoporn国产精品| 日韩av电影天堂| 欧美国产成人在线| 欧美久久久久久蜜桃| 国产福利91精品一区二区三区| 亚洲精品欧美激情| 日韩视频国产视频| 色综合天天综合网国产成人综合天 | 99视频国产精品| 日韩av一区二区三区四区| 国产精品三级在线观看| 欧美精品tushy高清| 波多野结衣亚洲一区| 日韩av网站免费在线| 亚洲日本一区二区| 久久综合九色综合欧美98| 欧美午夜精品一区二区三区| 高清不卡在线观看av| 男女性色大片免费观看一区二区 | 蜜臀av一区二区在线免费观看| 国产精品无人区| 欧美电影免费观看高清完整版| 91丝袜国产在线播放| 国产一区在线看| 日日夜夜一区二区| 亚洲女子a中天字幕| 久久久综合网站| 日韩欧美高清dvd碟片| 在线观看视频91| 福利一区二区在线| 国内久久婷婷综合| 日韩在线一二三区| 亚洲成人第一页| 亚洲欧洲一区二区在线播放| 日韩免费观看2025年上映的电影| 欧美四级电影网| av在线播放不卡| 国产精品911| 精品在线亚洲视频| 日本欧美加勒比视频| 亚洲成a人片在线观看中文| 国产精品麻豆视频| 欧美国产精品一区二区三区| 久久久久综合网| 久久精品一二三| 国产午夜精品一区二区三区嫩草| 日韩免费看的电影| 日韩三级高清在线| 日韩午夜激情免费电影| 欧美一区二区性放荡片| 在线综合亚洲欧美在线视频| 欧美欧美午夜aⅴ在线观看| 欧美视频精品在线观看| 欧美性大战久久| 欧美日韩免费一区二区三区 | 91在线播放网址| 成人久久久精品乱码一区二区三区| 福利一区二区在线观看| 国产.欧美.日韩| 国产一区二区看久久| 国产91精品久久久久久久网曝门| 国产成人免费视频一区| 成人激情免费视频| 97久久精品人人做人人爽50路| 91色在线porny| 色婷婷一区二区| 欧美久久婷婷综合色| 精品免费国产一区二区三区四区| 精品国产伦一区二区三区观看方式| 久久久亚洲精华液精华液精华液 | 日韩三级在线免费观看| www国产精品av| 中文字幕一区二区三区不卡 | 蜜桃视频在线一区| 国产成人99久久亚洲综合精品| 风间由美一区二区三区在线观看| 91丨九色porny丨蝌蚪| 91传媒视频在线播放| 91精品国产aⅴ一区二区| 精品国产91乱码一区二区三区| 国产婷婷精品av在线| 亚洲欧美aⅴ...| 蜜臀av一区二区| 99在线精品视频| 欧美日韩欧美一区二区| 久久免费看少妇高潮| 亚洲婷婷在线视频| 蜜桃精品视频在线观看| 成人精品小蝌蚪| 日韩一区二区三区视频在线| 国产欧美一区二区精品忘忧草 | 日本免费在线视频不卡一不卡二| 国产精品18久久久久久vr| 一本高清dvd不卡在线观看| 欧美一级二级在线观看| 国产精品久久久久影院| 日韩经典中文字幕一区| 成人网页在线观看| 欧美日韩的一区二区| 国产精品美女久久久久av爽李琼 | 亚洲精品一二三| 国产综合久久久久久久久久久久| 一本久久a久久精品亚洲| 日韩亚洲欧美高清| 亚洲乱码国产乱码精品精的特点| 精品一区二区在线播放| 欧美亚洲精品一区| 国产精品不卡在线| 国内精品伊人久久久久av影院| 欧美影院精品一区| 中文字幕中文字幕一区| 精品一区二区免费在线观看| 欧美亚洲一区二区在线观看| 日本一区二区三区国色天香| 日韩精品五月天| 欧美性生交片4| 亚洲天堂精品在线观看| 国产成人av电影在线播放| 日韩视频一区二区在线观看| 一区二区三区四区不卡视频| 成人午夜大片免费观看| 久久精品日产第一区二区三区高清版| 亚洲18色成人| 91久久国产最好的精华液| 国产精品三级av在线播放| 国产真实乱对白精彩久久| 91精品国产综合久久福利| 亚洲一区在线视频观看| 99国产精品国产精品毛片| 日本一区二区三级电影在线观看| 蜜桃一区二区三区在线观看| 91麻豆精品国产自产在线| 亚洲激情图片一区| 成人精品一区二区三区中文字幕| 精品福利一区二区三区免费视频| 日韩成人免费在线| 欧美精品精品一区| 亚州成人在线电影| 欧美日韩在线三区| 亚洲a一区二区| 欧美一区二区在线免费观看| 三级成人在线视频| 日韩欧美色综合| 国产一区二区在线免费观看| 精品日韩一区二区三区| 精品在线一区二区三区| 久久久国产一区二区三区四区小说 | 欧美一区二区三级| 久久精品国产77777蜜臀| 精品国产一区二区三区久久影院| 另类人妖一区二区av| 久久综合久久鬼色中文字| 国产成人aaa| 亚洲欧洲99久久| 欧美无人高清视频在线观看| 香蕉影视欧美成人| 精品国产一区二区国模嫣然| 国产精品一区二区在线观看网站 | 蓝色福利精品导航| 国产欧美日韩久久| 色偷偷久久一区二区三区| 一区二区三区日韩在线观看| 欧美日韩精品一区二区天天拍小说| 日韩精品视频网站| 久久午夜老司机| aa级大片欧美| 水野朝阳av一区二区三区| 久久婷婷国产综合精品青草| 成人精品电影在线观看| 亚洲欧美色一区| 欧美成人一区二区三区片免费| 粗大黑人巨茎大战欧美成人| 一区二区三区在线观看视频| 欧美一区二区三区在线观看| 国产精品1024|