diff options
author | Matt Sarett <msarett@google.com> | 2017-02-07 13:56:11 -0500 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-02-07 19:33:37 +0000 |
commit | 77a7a1b57c16c97f056c1e50c03bdc954947778c (patch) | |
tree | 15ffacdee0ba8b0a0c8ac244302ef10ead4f915e /gm/readpixels.cpp | |
parent | 4f51aa57eaa4187696f7830ee7bdac096bc47ccc (diff) |
SkColorSpace: remove named API, add gamut API
Reland from: https://skia-review.googlesource.com/c/8021/
BUG=skia:
Change-Id: I18985f130587b15fccbc86b76b2bb5c49ba5ba8a
Reviewed-on: https://skia-review.googlesource.com/8136
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>
Diffstat (limited to 'gm/readpixels.cpp')
-rw-r--r-- | gm/readpixels.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gm/readpixels.cpp b/gm/readpixels.cpp index df7fb0751a..ad9bf8d4f4 100644 --- a/gm/readpixels.cpp +++ b/gm/readpixels.cpp @@ -86,7 +86,7 @@ static sk_sp<SkImage> make_tagged_picture_image() { return SkImage::MakeFromPicture(recorder.finishRecordingAsPicture(), SkISize::Make(kWidth, kHeight), nullptr, nullptr, SkImage::BitDepth::kU8, - SkColorSpace::MakeNamed(SkColorSpace::kSRGB_Named)); + SkColorSpace::MakeSRGB()); } static sk_sp<SkImage> make_untagged_picture_image() { @@ -144,7 +144,7 @@ static void draw_image(SkCanvas* canvas, SkImage* image, SkColorType dstColorTyp // Now that we have called readPixels(), dump the raw pixels into an srgb image. sk_sp<SkColorSpace> srgb = fix_for_colortype( - SkColorSpace::MakeNamed(SkColorSpace::kSRGB_Named).get(), dstColorType); + SkColorSpace::MakeSRGB().get(), dstColorType); sk_sp<SkImage> raw = SkImage::MakeRasterData(dstInfo.makeColorSpace(srgb), data, rowBytes); canvas->drawImage(raw.get(), 0.0f, 0.0f, nullptr); } @@ -179,7 +179,7 @@ protected: }; const sk_sp<SkColorSpace> colorSpaces[] = { make_wide_gamut(), - SkColorSpace::MakeNamed(SkColorSpace::kSRGB_Named), + SkColorSpace::MakeSRGB(), make_small_gamut(), }; @@ -237,7 +237,7 @@ protected: }; const sk_sp<SkColorSpace> colorSpaces[] = { make_wide_gamut(), - SkColorSpace::MakeNamed(SkColorSpace::kSRGB_Named), + SkColorSpace::MakeSRGB(), make_small_gamut(), }; const SkImage::CachingHint hints[] = { @@ -304,7 +304,7 @@ protected: }; const sk_sp<SkColorSpace> colorSpaces[] = { make_wide_gamut(), - SkColorSpace::MakeNamed(SkColorSpace::kSRGB_Named), + SkColorSpace::MakeSRGB(), make_small_gamut(), }; const SkImage::CachingHint hints[] = { |