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

Side by Side Diff: dm/DM.cpp

Issue 338633011: Deprecate SkPicture::clone(). (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: add define for chrome Created 6 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
« no previous file with comments | « no previous file | dm/DMPDFTask.h » ('j') | src/core/SkPicturePlayback.cpp » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Main binary for DM. 1 // Main binary for DM.
2 // For a high-level overview, please see dm/README. 2 // For a high-level overview, please see dm/README.
3 3
4 #include "Benchmark.h" 4 #include "Benchmark.h"
5 #include "CrashHandler.h" 5 #include "CrashHandler.h"
6 #include "SkCommandLineFlags.h" 6 #include "SkCommandLineFlags.h"
7 #include "SkForceLinking.h" 7 #include "SkForceLinking.h"
8 #include "SkGraphics.h" 8 #include "SkGraphics.h"
9 #include "SkPicture.h" 9 #include "SkPicture.h"
10 #include "SkString.h" 10 #include "SkString.h"
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 if (stream.get() == NULL) { 179 if (stream.get() == NULL) {
180 SkDebugf("Could not read %s.\n", path.c_str()); 180 SkDebugf("Could not read %s.\n", path.c_str());
181 exit(1); 181 exit(1);
182 } 182 }
183 SkAutoTUnref<SkPicture> pic(SkPicture::CreateFromStream(stream.get())); 183 SkAutoTUnref<SkPicture> pic(SkPicture::CreateFromStream(stream.get()));
184 if (pic.get() == NULL) { 184 if (pic.get() == NULL) {
185 SkDebugf("Could not read %s as an SkPicture.\n", path.c_str()); 185 SkDebugf("Could not read %s as an SkPicture.\n", path.c_str());
186 exit(1); 186 exit(1);
187 } 187 }
188 188
189 tasks->add(SkNEW_ARGS(DM::SKPTask, (reporter, tasks, pic->clone(), filen ame))); 189 tasks->add(SkNEW_ARGS(DM::SKPTask, (reporter, tasks, pic, filename)));
190 tasks->add(SkNEW_ARGS(DM::PDFTask, (reporter, tasks, pic->clone(), filen ame, 190 tasks->add(SkNEW_ARGS(DM::PDFTask, (reporter, tasks, pic, filename,
191 RASTERIZE_PDF_PROC))); 191 RASTERIZE_PDF_PROC)));
192 } 192 }
193 } 193 }
194 194
195 static void report_failures(const SkTArray<SkString>& failures) { 195 static void report_failures(const SkTArray<SkString>& failures) {
196 if (failures.count() == 0) { 196 if (failures.count() == 0) {
197 return; 197 return;
198 } 198 }
199 199
200 SkDebugf("Failures:\n"); 200 SkDebugf("Failures:\n");
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
273 reporter.getFailures(&failures); 273 reporter.getFailures(&failures);
274 report_failures(failures); 274 report_failures(failures);
275 return failures.count() > 0; 275 return failures.count() > 0;
276 } 276 }
277 277
278 #if !defined(SK_BUILD_FOR_IOS) && !defined(SK_BUILD_FOR_NACL) 278 #if !defined(SK_BUILD_FOR_IOS) && !defined(SK_BUILD_FOR_NACL)
279 int main(int argc, char** argv) { 279 int main(int argc, char** argv) {
280 return tool_main(argc, argv); 280 return tool_main(argc, argv);
281 } 281 }
282 #endif 282 #endif
OLDNEW
« no previous file with comments | « no previous file | dm/DMPDFTask.h » ('j') | src/core/SkPicturePlayback.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698