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

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

?? jdapistd.c

?? 常好且全面的jpeg圖像壓縮算法
?? C
字號:
/*
 * jdapistd.c
 *
 * Copyright (C) 1994-1996, Thomas G. Lane.
 * This file is part of the Independent JPEG Group's software.
 * For conditions of distribution and use, see the accompanying README file.
 *
 * This file contains application interface code for the decompression half
 * of the JPEG library.  These are the "standard" API routines that are
 * used in the normal full-decompression case.  They are not used by a
 * transcoding-only application.  Note that if an application links in
 * jpeg_start_decompress, it will end up linking in the entire decompressor.
 * We thus must separate this file from jdapimin.c to avoid linking the
 * whole decompression library into a transcoder.
 */

#define JPEG_INTERNALS
#include "jinclude.h"
#include "jpeglib.h"


/* Forward declarations */
LOCAL(boolean) output_pass_setup JPP((j_decompress_ptr cinfo));


/*
 * Decompression initialization.
 * jpeg_read_header must be completed before calling this.
 *
 * If a multipass operating mode was selected, this will do all but the
 * last pass, and thus may take a great deal of time.
 *
 * Returns FALSE if suspended.  The return value need be inspected only if
 * a suspending data source is used.
 */

GLOBAL(boolean)
jpeg_start_decompress (j_decompress_ptr cinfo)
{
  if (cinfo->global_state == DSTATE_READY) {
    /* First call: initialize master control, select active modules */
    jinit_master_decompress(cinfo);
    if (cinfo->buffered_image) {
      /* No more work here; expecting jpeg_start_output next */
      cinfo->global_state = DSTATE_BUFIMAGE;
      return TRUE;
    }
    cinfo->global_state = DSTATE_PRELOAD;
  }
  if (cinfo->global_state == DSTATE_PRELOAD) {
    /* If file has multiple scans, absorb them all into the coef buffer */
    if (cinfo->inputctl->has_multiple_scans) {
#ifdef D_MULTISCAN_FILES_SUPPORTED
      for (;;) {
	int retcode;
	/* Call progress monitor hook if present */
	if (cinfo->progress != NULL)
	  (*cinfo->progress->progress_monitor) ((j_common_ptr) cinfo);
	/* Absorb some more input */
	retcode = (*cinfo->inputctl->consume_input) (cinfo);
	if (retcode == JPEG_SUSPENDED)
	  return FALSE;
	if (retcode == JPEG_REACHED_EOI)
	  break;
	/* Advance progress counter if appropriate */
	if (cinfo->progress != NULL &&
	    (retcode == JPEG_ROW_COMPLETED || retcode == JPEG_REACHED_SOS)) {
	  if (++cinfo->progress->pass_counter >= cinfo->progress->pass_limit) {
	    /* jdmaster underestimated number of scans; ratchet up one scan */
	    cinfo->progress->pass_limit += (long) cinfo->total_iMCU_rows;
	  }
	}
      }
#else
      ERREXIT(cinfo, JERR_NOT_COMPILED);
#endif /* D_MULTISCAN_FILES_SUPPORTED */
    }
    cinfo->output_scan_number = cinfo->input_scan_number;
  } else if (cinfo->global_state != DSTATE_PRESCAN)
    ERREXIT1(cinfo, JERR_BAD_STATE, cinfo->global_state);
  /* Perform any dummy output passes, and set up for the final pass */
  return output_pass_setup(cinfo);
}


/*
 * Set up for an output pass, and perform any dummy pass(es) needed.
 * Common subroutine for jpeg_start_decompress and jpeg_start_output.
 * Entry: global_state = DSTATE_PRESCAN only if previously suspended.
 * Exit: If done, returns TRUE and sets global_state for proper output mode.
 *       If suspended, returns FALSE and sets global_state = DSTATE_PRESCAN.
 */

