Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1096)

Side by Side Diff: jpegtran.c

Issue 10386084: Update libjpeg-turbo. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/libjpeg_turbo/
Patch Set: Created 8 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « jpegcomp.h ('k') | jversion.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * jpegtran.c 2 * jpegtran.c
3 * 3 *
4 * Copyright (C) 1995-2010, Thomas G. Lane, Guido Vollbeding. 4 * Copyright (C) 1995-2010, Thomas G. Lane, Guido Vollbeding.
5 * Copyright (C) 2010, D. R. Commander. 5 * Copyright (C) 2010, D. R. Commander.
6 * This file is part of the Independent JPEG Group's software. 6 * This file is part of the Independent JPEG Group's software.
7 * For conditions of distribution and use, see the accompanying README file. 7 * For conditions of distribution and use, see the accompanying README file.
8 * 8 *
9 * This file contains a command-line user interface for JPEG transcoding. 9 * This file contains a command-line user interface for JPEG transcoding.
10 * It is very similar to cjpeg.c, and partly to djpeg.c, but provides 10 * It is very similar to cjpeg.c, and partly to djpeg.c, but provides
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 fprintf(stderr, " -flip [horizontal|vertical] Mirror image (left-right or to p-bottom)\n"); 71 fprintf(stderr, " -flip [horizontal|vertical] Mirror image (left-right or to p-bottom)\n");
72 fprintf(stderr, " -perfect Fail if there is non-transformable edge bloc ks\n"); 72 fprintf(stderr, " -perfect Fail if there is non-transformable edge bloc ks\n");
73 fprintf(stderr, " -rotate [90|180|270] Rotate image (degrees clockwis e)\n"); 73 fprintf(stderr, " -rotate [90|180|270] Rotate image (degrees clockwis e)\n");
74 #endif 74 #endif
75 #if TRANSFORMS_SUPPORTED 75 #if TRANSFORMS_SUPPORTED
76 fprintf(stderr, " -transpose Transpose image\n"); 76 fprintf(stderr, " -transpose Transpose image\n");
77 fprintf(stderr, " -transverse Transverse transpose image\n"); 77 fprintf(stderr, " -transverse Transverse transpose image\n");
78 fprintf(stderr, " -trim Drop non-transformable edge blocks\n"); 78 fprintf(stderr, " -trim Drop non-transformable edge blocks\n");
79 #endif 79 #endif
80 fprintf(stderr, "Switches for advanced users:\n"); 80 fprintf(stderr, "Switches for advanced users:\n");
81 #ifdef C_ARITH_CODING_SUPPORTED
82 fprintf(stderr, " -arithmetic Use arithmetic coding\n");
83 #endif
81 fprintf(stderr, " -restart N Set restart interval in rows, or in blocks w ith B\n"); 84 fprintf(stderr, " -restart N Set restart interval in rows, or in blocks w ith B\n");
82 fprintf(stderr, " -maxmemory N Maximum memory to use (in kbytes)\n"); 85 fprintf(stderr, " -maxmemory N Maximum memory to use (in kbytes)\n");
83 fprintf(stderr, " -outfile name Specify name for output file\n"); 86 fprintf(stderr, " -outfile name Specify name for output file\n");
84 fprintf(stderr, " -verbose or -debug Emit debug output\n"); 87 fprintf(stderr, " -verbose or -debug Emit debug output\n");
85 fprintf(stderr, "Switches for wizards:\n"); 88 fprintf(stderr, "Switches for wizards:\n");
86 #ifdef C_ARITH_CODING_SUPPORTED
87 fprintf(stderr, " -arithmetic Use arithmetic coding\n");
88 #endif
89 #ifdef C_MULTISCAN_FILES_SUPPORTED 89 #ifdef C_MULTISCAN_FILES_SUPPORTED
90 fprintf(stderr, " -scans file Create multi-scan JPEG per script file\n"); 90 fprintf(stderr, " -scans file Create multi-scan JPEG per script file\n");
91 #endif 91 #endif
92 exit(EXIT_FAILURE); 92 exit(EXIT_FAILURE);
93 } 93 }
94 94
95 95
96 LOCAL(void) 96 LOCAL(void)
97 select_transform (JXFORM_CODE transform) 97 select_transform (JXFORM_CODE transform)
98 /* Silly little routine to detect multiple transform options, 98 /* Silly little routine to detect multiple transform options,
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 #endif 197 #endif
198 198
199 } else if (keymatch(arg, "debug", 1) || keymatch(arg, "verbose", 1)) { 199 } else if (keymatch(arg, "debug", 1) || keymatch(arg, "verbose", 1)) {
200 /* Enable debug printouts. */ 200 /* Enable debug printouts. */
201 /* On first -d, print version identification */ 201 /* On first -d, print version identification */
202 static boolean printed_version = FALSE; 202 static boolean printed_version = FALSE;
203 203
204 if (! printed_version) { 204 if (! printed_version) {
205 fprintf(stderr, "%s version %s (build %s)\n", 205 fprintf(stderr, "%s version %s (build %s)\n",
206 PACKAGE_NAME, VERSION, BUILD); 206 PACKAGE_NAME, VERSION, BUILD);
207 » fprintf(stderr, "%s\n\n", LJTCOPYRIGHT); 207 » fprintf(stderr, "%s\n\n", JCOPYRIGHT);
208 » fprintf(stderr, "Based on Independent JPEG Group's libjpeg, version %s\n %s\n\n", 208 » fprintf(stderr, "Emulating The Independent JPEG Group's libjpeg, version %s\n\n",
209 » » JVERSION, JCOPYRIGHT); 209 » » JVERSION);
210 printed_version = TRUE; 210 printed_version = TRUE;
211 } 211 }
212 cinfo->err->trace_level++; 212 cinfo->err->trace_level++;
213 213
214 } else if (keymatch(arg, "flip", 1)) { 214 } else if (keymatch(arg, "flip", 1)) {
215 /* Mirror left-right or top-bottom. */ 215 /* Mirror left-right or top-bottom. */
216 if (++argn >= argc) /* advance to next argument */ 216 if (++argn >= argc) /* advance to next argument */
217 usage(); 217 usage();
218 if (keymatch(argv[argn], "horizontal", 1)) 218 if (keymatch(argv[argn], "horizontal", 1))
219 select_transform(JXFORM_FLIP_H); 219 select_transform(JXFORM_FLIP_H);
(...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after
541 fclose(fp); 541 fclose(fp);
542 542
543 #ifdef PROGRESS_REPORT 543 #ifdef PROGRESS_REPORT
544 end_progress_monitor((j_common_ptr) &dstinfo); 544 end_progress_monitor((j_common_ptr) &dstinfo);
545 #endif 545 #endif
546 546
547 /* All done. */ 547 /* All done. */
548 exit(jsrcerr.num_warnings + jdsterr.num_warnings ?EXIT_WARNING:EXIT_SUCCESS); 548 exit(jsrcerr.num_warnings + jdsterr.num_warnings ?EXIT_WARNING:EXIT_SUCCESS);
549 return 0; /* suppress no-return-value warnings */ 549 return 0; /* suppress no-return-value warnings */
550 } 550 }
OLDNEW
« no previous file with comments | « jpegcomp.h ('k') | jversion.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698