Disable the cache on the GrContext used for decoding images (flutter/engine#3451)

Fixes https://github.com/flutter/flutter/issues/8429
This commit is contained in:
Jason Simmons
2017-02-27 16:21:21 -08:00
committed by GitHub
parent 396912456c
commit 5683b4d5fc

View File

@@ -177,6 +177,11 @@ void PlatformView::SetupResourceContextOnIOThreadPerform(
reinterpret_cast<GrBackendContext>(GrGLCreateNativeInterface()),
options));
// Do not cache textures created by the image decoder. These textures should
// be deleted when they are no longer referenced by an SkImage.
if (blink::ResourceContext::Get())
blink::ResourceContext::Get()->setResourceCacheLimits(0, 0);
latch->Signal();
}