LOCAL(boolean)
output_pass_setup (j_decompress_ptr cinfo)
{
  if (cinfo->global_state != DSTATE_PRESCAN) {
    /* First call: do pass setup */
    (*cinfo->master->prepare_for_output_pass) (cinfo);
    cinfo->output_scanline = 0;
    cinfo->global_state = DSTATE_PRESCAN;
  }
  /* Loop over any required dummy passes */
  while (cinfo->master->is_dummy_pass) {
#ifdef QUANT_2PASS_SUPPORTED
    /* Crank through the dummy pass */
    while (cinfo->output_scanline < cinfo->output_height) {
      JDIMENSION last_scanline;
      /* Call progress monitor hook if present */
      if (cinfo->progress != NULL) {
	cinfo->progress->pass_counter = (long) cinfo->output_scanline;
	cinfo->progress->pass_limit = (long) cinfo->output_height;
	(*cinfo->progress->progress_monitor) ((j_common_ptr) cinfo);
      }
      /* Process some data */
      last_scanline = cinfo->output_scanline;
      (*cinfo->main->process_data) (cinfo, (JSAMPARRAY) NULL,
				    &cinfo->output_scanline, (JDIMENSION) 0);
      if (cinfo->output_scanline == last_scanline)
	return FALSE;		/* No progress made, must suspend */
    }
    /* Finish up dummy pass, and set up for another one */
    (*cinfo->master->finish_output_pass) (cinfo);
    (*cinfo->master->prepare_for_output_pass) (cinfo);
    cinfo->output_scanline = 0;
#else
    ERREXIT(cinfo, JERR_NOT_COMPILED);
#endif /* QUANT_2PASS_SUPPORTED */
  }
  /* Ready for application to drive output pass through
   * jpeg_read_scanlines or jpeg_read_raw_data.
   */
  cinfo->global_state = cinfo->raw_data_out ? DSTATE_RAW_OK : DSTATE_SCANNING;
  return TRUE;
}


/*
 * Read some scanlines of data from the JPEG decompressor.
 *
 * The return value will be the number of lines actually read.
 * This may be less than the number requested in several cases,
 * including bottom of image, data source suspension, and operating
 * modes that emit multiple scanlines at a time.
 *
 * Note: we warn about excess calls to jpeg_read_scanlines() since
 * this likely signals an application programmer error.  However,
 * an oversize buffer (max_lines > scanlines remaining) is not an error.
 */

GLOBAL(JDIMENSION)
jpeg_read_scanlines (j_decompress_ptr cinfo, JSAMPARRAY scanlines,
		     JDIMENSION max_lines)
{
  JDIMENSION row_ctr;

  if (cinfo->global_state != DSTATE_SCANNING)
    ERREXIT1(cinfo, JERR_BAD_STATE, cinfo->global_state);
  if (cinfo->output_scanline >= cinfo->output_height) {
    WARNMS(cinfo, JWRN_TOO_MUCH_DATA);
    return 0;
  }

  /* Call progress monitor hook if present */
  if (cinfo->progress != NULL) {
    cinfo->progress->pass_counter = (long) cinfo->output_scanline;
    cinfo->progress->pass_limit = (long) cinfo->output_height;
    (*cinfo->progress->progress_monitor) ((j_common_ptr) cinfo);
  }

  /* Process some data */
  row_ctr = 0;
  (*cinfo->main->process_data) (cinfo, scanlines, &row_ctr, max_lines);
  cinfo->output_scanline += row_ctr;
  return row_ctr;
}


/*
 * Alternate entry point to read raw data.
 * Processes exactly one iMCU row per call, unless suspended.
 */

GLOBAL(JDIMENSION)
jpeg_read_raw_data (j_decompress_ptr cinfo, JSAMPIMAGE data,
		    JDIMENSION max_lines)
{
  JDIMENSION lines_per_iMCU_row;

  if (cinfo->global_state != DSTATE_RAW_OK)
    ERREXIT1(cinfo, JERR_BAD_STATE, cinfo->global_state);
  if (cinfo->output_scanline >= cinfo->output_height) {
    WARNMS(cinfo, JWRN_TOO_MUCH_DATA);
    return 0;
  }

  /* Call progress monitor hook if present */
  if (cinfo->progress != NULL) {
    cinfo->progress->pass_counter = (long) cinfo->output_scanline;
    cinfo->progress->pass_limit = (long) cinfo->output_height;
    (*cinfo->progress->progress_monitor) ((j_common_ptr) cinfo);
  }

  /* Verify that at least one iMCU row can be returned. */
  lines_per_iMCU_row = cinfo->max_v_samp_factor * cinfo->min_DCT_scaled_size;
  if (max_lines < lines_per_iMCU_row)
    ERREXIT(cinfo, JERR_BUFFER_SIZE);

  /* Decompress directly into user's buffer. */
  if (! (*cinfo->coef->decompress_data) (cinfo, data))
    return 0;			/* suspension forced, can do nothing more */

  /* OK, we processed one iMCU row. */
  cinfo->output_scanline += lines_per_iMCU_row;
  return lines_per_iMCU_row;
}


/* Additional entry points for buffered-image mode. */

