Index: gm/image.cpp |
diff --git a/gm/image.cpp b/gm/image.cpp |
index b57ec3a687e4b93c75ef3c27b2b97220945374e1..a67ed202dbea196f157d3d55e6877cc6f1de2c9c 100644 |
--- a/gm/image.cpp |
+++ b/gm/image.cpp |
@@ -349,14 +349,14 @@ static SkImageGenerator* gen_picture(const SkImageInfo& info) { |
static SkImageGenerator* gen_png(const SkImageInfo& info) { |
sk_sp<SkImage> image(make_raster(info, nullptr, draw_opaque_contents)); |
- SkAutoTUnref<SkData> data(image->encode(SkImageEncoder::kPNG_Type, 100)); |
- return SkImageGenerator::NewFromEncoded(data); |
+ sk_sp<SkData> data(image->encode(SkImageEncoder::kPNG_Type, 100)); |
+ return SkImageGenerator::NewFromEncoded(data.get()); |
} |
static SkImageGenerator* gen_jpg(const SkImageInfo& info) { |
sk_sp<SkImage> image(make_raster(info, nullptr, draw_opaque_contents)); |
- SkAutoTUnref<SkData> data(image->encode(SkImageEncoder::kJPEG_Type, 100)); |
- return SkImageGenerator::NewFromEncoded(data); |
+ sk_sp<SkData> data(image->encode(SkImageEncoder::kJPEG_Type, 100)); |
+ return SkImageGenerator::NewFromEncoded(data.get()); |
} |
typedef SkImageGenerator* (*GeneratorMakerProc)(const SkImageInfo&); |