diff --git a/engine/src/flutter/shell/platform/darwin/graphics/FlutterDarwinExternalTextureMetal.mm b/engine/src/flutter/shell/platform/darwin/graphics/FlutterDarwinExternalTextureMetal.mm index 2dc6febb04..5618f75a41 100644 --- a/engine/src/flutter/shell/platform/darwin/graphics/FlutterDarwinExternalTextureMetal.mm +++ b/engine/src/flutter/shell/platform/darwin/graphics/FlutterDarwinExternalTextureMetal.mm @@ -39,6 +39,9 @@ FLUTTER_ASSERT_ARC - (void)dealloc { CVPixelBufferRelease(_lastPixelBuffer); if (_textureCache) { + CVMetalTextureCacheFlush(_textureCache, // cache + 0 // options (must be zero) + ); CFRelease(_textureCache); } }