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

Unified Diff: gm/color4f.cpp

Issue 2071393002: More removal of SkColorProfileType... (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Restore API used in Chrome Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gm/all_bitmap_configs.cpp ('k') | gm/dftext.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/color4f.cpp
diff --git a/gm/color4f.cpp b/gm/color4f.cpp
index 33d837786a2e2d42c95c714b5e882fe0d73cca8e..5a516a569b640a4119faef643b877ac11b86c1fe 100644
--- a/gm/color4f.cpp
+++ b/gm/color4f.cpp
@@ -73,10 +73,13 @@ DEF_SIMPLE_GM(color4f, canvas, 1024, 260) {
// even if it holds sRGB values.
bg.setColor(0xFFFFFFFF);
- SkColorProfileType const profiles[] { kLinear_SkColorProfileType, kSRGB_SkColorProfileType };
- for (auto profile : profiles) {
+ sk_sp<SkColorSpace> colorSpaces[]{
+ nullptr,
+ SkColorSpace::NewNamed(SkColorSpace::kSRGB_Named)
+ };
+ for (auto colorSpace : colorSpaces) {
const SkImageInfo info = SkImageInfo::Make(1024, 100, kN32_SkColorType, kPremul_SkAlphaType,
- profile);
+ colorSpace);
auto surface(SkSurface::MakeRaster(info));
surface->getCanvas()->drawPaint(bg);
draw_into_canvas(surface->getCanvas());
« no previous file with comments | « gm/all_bitmap_configs.cpp ('k') | gm/dftext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698