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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? djpeg.c

?? 這是JPEG解碼、編碼的源代碼
?? C
?? 第 1 頁 / 共 2 頁
字號:
/*
 * djpeg.c
 *
 * Copyright (C) 1991-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 a command-line user interface for the JPEG decompressor.
 * It should work on any system with Unix- or MS-DOS-style command lines.
 *
 * Two different command line styles are permitted, depending on the
 * compile-time switch TWO_FILE_COMMANDLINE:
 *	djpeg [options]  inputfile outputfile
 *	djpeg [options]  [inputfile]
 * In the second style, output is always to standard output, which you'd
 * normally redirect to a file or pipe to some other program.  Input is
 * either from a named file or from standard input (typically redirected).
 * The second style is convenient on Unix but is unhelpful on systems that
 * don't support pipes.  Also, you MUST use the first style if your system
 * doesn't do binary I/O to stdin/stdout.
 * To simplify script writing, the "-outfile" switch is provided.  The syntax
 *	djpeg [options]  -outfile outputfile  inputfile
 * works regardless of which command line style is used.
 */

#include "cdjpeg.h"		/* Common decls for cjpeg/djpeg applications */
#include "jversion.h"		/* for version message */

#include <ctype.h>		/* to declare isprint() */

#ifdef USE_CCOMMAND		/* command-line reader for Macintosh */
#ifdef __MWERKS__
#include <SIOUX.h>              /* Metrowerks needs this */
#include <console.h>		/* ... and this */
#endif
#ifdef THINK_C
#include <console.h>		/* Think declares it here */
#endif
#endif


/* Create the add-on message string table. */

#define JMESSAGE(code,string)	string ,

static const char * const cdjpeg_message_table[] = {
#include "cderror.h"
  NULL
};


/*
 * This list defines the known output image formats
 * (not all of which need be supported by a given version).
 * You can change the default output format by defining DEFAULT_FMT;
 * indeed, you had better do so if you undefine PPM_SUPPORTED.
 */

typedef enum {
	FMT_BMP,		/* BMP format (Windows flavor) */
	FMT_GIF,		/* GIF format */
	FMT_OS2,		/* BMP format (OS/2 flavor) */
	FMT_PPM,		/* PPM/PGM (PBMPLUS formats) */
	FMT_RLE,		/* RLE format */
	FMT_TARGA,		/* Targa format */
	FMT_TIFF		/* TIFF format */
} IMAGE_FORMATS;

#ifndef DEFAULT_FMT		/* so can override from CFLAGS in Makefile */
#define DEFAULT_FMT	FMT_PPM
#endif

static IMAGE_FORMATS requested_fmt;


/*
 * Argument-parsing code.
 * The switch parser is designed to be useful with DOS-style command line
 * syntax, ie, intermixed switches and file names, where only the switches
 * to the left of a given file name affect processing of that file.
 * The main program in this file doesn't actually use this capability...
 */


static const char * progname;	/* program name for error messages */
static char * outfilename;	/* for -outfile switch */