#ifdef D_MULTISCAN_FILES_SUPPORTED

/*
 * Initialize for an output pass in buffered-image mode.
 */

GLOBAL(boolean)
jpeg_start_output (j_decompress_ptr cinfo, int scan_number)
{
  if (cinfo->global_state != DSTATE_BUFIMAGE &&
      cinfo->global_state != DSTATE_PRESCAN)
    ERREXIT1(cinfo, JERR_BAD_STATE, cinfo->global_state);
  /* Limit scan number to valid range */
  if (scan_number <= 0)
    scan_number = 1;
  if (cinfo->inputctl->eoi_reached &&
      scan_number > cinfo->input_scan_number)
    scan_number = cinfo->input_scan_number;
  cinfo->output_scan_number = scan_number;
  /* Perform any dummy output passes, and set up for the real pass */
  return output_pass_setup(cinfo);
}


/*
 * Finish up after an output pass in buffered-image mode.
 *
 * Returns FALSE if suspended.  The return value need be inspected only if
 * a suspending data source is used.
 */

GLOBAL(boolean)
jpeg_finish_output (j_decompress_ptr cinfo)
{
  if ((cinfo->global_state == DSTATE_SCANNING ||
       cinfo->global_state == DSTATE_RAW_OK) && cinfo->buffered_image) {
    /* Terminate this pass. */
    /* We do not require the whole pass to have been completed. */
    (*cinfo->master->finish_output_pass) (cinfo);
    cinfo->global_state = DSTATE_BUFPOST;
  } else if (cinfo->global_state != DSTATE_BUFPOST) {
    /* BUFPOST = repeat call after a suspension, anything else is error */
    ERREXIT1(cinfo, JERR_BAD_STATE, cinfo->global_state);
  }
  /* Read markers looking for SOS or EOI */
  while (cinfo->input_scan_number <= cinfo->output_scan_number &&
	 ! cinfo->inputctl->eoi_reached) {
    if ((*cinfo->inputctl->consume_input) (cinfo) == JPEG_SUSPENDED)
      return FALSE;		/* Suspend, come back later */
  }
  cinfo->global_state = DSTATE_BUFIMAGE;
  return TRUE;
}

