From ebb33d946ae5e2f05fd2f51defeae05a7303379b Mon Sep 17 00:00:00 2001 From: Brian Osman Date: Wed, 18 Apr 2018 21:00:00 -0400 Subject: [PATCH] Enable downscale of very large images when uploading on IO thread (flutter/engine#5011) --- engine/src/flutter/lib/ui/painting/codec.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/engine/src/flutter/lib/ui/painting/codec.cc b/engine/src/flutter/lib/ui/painting/codec.cc index 758a722b40..c75ec5fef3 100644 --- a/engine/src/flutter/lib/ui/painting/codec.cc +++ b/engine/src/flutter/lib/ui/painting/codec.cc @@ -63,7 +63,7 @@ static sk_sp DecodeImage(fml::WeakPtr context, // This indicates that we do not want a "linear blending" decode. sk_sp dstColorSpace = nullptr; return SkImage::MakeCrossContextFromEncoded( - context.get(), std::move(buffer), false, dstColorSpace.get()); + context.get(), std::move(buffer), false, dstColorSpace.get(), true); } else { // Defer decoding until time of draw later on the GPU thread. Can happen // when GL operations are currently forbidden such as in the background