LOCAL(void)
usage (void)
/* complain about bad command line */
{
  fprintf(stderr, "usage: %s [switches] ", progname);
#ifdef TWO_FILE_COMMANDLINE
  fprintf(stderr, "inputfile outputfile\n");
#else
  fprintf(stderr, "[inputfile]\n");
#endif

  fprintf(stderr, "Switches (names may be abbreviated):\n");
  fprintf(stderr, "  -colors N      Reduce image to no more than N colors\n");
  fprintf(stderr, "  -fast          Fast, low-quality processing\n");
  fprintf(stderr, "  -grayscale     Force grayscale output\n");
#ifdef IDCT_SCALING_SUPPORTED
  fprintf(stderr, "  -scale M/N     Scale output image by fraction M/N, eg, 1/8\n");
#endif
#ifdef BMP_SUPPORTED
  fprintf(stderr, "  -bmp           Select BMP output format (Windows style)%s\n",
	  (DEFAULT_FMT == FMT_BMP ? " (default)" : ""));
#endif
#ifdef GIF_SUPPORTED
  fprintf(stderr, "  -gif           Select GIF output format%s\n",
	  (DEFAULT_FMT == FMT_GIF ? " (default)" : ""));
#endif
#ifdef BMP_SUPPORTED
  fprintf(stderr, "  -os2           Select BMP output format (OS/2 style)%s\n",
	  (DEFAULT_FMT == FMT_OS2 ? " (default)" : ""));
#endif
#ifdef PPM_SUPPORTED
  fprintf(stderr, "  -pnm           Select PBMPLUS (PPM/PGM) output format%s\n",
	  (DEFAULT_FMT == FMT_PPM ? " (default)" : ""));
#endif
#ifdef RLE_SUPPORTED
  fprintf(stderr, "  -rle           Select Utah RLE output format%s\n",
	  (DEFAULT_FMT == FMT_RLE ? " (default)" : ""));
#endif
#ifdef TARGA_SUPPORTED
  fprintf(stderr, "  -targa         Select Targa output format%s\n",
	  (DEFAULT_FMT == FMT_TARGA ? " (default)" : ""));
#endif
  fprintf(stderr, "Switches for advanced users:\n");
#ifdef DCT_ISLOW_SUPPORTED
  fprintf(stderr, "  -dct int       Use integer DCT method%s\n",
	  (JDCT_DEFAULT == JDCT_ISLOW ? " (default)" : ""));
#endif
#ifdef DCT_IFAST_SUPPORTED
  fprintf(stderr, "  -dct fast      Use fast integer DCT (less accurate)%s\n",
	  (JDCT_DEFAULT == JDCT_IFAST ? " (default)" : ""));
#endif
#ifdef DCT_FLOAT_SUPPORTED
  fprintf(stderr, "  -dct float     Use floating-point DCT method%s\n",
	  (JDCT_DEFAULT == JDCT_FLOAT ? " (default)" : ""));
#endif
  fprintf(stderr, "  -dither fs     Use F-S dithering (default)\n");
  fprintf(stderr, "  -dither none   Don't use dithering in quantization\n");
  fprintf(stderr, "  -dither ordered  Use ordered dither (medium speed, quality)\n");
#ifdef QUANT_2PASS_SUPPORTED
  fprintf(stderr, "  -map FILE      Map to colors used in named image file\n");
#endif
  fprintf(stderr, "  -nosmooth      Don't use high-quality upsampling\n");
#ifdef QUANT_1PASS_SUPPORTED
  fprintf(stderr, "  -onepass       Use 1-pass quantization (fast, low quality)\n");
#endif
  fprintf(stderr, "  -maxmemory N   Maximum memory to use (in kbytes)\n");
  fprintf(stderr, "  -outfile name  Specify name for output file\n");
  fprintf(stderr, "  -verbose  or  -debug   Emit debug output\n");
  exit(EXIT_FAILURE);
}


LOCAL(int)
parse_switches (j_decompress_ptr cinfo, int argc, char **argv,
		int last_file_arg_seen, boolean for_real)
