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

Side by Side Diff: dm/DM.cpp

Issue 2201323003: add pipecanvas (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: add test for writeImage Created 4 years, 3 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/DMSrcSink.h » ('j') | src/core/SkPipe.h » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 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 "DMJsonWriter.h" 8 #include "DMJsonWriter.h"
9 #include "DMSrcSink.h" 9 #include "DMSrcSink.h"
10 #include "DMSrcSinkAndroid.h" 10 #include "DMSrcSinkAndroid.h"
(...skipping 850 matching lines...) Expand 10 before | Expand all | Expand 10 after
861 861
862 if (FLAGS_cpu) { 862 if (FLAGS_cpu) {
863 auto srgbColorSpace = SkColorSpace::NewNamed(SkColorSpace::kSRGB_Named); 863 auto srgbColorSpace = SkColorSpace::NewNamed(SkColorSpace::kSRGB_Named);
864 864
865 SINK("565", RasterSink, kRGB_565_SkColorType); 865 SINK("565", RasterSink, kRGB_565_SkColorType);
866 SINK("8888", RasterSink, kN32_SkColorType); 866 SINK("8888", RasterSink, kN32_SkColorType);
867 SINK("srgb", RasterSink, kN32_SkColorType, srgbColorSpace); 867 SINK("srgb", RasterSink, kN32_SkColorType, srgbColorSpace);
868 SINK("f16", RasterSink, kRGBA_F16_SkColorType, srgbColorSpace->makeLine arGamma()); 868 SINK("f16", RasterSink, kRGBA_F16_SkColorType, srgbColorSpace->makeLine arGamma());
869 SINK("pdf", PDFSink); 869 SINK("pdf", PDFSink);
870 SINK("skp", SKPSink); 870 SINK("skp", SKPSink);
871 SINK("pipe", PipeSink);
871 SINK("svg", SVGSink); 872 SINK("svg", SVGSink);
872 SINK("null", NullSink); 873 SINK("null", NullSink);
873 SINK("xps", XPSSink); 874 SINK("xps", XPSSink);
874 SINK("pdfa", PDFSink, true); 875 SINK("pdfa", PDFSink, true);
875 } 876 }
876 #undef SINK 877 #undef SINK
877 return nullptr; 878 return nullptr;
878 } 879 }
879 880
880 static Sink* create_via(const SkString& tag, Sink* wrapped) { 881 static Sink* create_via(const SkString& tag, Sink* wrapped) {
881 #define VIA(t, via, ...) if (tag.equals(t)) { return new via(__VA_ARGS__); } 882 #define VIA(t, via, ...) if (tag.equals(t)) { return new via(__VA_ARGS__); }
882 VIA("lite", ViaLite, wrapped); 883 VIA("lite", ViaLite, wrapped);
884 VIA("pipe", ViaPipe, wrapped);
883 VIA("twice", ViaTwice, wrapped); 885 VIA("twice", ViaTwice, wrapped);
884 VIA("serialize", ViaSerialization, wrapped); 886 VIA("serialize", ViaSerialization, wrapped);
885 VIA("pic", ViaPicture, wrapped); 887 VIA("pic", ViaPicture, wrapped);
886 VIA("2ndpic", ViaSecondPicture, wrapped); 888 VIA("2ndpic", ViaSecondPicture, wrapped);
887 VIA("sp", ViaSingletonPictures, wrapped); 889 VIA("sp", ViaSingletonPictures, wrapped);
888 VIA("defer", ViaDefer, wrapped); 890 VIA("defer", ViaDefer, wrapped);
889 VIA("tiles", ViaTiles, 256, 256, nullptr, wrapped); 891 VIA("tiles", ViaTiles, 256, 256, nullptr, wrapped);
890 VIA("tiles_rt", ViaTiles, 256, 256, new SkRTreeFactory, wrapped); 892 VIA("tiles_rt", ViaTiles, 256, 256, new SkRTreeFactory, wrapped);
891 893
892 if (FLAGS_matrix.count() == 4) { 894 if (FLAGS_matrix.count() == 4) {
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
1435 #endif 1437 #endif
1436 } 1438 }
1437 } // namespace skiatest 1439 } // namespace skiatest
1438 1440
1439 #if !defined(SK_BUILD_FOR_IOS) 1441 #if !defined(SK_BUILD_FOR_IOS)
1440 int main(int argc, char** argv) { 1442 int main(int argc, char** argv) {
1441 SkCommandLineFlags::Parse(argc, argv); 1443 SkCommandLineFlags::Parse(argc, argv);
1442 return dm_main(); 1444 return dm_main();
1443 } 1445 }
1444 #endif 1446 #endif
OLDNEW
« no previous file with comments | « no previous file | dm/DMSrcSink.h » ('j') | src/core/SkPipe.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698