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

Side by Side Diff: tools/PictureRenderer.cpp

Issue 196823004: Silence warning after f5e315ccf1a. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Drop unrelated changes. Created 6 years, 9 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 | « no previous file | no next file » | 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 * Copyright 2012 Google Inc. 2 * Copyright 2012 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 #include "PictureRenderer.h" 8 #include "PictureRenderer.h"
9 #include "picture_utils.h" 9 #include "picture_utils.h"
10 #include "SamplePipeControllers.h" 10 #include "SamplePipeControllers.h"
(...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after
340 SkString outputFilename(inputFilename); 340 SkString outputFilename(inputFilename);
341 outputFilename.remove(outputFilename.size() - 4, 4); 341 outputFilename.remove(outputFilename.size() - 4, 4);
342 if (NULL != numberToAppend) { 342 if (NULL != numberToAppend) {
343 outputFilename.appendf("%i", *numberToAppend); 343 outputFilename.appendf("%i", *numberToAppend);
344 } 344 }
345 outputFilename.append(".png"); 345 outputFilename.append(".png");
346 // TODO(epoger): what about including the config type within outputFilename? That way, 346 // TODO(epoger): what about including the config type within outputFilename? That way,
347 // we could combine results of different config types without conflicting fi lenames. 347 // we could combine results of different config types without conflicting fi lenames.
348 348
349 if (NULL != jsonSummaryPtr) { 349 if (NULL != jsonSummaryPtr) {
350 if (!generatedHash) { 350 SkASSERT(!generatedHash);
351 SkAssertResult(SkBitmapHasher::ComputeDigest(bitmap, &hash)); 351 SkAssertResult(SkBitmapHasher::ComputeDigest(bitmap, &hash));
352 generatedHash = true; 352 generatedHash = true;
353 } 353
354 jsonSummaryPtr->add(outputFilename.c_str(), hash); 354 jsonSummaryPtr->add(outputFilename.c_str(), hash);
355 } 355 }
356 356
357 // Update outputFilename AFTER adding to JSON summary, but BEFORE writing ou t the image file. 357 // Update outputFilename AFTER adding to JSON summary, but BEFORE writing ou t the image file.
358 if (useChecksumBasedFilenames) { 358 if (useChecksumBasedFilenames) {
359 if (!generatedHash) { 359 if (!generatedHash) {
360 SkAssertResult(SkBitmapHasher::ComputeDigest(bitmap, &hash)); 360 SkAssertResult(SkBitmapHasher::ComputeDigest(bitmap, &hash));
361 generatedHash = true; 361 generatedHash = true;
362 } 362 }
363 outputFilename.set(kJsonKey_Hashtype_Bitmap_64bitMD5); 363 outputFilename.set(kJsonKey_Hashtype_Bitmap_64bitMD5);
(...skipping 634 matching lines...) Expand 10 before | Expand all | Expand 10 after
998 virtual SkString getConfigNameInternal() SK_OVERRIDE { 998 virtual SkString getConfigNameInternal() SK_OVERRIDE {
999 return SkString("picture_clone"); 999 return SkString("picture_clone");
1000 } 1000 }
1001 }; 1001 };
1002 1002
1003 PictureRenderer* CreatePictureCloneRenderer() { 1003 PictureRenderer* CreatePictureCloneRenderer() {
1004 return SkNEW(PictureCloneRenderer); 1004 return SkNEW(PictureCloneRenderer);
1005 } 1005 }
1006 1006
1007 } // namespace sk_tools 1007 } // namespace sk_tools
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698