/* Parse optional switches.
 * Returns argv[] index of first file-name argument (== argc if none).
 * Any file names with indexes <= last_file_arg_seen are ignored;
 * they have presumably been processed in a previous iteration.
 * (Pass 0 for last_file_arg_seen on the first or only iteration.)
 * for_real is FALSE on the first (dummy) pass; we may skip any expensive
 * processing.
 */
{
  int argn;
  char * arg;

  /* Set up default JPEG parameters. */
  requested_fmt = DEFAULT_FMT;	/* set default output file format */
  outfilename = NULL;
  cinfo->err->trace_level = 0;

  /* Scan command line options, adjust parameters */

  for (argn = 1; argn < argc; argn++) {
    arg = argv[argn];
    if (*arg != '-') {
      /* Not a switch, must be a file name argument */
      if (argn <= last_file_arg_seen) {
	outfilename = NULL;	/* -outfile applies to just one input file */
	continue;		/* ignore this name if previously processed */
      }
      break;			/* else done parsing switches */
    }
    arg++;			/* advance past switch marker character */

    if (keymatch(arg, "bmp", 1)) {
      /* BMP output format. */
      requested_fmt = FMT_BMP;

    } else if (keymatch(arg, "colors", 1) || keymatch(arg, "colours", 1) ||
	       keymatch(arg, "quantize", 1) || keymatch(arg, "quantise", 1)) {
      /* Do color quantization. */
      int val;

      if (++argn >= argc)	/* advance to next argument */
	usage();
      if (sscanf(argv[argn], "%d", &val) != 1)
	usage();
      cinfo->desired_number_of_colors = val;
      cinfo->quantize_colors = TRUE;

    } else if (keymatch(arg, "dct", 2)) {
      /* Select IDCT algorithm. */
      if (++argn >= argc)	/* advance to next argument */
	usage();
      if (keymatch(argv[argn], "int", 1)) {
	cinfo->dct_method = JDCT_ISLOW;
      } else if (keymatch(argv[argn], "fast", 2)) {
	cinfo->dct_method = JDCT_IFAST;
      } else if (keymatch(argv[argn], "float", 2)) {
	cinfo->dct_method = JDCT_FLOAT;
      } else
	usage();

    } else if (keymatch(arg, "dither", 2)) {
      /* Select dithering algorithm. */
      if (++argn >= argc)	/* advance to next argument */
	usage();
      if (keymatch(argv[argn], "fs", 2)) {
	cinfo->dither_mode = JDITHER_FS;
      } else if (keymatch(argv[argn], "none", 2)) {
	cinfo->dither_mode = JDITHER_NONE;
      } else if (keymatch(argv[argn], "ordered", 2)) {
	cinfo->dither_mode = JDITHER_ORDERED;
      } else
	usage();

    } else if (keymatch(arg, "debug", 1) || keymatch(arg, "verbose", 1)) {
      /* Enable debug printouts. */
      /* On first -d, print version identification */
      static boolean printed_version = FALSE;

      if (! printed_version) {
	fprintf(stderr, "Independent JPEG Group's DJPEG, version %s\n%s\n",
		JVERSION, JCOPYRIGHT);
	printed_version = TRUE;
      }
      cinfo->err->trace_level++;

    } else if (keymatch(arg, "fast", 1)) {
      /* Select recommended processing options for quick-and-dirty output. */
      cinfo->two_pass_quantize = FALSE;
      cinfo->dither_mode = JDITHER_ORDERED;
      if (! cinfo->quantize_colors) /* don't override an earlier -colors */
	cinfo->desired_number_of_colors = 216;
      cinfo->dct_method = JDCT_FASTEST;
      cinfo->do_fancy_upsampling = FALSE;

    } else if (keymatch(arg, "gif", 1)) {
      /* GIF output format. */
      requested_fmt = FMT_GIF;

    } else if (keymatch(arg, "grayscale", 2) || keymatch(arg, "greyscale",2)) {
      /* Force monochrome output. */
      cinfo->out_color_space = JCS_GRAYSCALE;

    } else if (keymatch(arg, "map", 3)) {
      /* Quantize to a color map taken from an input file. */
      if (++argn >= argc)	/* advance to next argument */
	usage();
      if (for_real) {		/* too expensive to do twice! */
#ifdef QUANT_2PASS_SUPPORTED	/* otherwise can't quantize to supplied map */
	FILE * mapfile;

	if ((mapfile = fopen(argv[argn], READ_BINARY)) == NULL) {
	  fprintf(stderr, "%s: can't open %s\n", progname, argv[argn]);
	  exit(EXIT_FAILURE);
	}
	read_color_map(cinfo, mapfile);
	fclose(mapfile);
	cinfo->quantize_colors = TRUE;
#else
	ERREXIT(cinfo, JERR_NOT_COMPILED);
#endif
      }

    } else if (keymatch(arg, "maxmemory", 3)) {
      /* Maximum memory in Kb (or Mb with 'm'). */
      long lval;
      char ch = 'x';

      if (++argn >= argc)	/* advance to next argument */
	usage();
      if (sscanf(argv[argn], "%ld%c", &lval, &ch) < 1)
	usage();
      if (ch == 'm' || ch == 'M')
	lval *= 1000L;
      cinfo->mem->max_memory_to_use = lval * 1000L;

    } else if (keymatch(arg, "nosmooth", 3)) {
      /* Suppress fancy upsampling */
      cinfo->do_fancy_upsampling = FALSE;

    } else if (keymatch(arg, "onepass", 3)) {

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产日本亚洲高清| 久久免费电影网| 99久久精品免费看| 国产乱人伦精品一区二区在线观看 | 欧美tk丨vk视频| 欧美网站一区二区| 精品1区2区3区| 欧美久久一区二区| 日韩午夜激情免费电影| 欧美一区二区三区不卡| 久久久精品一品道一区| 国产精品二区一区二区aⅴ污介绍| 国产女人18毛片水真多成人如厕| 国产精品美女久久福利网站| 国产精品家庭影院| 性做久久久久久久久| 日本怡春院一区二区| 极品少妇xxxx精品少妇偷拍 | 中文字幕精品一区二区三区精品| 国产精品毛片高清在线完整版| 国产精品久久免费看| 洋洋成人永久网站入口| 免费高清不卡av| 国产99久久久久| 色狠狠桃花综合| 在线综合亚洲欧美在线视频| 久久久精品人体av艺术| 亚洲精品久久久蜜桃| 日韩精品一二三四| 成人性视频网站| 91精品在线免费观看| 日本一区二区高清| 亚洲综合在线第一页| 蜜臀av性久久久久av蜜臀妖精| 粉嫩aⅴ一区二区三区四区五区| 一本一道波多野结衣一区二区| 日韩视频国产视频| 国产精品久久99| 欧美aaa在线| 91老师国产黑色丝袜在线| 欧美日韩一级视频| 久久综合久久鬼色中文字| 亚洲欧美电影一区二区| 日韩精品五月天| 色综合天天在线| 日韩午夜在线播放| 一区二区三区日韩欧美| 久久国产麻豆精品| 欧美美女视频在线观看| 国产精品每日更新在线播放网址 | 国产一区二区三区在线观看免费视频| 国产一区二区三区四区五区入口| 色www精品视频在线观看| 欧美电影影音先锋| 亚洲天堂免费看| 丁香五精品蜜臀久久久久99网站| 欧美亚洲国产一区二区三区va| 欧美精品一区二区三区蜜桃视频| 一区二区激情视频| 91免费版在线| 国产精品美女久久久久aⅴ | 国产亚洲精品中文字幕| 日韩成人伦理电影在线观看| 91黄视频在线观看| 1区2区3区精品视频| 国产精品一品二品| 欧美videos大乳护士334| 视频一区二区三区在线| 欧美日韩综合在线免费观看| 亚洲免费高清视频在线| 94色蜜桃网一区二区三区| 天天色天天爱天天射综合| 在线视频一区二区三| 亚洲一区二区在线播放相泽| 色菇凉天天综合网| 亚洲福利电影网| 精品视频123区在线观看| 亚洲福利一二三区| 日韩一区二区高清| 国产剧情一区在线| 国产精品久久久久一区二区三区共 | 欧美亚洲图片小说| 午夜在线电影亚洲一区| 日韩一区二区精品| 国产乱码精品一区二区三区av| 国产视频一区在线观看| 成人av中文字幕| 亚洲欧美日韩国产手机在线 | 久久久国产精品麻豆| 国产99久久久精品| 亚洲精品综合在线| 欧美男女性生活在线直播观看| 男女男精品视频| 国产婷婷一区二区| 日本韩国精品一区二区在线观看| 亚洲电影中文字幕在线观看| 91精品国产色综合久久不卡电影| 久久99国产精品久久99果冻传媒| 久久久久久99久久久精品网站| 不卡视频一二三四| 图片区小说区区亚洲影院| 精品国产网站在线观看| 99久久99精品久久久久久| 午夜成人免费电影| 中文字幕国产一区| 欧美一区二区三区系列电影| 韩国av一区二区三区在线观看| 亚洲视频中文字幕| 亚洲精品一区二区三区香蕉| 99在线精品免费| 久久97超碰色| 亚洲一区二区在线播放相泽| 欧美精品一区二区三区蜜桃| 北岛玲一区二区三区四区| 亚洲与欧洲av电影| 国产精品天美传媒| 欧美一区二区三区在| www..com久久爱| 久久精品国产免费| 亚洲国产日日夜夜| 国产精品女主播av| 久久尤物电影视频在线观看| 一本久久精品一区二区| 国产老女人精品毛片久久| 亚洲成人动漫在线观看| 亚洲欧洲韩国日本视频| 久久欧美中文字幕| 91精品国产综合久久婷婷香蕉| 成人免费电影视频| 国产剧情一区二区| 久久99国产精品免费| 天天爽夜夜爽夜夜爽精品视频| 亚洲欧洲三级电影| 国产情人综合久久777777| 欧美一级艳片视频免费观看| 欧美系列日韩一区| 色8久久精品久久久久久蜜| 国产aⅴ精品一区二区三区色成熟| 青青草成人在线观看| 亚洲成人精品一区二区| 一区二区高清在线| 亚洲激情图片qvod| 亚洲激情欧美激情| 一级中文字幕一区二区| 亚洲男人的天堂av| ●精品国产综合乱码久久久久| 国产精品美女久久久久av爽李琼| 久久久99免费| 久久久国产午夜精品| 久久久青草青青国产亚洲免观| 2024国产精品视频| 国产视频一区不卡| 中文字幕一区二区三区不卡| 中文字幕 久热精品 视频在线| 国产偷国产偷精品高清尤物| 久久精品视频一区二区| 久久婷婷成人综合色| 亚洲精品一区二区三区四区高清| 日韩一二三四区| 26uuu国产电影一区二区| 精品粉嫩aⅴ一区二区三区四区| 欧美精品一区二区在线播放| 久久久蜜桃精品| 国产精品久久久久久久久免费桃花 | 激情综合色播激情啊| 黑人巨大精品欧美一区| 国产真实乱对白精彩久久| 国产福利精品一区| 成人黄色av电影| 色老汉av一区二区三区| 欧美日韩国产综合久久| 6080午夜不卡| 日本一区二区三区视频视频| 中文字幕一区二区三区在线不卡 | 日本一区免费视频| 亚洲人xxxx| 日韩成人一区二区三区在线观看| 日韩国产欧美在线观看| 国产经典欧美精品| 91电影在线观看| 日韩欧美国产三级| 国产精品国产三级国产普通话蜜臀 | 在线观看91视频| 555www色欧美视频| 欧美国产视频在线| 日韩激情在线观看| 不卡一区二区在线| 欧美一区二区三区四区五区| 久久人人超碰精品| 亚洲国产综合视频在线观看| 麻豆国产一区二区| thepron国产精品| 在线不卡中文字幕播放| 99免费精品视频| 不卡视频一二三四| 日韩欧美在线综合网| 亚洲欧美日韩人成在线播放| 九九国产精品视频| 日本韩国精品一区二区在线观看| 精品福利在线导航|