Index: dm/DMSrcSink.cpp |
diff --git a/dm/DMSrcSink.cpp b/dm/DMSrcSink.cpp |
index 394b84fa7bd568a6a44a0235cff6bfb08a1201f7..9a73b8b32eed16ff79dff47c9a18a4075f00c6b8 100644 |
--- a/dm/DMSrcSink.cpp |
+++ b/dm/DMSrcSink.cpp |
@@ -1019,10 +1019,11 @@ Error ViaPipe::draw(const Src& src, SkBitmap* bitmap, SkWStream* stream, SkStrin |
Error ViaRemote::draw(const Src& src, SkBitmap* bitmap, SkWStream* stream, SkString* log) const { |
return draw_to_canvas(fSink, bitmap, stream, log, src.size(), [&](SkCanvas* canvas) { |
- SkAutoTDelete<SkRemote::Cache> cache(fCache ? SkRemote::Cache::CreateAlwaysCache() |
- : SkRemote::Cache::CreateNeverCache()); |
SkRemote::Server server(canvas); |
- SkRemote::Client client(cache, &server); |
+ SkAutoTDelete<SkRemote::Encoder> cache(fCache |
+ ? SkRemote::Encoder::CreateCachingEncoder(&server) |
+ : nullptr); |
+ SkRemote::Client client(cache.get() ? cache.get() : &server); |
return src.draw(&client); |
}); |
} |