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

Side by Side Diff: tools/filtermain.cpp

Issue 238273012: Staged removal of SkPicture-derived classes (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: have SkPicture only friend SkPictureRecorder once Created 6 years, 8 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 | « tools/bench_record.cpp ('k') | tools/render_pictures_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 * 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 "SkDebugCanvas.h" 8 #include "SkDebugCanvas.h"
9 #include "SkDevice.h" 9 #include "SkDevice.h"
10 #include "SkForceLinking.h" 10 #include "SkForceLinking.h"
(...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after
711 changed = true; 711 changed = true;
712 } 712 }
713 } 713 }
714 } 714 }
715 } 715 }
716 716
717 int numAfter = debugCanvas.getSize(); 717 int numAfter = debugCanvas.getSize();
718 718
719 if (!outFile.isEmpty()) { 719 if (!outFile.isEmpty()) {
720 SkPictureRecorder recorder; 720 SkPictureRecorder recorder;
721 SkCanvas* canvas = recorder.beginRecording(inPicture->width(), inPicture ->height()); 721 SkCanvas* canvas = recorder.beginRecording(inPicture->width(), inPicture ->height(), NULL, 0);
722 debugCanvas.draw(canvas); 722 debugCanvas.draw(canvas);
723 SkAutoTUnref<SkPicture> outPicture(recorder.endRecording()); 723 SkAutoTUnref<SkPicture> outPicture(recorder.endRecording());
724 724
725 SkFILEWStream outStream(outFile.c_str()); 725 SkFILEWStream outStream(outFile.c_str());
726 726
727 outPicture->serialize(&outStream); 727 outPicture->serialize(&outStream);
728 } 728 }
729 729
730 bool someOptFired = false; 730 bool someOptFired = false;
731 for (size_t opt = 0; opt < SK_ARRAY_COUNT(gOptTable); ++opt) { 731 for (size_t opt = 0; opt < SK_ARRAY_COUNT(gOptTable); ++opt) {
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
838 838
839 SkGraphics::Term(); 839 SkGraphics::Term();
840 return 0; 840 return 0;
841 } 841 }
842 842
843 #if !defined SK_BUILD_FOR_IOS 843 #if !defined SK_BUILD_FOR_IOS
844 int main(int argc, char * const argv[]) { 844 int main(int argc, char * const argv[]) {
845 return tool_main(argc, (char**) argv); 845 return tool_main(argc, (char**) argv);
846 } 846 }
847 #endif 847 #endif
OLDNEW
« no previous file with comments | « tools/bench_record.cpp ('k') | tools/render_pictures_main.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698