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

Side by Side Diff: gm/gmmain.cpp

Issue 17365002: GM: add --writeChecksumBasedFilenames option (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 6 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
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 /* 8 /*
9 * Code for the "gm" (Golden Master) rendering comparison tool. 9 * Code for the "gm" (Golden Master) rendering comparison tool.
10 * 10 *
(...skipping 1285 matching lines...) Expand 10 before | Expand all | Expand 10 after
1296 "any differences between those and the newly generated ones."); 1296 "any differences between those and the newly generated ones.");
1297 DEFINE_bool(replay, true, "Exercise the SkPicture replay test pass."); 1297 DEFINE_bool(replay, true, "Exercise the SkPicture replay test pass.");
1298 DEFINE_string2(resourcePath, i, "", "Directory that stores image resources."); 1298 DEFINE_string2(resourcePath, i, "", "Directory that stores image resources.");
1299 DEFINE_bool(rtree, true, "Exercise the R-Tree variant of SkPicture test pass."); 1299 DEFINE_bool(rtree, true, "Exercise the R-Tree variant of SkPicture test pass.");
1300 DEFINE_bool(serialize, true, "Exercise the SkPicture serialization & deserializa tion test pass."); 1300 DEFINE_bool(serialize, true, "Exercise the SkPicture serialization & deserializa tion test pass.");
1301 DEFINE_bool(simulatePipePlaybackFailure, false, "Simulate a rendering failure in pipe mode only."); 1301 DEFINE_bool(simulatePipePlaybackFailure, false, "Simulate a rendering failure in pipe mode only.");
1302 DEFINE_bool(tiledPipe, false, "Exercise tiled SkGPipe replay."); 1302 DEFINE_bool(tiledPipe, false, "Exercise tiled SkGPipe replay.");
1303 DEFINE_bool(tileGrid, true, "Exercise the tile grid variant of SkPicture."); 1303 DEFINE_bool(tileGrid, true, "Exercise the tile grid variant of SkPicture.");
1304 DEFINE_string(tileGridReplayScales, "", "Space separated list of floating-point scale " 1304 DEFINE_string(tileGridReplayScales, "", "Space separated list of floating-point scale "
1305 "factors to be used for tileGrid playback testing. Default value: 1.0"); 1305 "factors to be used for tileGrid playback testing. Default value: 1.0");
1306 DEFINE_string(writeJsonSummaryPath, "", "Write a JSON-formatted result summary t o this file.");
1307 DEFINE_bool2(verbose, v, false, "Give more detail (e.g. list all GMs run, more i nfo about " 1306 DEFINE_bool2(verbose, v, false, "Give more detail (e.g. list all GMs run, more i nfo about "
1308 "each test)."); 1307 "each test).");
1308 DEFINE_bool(writeChecksumBasedFilenames, false, "When writing out actual images, use checksum-"
epoger 2013/06/18 03:44:10 Patchset 1 adds the definition of the new flag, bu
1309 "based filenames, as rebaseline.py will use when downloading them fr om Google Storage");
1310 DEFINE_string(writeJsonSummaryPath, "", "Write a JSON-formatted result summary t o this file.");
1309 DEFINE_string2(writePath, w, "", "Write rendered images into this directory."); 1311 DEFINE_string2(writePath, w, "", "Write rendered images into this directory.");
1310 DEFINE_string2(writePicturePath, p, "", "Write .skp files into this directory.") ; 1312 DEFINE_string2(writePicturePath, p, "", "Write .skp files into this directory.") ;
1311 DEFINE_int32(pdfJpegQuality, -1, "Encodes images in JPEG at quality level N, " 1313 DEFINE_int32(pdfJpegQuality, -1, "Encodes images in JPEG at quality level N, "
1312 "which can be in range 0-100). N = -1 will disable JPEG compression . " 1314 "which can be in range 0-100). N = -1 will disable JPEG compression . "
1313 "Default is N = 100, maximum quality."); 1315 "Default is N = 100, maximum quality.");
1314 1316
1315 static bool encode_to_dct_stream(SkWStream* stream, const SkBitmap& bitmap, cons t SkIRect& rect) { 1317 static bool encode_to_dct_stream(SkWStream* stream, const SkBitmap& bitmap, cons t SkIRect& rect) {
1316 // Filter output of warnings that JPEG is not available for the image. 1318 // Filter output of warnings that JPEG is not available for the image.
1317 if (bitmap.width() >= 65500 || bitmap.height() >= 65500) return false; 1319 if (bitmap.width() >= 65500 || bitmap.height() >= 65500) return false;
1318 if (FLAGS_pdfJpegQuality == -1) return false; 1320 if (FLAGS_pdfJpegQuality == -1) return false;
(...skipping 767 matching lines...) Expand 10 before | Expand all | Expand 10 after
2086 if (FLAGS_forceBWtext) { 2088 if (FLAGS_forceBWtext) {
2087 canvas->setDrawFilter(SkNEW(BWTextDrawFilter))->unref(); 2089 canvas->setDrawFilter(SkNEW(BWTextDrawFilter))->unref();
2088 } 2090 }
2089 } 2091 }
2090 2092
2091 #if !defined(SK_BUILD_FOR_IOS) && !defined(SK_BUILD_FOR_NACL) 2093 #if !defined(SK_BUILD_FOR_IOS) && !defined(SK_BUILD_FOR_NACL)
2092 int main(int argc, char * const argv[]) { 2094 int main(int argc, char * const argv[]) {
2093 return tool_main(argc, (char**) argv); 2095 return tool_main(argc, (char**) argv);
2094 } 2096 }
2095 #endif 2097 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698