Index: gm/textblobgeometrychange.cpp |
diff --git a/gm/textblobgeometrychange.cpp b/gm/textblobgeometrychange.cpp |
index 0632908dfbfa8ee2ffb8fffdd001a6e4f6713f78..b1c5b179880663716864060e1d812a58c719fa0f 100644 |
--- a/gm/textblobgeometrychange.cpp |
+++ b/gm/textblobgeometrychange.cpp |
@@ -42,8 +42,11 @@ protected: |
SkAutoTUnref<const SkTextBlob> blob(builder.build()); |
- SkImageInfo info = SkImageInfo::MakeN32Premul(200, 200); |
- SkSurfaceProps props(0, kUnknown_SkPixelGeometry); |
+ SkImageInfo info = SkImageInfo::MakeN32Premul(200, 200, canvas->imageInfo().profileType()); |
+ SkSurfaceProps canvasProps(SkSurfaceProps::kLegacyFontHost_InitType); |
+ uint32_t allowSRGBInputs = canvas->getProps(&canvasProps) |
+ ? canvasProps.flags() & SkSurfaceProps::kAllowSRGBInputs_Flag : 0; |
+ SkSurfaceProps props(allowSRGBInputs, kUnknown_SkPixelGeometry); |
auto surface(canvas->makeSurface(info, &props)); |
if (surface) { |
SkCanvas* c = surface->getCanvas(); |