aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm/color4f.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'gm/color4f.cpp')
-rw-r--r--gm/color4f.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/gm/color4f.cpp b/gm/color4f.cpp
index 5a516a569b..33d837786a 100644
--- a/gm/color4f.cpp
+++ b/gm/color4f.cpp
@@ -73,13 +73,10 @@ DEF_SIMPLE_GM(color4f, canvas, 1024, 260) {
// even if it holds sRGB values.
bg.setColor(0xFFFFFFFF);
- sk_sp<SkColorSpace> colorSpaces[]{
- nullptr,
- SkColorSpace::NewNamed(SkColorSpace::kSRGB_Named)
- };
- for (auto colorSpace : colorSpaces) {
+ SkColorProfileType const profiles[] { kLinear_SkColorProfileType, kSRGB_SkColorProfileType };
+ for (auto profile : profiles) {
const SkImageInfo info = SkImageInfo::Make(1024, 100, kN32_SkColorType, kPremul_SkAlphaType,
- colorSpace);
+ profile);
auto surface(SkSurface::MakeRaster(info));
surface->getCanvas()->drawPaint(bg);
draw_into_canvas(surface->getCanvas());