#endif /* D_MULTISCAN_FILES_SUPPORTED */

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
狠狠色丁香久久婷婷综| 亚洲第一成年网| 蜜桃视频免费观看一区| 99精品视频一区| 亚洲精品一区二区三区四区高清| 一区二区三区精品在线观看| 高清在线不卡av| 日韩精品在线网站| 亚洲国产另类av| 色狠狠色狠狠综合| 中文字幕精品—区二区四季| 黄网站免费久久| 日韩视频在线一区二区| 婷婷丁香激情综合| 欧美性大战久久久久久久| 中文字幕综合网| 懂色av中文字幕一区二区三区| 精品成人一区二区三区四区| 五月天精品一区二区三区| 91成人在线观看喷潮| 中文字幕亚洲不卡| 国产成人免费高清| 久久久久久电影| 久草热8精品视频在线观看| 欧美一级爆毛片| 日韩一区精品字幕| 欧美日韩精品一区二区三区四区| 亚洲制服丝袜一区| 一本色道久久综合狠狠躁的推荐| 国产精品少妇自拍| 成人丝袜视频网| 国产免费成人在线视频| 国产乱码精品1区2区3区| 精品久久久久久亚洲综合网| 久久精品国产网站| 日韩欧美国产三级| 久久99久久99精品免视看婷婷 | 波多野结衣在线一区| 久久精品视频在线免费观看| 黑人精品欧美一区二区蜜桃 | 欧美色视频在线观看| 亚洲激情图片qvod| 欧美主播一区二区三区| 亚洲图片欧美综合| 欧美日韩一区国产| 三级在线观看一区二区| 欧美一区二区视频在线观看| 日本免费新一区视频| 日韩欧美精品在线| 国产精品综合一区二区三区| 久久久一区二区| 成人国产一区二区三区精品| 亚洲天堂2016| 91黄色免费观看| 日韩中文欧美在线| 日韩视频永久免费| 国产成人精品一区二区三区网站观看| 国产三级精品视频| 99re视频这里只有精品| 一区二区三区在线不卡| 欧美精选午夜久久久乱码6080| 日本中文一区二区三区| 精品999在线播放| 成人福利在线看| 一区二区三区波多野结衣在线观看 | 亚洲午夜视频在线| 欧美剧在线免费观看网站 | 亚洲高清不卡在线观看| 欧美一区二区三区免费视频 | 日本不卡视频在线| 久久嫩草精品久久久精品| 成人的网站免费观看| 亚洲电影第三页| 欧美va亚洲va香蕉在线| 懂色av中文一区二区三区 | 久久久久久毛片| 99精品热视频| 免费在线观看日韩欧美| 国产色综合一区| 精品视频在线视频| 黄页视频在线91| 亚洲乱码国产乱码精品精98午夜| 欧美精品乱码久久久久久按摩| 国产在线不卡一卡二卡三卡四卡| 成人免费一区二区三区视频| 在线观看91av| 成人一区二区三区| 天天影视色香欲综合网老头| 久久无码av三级| 色婷婷综合激情| 国产精品99久久久久久久vr | 国产精品久久99| 欧美高清激情brazzers| 成人综合婷婷国产精品久久免费| 亚洲成人自拍偷拍| 国产欧美一区二区精品久导航 | 成人国产一区二区三区精品| 视频一区视频二区中文字幕| 国产精品色噜噜| 日韩一区二区三区在线视频| 99久久99久久精品免费观看| 秋霞午夜鲁丝一区二区老狼| 亚洲欧洲一区二区在线播放| 日韩一区二区高清| 色999日韩国产欧美一区二区| 国产一区二区三区免费播放| 亚洲福利视频三区| 国产精品麻豆久久久| 日韩一区二区免费视频| 色综合久久天天| 国产乱子伦视频一区二区三区| 亚洲电影激情视频网站| 国产精品电影一区二区| www日韩大片| 欧美日韩大陆一区二区| 91丝袜高跟美女视频| 国产高清精品久久久久| 另类中文字幕网| 亚洲va欧美va人人爽| 成人免费小视频| 国产欧美日韩在线| 欧美xxxxxxxx| 欧美一区午夜视频在线观看| 色噜噜狠狠成人网p站| 国产东北露脸精品视频| 韩国av一区二区三区在线观看| 日韩高清在线观看| 亚洲国产一二三| 亚洲免费资源在线播放| 国产欧美一区二区在线| 欧美精品一区二| 日韩一卡二卡三卡| 91麻豆精品国产91| 欧美剧情片在线观看| 欧美亚洲综合一区| 91国产视频在线观看| 94色蜜桃网一区二区三区| 国产成人99久久亚洲综合精品| 精品一区二区久久| 久久99国产精品成人| 美女一区二区久久| 美女高潮久久久| 秋霞电影网一区二区| 日本中文在线一区| 免费在线看一区| 男女视频一区二区| 日韩不卡一区二区| 日韩av不卡在线观看| 日韩av一区二区三区| 肉色丝袜一区二区| 丝袜亚洲另类丝袜在线| 图片区小说区区亚洲影院| 亚洲高清视频中文字幕| 亚洲高清一区二区三区| 五月婷婷欧美视频| 天天综合色天天综合色h| 日韩中文字幕亚洲一区二区va在线| 亚洲高清免费在线| 日韩成人av影视| 久久福利资源站| 国产精品一卡二卡| 成人动漫一区二区三区| 91麻豆国产香蕉久久精品| 色综合天天综合网天天看片| 在线观看欧美精品| 欧美日韩国产另类不卡| 在线不卡的av| 精品国产免费人成在线观看| 久久―日本道色综合久久| 国产午夜精品理论片a级大结局| 国产欧美日韩在线看| 综合久久国产九一剧情麻豆| 亚洲自拍偷拍麻豆| 日韩专区一卡二卡| 国产一区三区三区| 国产suv一区二区三区88区| 97se狠狠狠综合亚洲狠狠| 欧美在线一二三| 91精品国产色综合久久久蜜香臀| 欧美大胆人体bbbb| 国产精品视频一二三区| 一区二区三区国产豹纹内裤在线| 午夜激情综合网| 精品一区二区影视| 波多野洁衣一区| 欧美日韩精品免费观看视频| 日韩午夜激情免费电影| 亚洲国产成人私人影院tom| 夜夜嗨av一区二区三区| 免费高清不卡av| 成人动漫视频在线| 欧美精品乱人伦久久久久久| 久久婷婷国产综合国色天香| 亚洲欧洲精品一区二区三区不卡| 亚洲图片欧美一区| 国产精品综合av一区二区国产馆| 91在线免费视频观看| 91精品国产综合久久福利软件| 国产午夜精品福利| 亚洲成人三级小说|