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

Side by Side Diff: experimental/skpdiff/SkCLImageDiffer.cpp

Issue 17885003: add command line flags (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: add TODOs Created 7 years, 5 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 | « experimental/skpdiff/README ('k') | experimental/skpdiff/main.cpp » ('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 /* 2 /*
3 * Copyright 2013 Google Inc. 3 * Copyright 2013 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include <cstring> 9 #include <cstring>
10 10
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 return false; 119 return false;
120 } 120 }
121 121
122 return true; 122 return true;
123 } 123 }
124 124
125 125
126 //////////////////////////////////////////////////////////////// 126 ////////////////////////////////////////////////////////////////
127 127
128 const char* SkDifferentPixelsImageDiffer::getName() { 128 const char* SkDifferentPixelsImageDiffer::getName() {
129 return "Find Different Pixels"; 129 return "different_pixels";
130 } 130 }
131 131
132 int SkDifferentPixelsImageDiffer::queueDiff(SkBitmap * baseline, SkBitmap * test ) { 132 int SkDifferentPixelsImageDiffer::queueDiff(SkBitmap * baseline, SkBitmap * test ) {
133 int diffID = fQueuedDiffs.count(); 133 int diffID = fQueuedDiffs.count();
134 double startTime = get_seconds(); 134 double startTime = get_seconds();
135 QueuedDiff* diff = fQueuedDiffs.push(); 135 QueuedDiff* diff = fQueuedDiffs.push();
136 136
137 // Ensure the images are comparable 137 // Ensure the images are comparable
138 if (baseline->width() != test->width() || baseline->height() != test->height () || 138 if (baseline->width() != test->width() || baseline->height() != test->height () ||
139 baseline->width() <= 0 || baseline->height() <= 0) { 139 baseline->width() <= 0 || baseline->height() <= 0) {
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 } 201 }
202 202
203 203
204 bool SkDifferentPixelsImageDiffer::onInit() { 204 bool SkDifferentPixelsImageDiffer::onInit() {
205 if (!loadKernelFile("experimental/skpdiff/diff_pixels.cl", "diff", &fKernel) ) { 205 if (!loadKernelFile("experimental/skpdiff/diff_pixels.cl", "diff", &fKernel) ) {
206 return false; 206 return false;
207 } 207 }
208 208
209 return true; 209 return true;
210 } 210 }
OLDNEW
« no previous file with comments | « experimental/skpdiff/README ('k') | experimental/skpdiff/main.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698