From 62925d79cb74678408a3c2e2fb98e5af8170a926 Mon Sep 17 00:00:00 2001 From: Adam Duskett Date: Fri, 3 Nov 2023 10:56:17 +0100 Subject: [PATCH] package/flutter-engine: use impeller rendering engine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From https://docs.flutter.dev/perf/impeller: Impeller provides a new rendering runtime for Flutter. The Flutter team’s believes this solves Flutter’s early-onset jank issue. Impeller precompiles a smaller, simpler set of shaders at Engine build time so they don’t compile at runtime. Impeller has the following objectives: - Predictable performance: Impeller compiles all shaders reflection and offline at build time. It builds all pipeline state objects upfront. The engine controls caching and caches explicitly. - Instrumentable: Impeller tags and labels all graphics resources like textures, and buffers. It can capture and persist animations to disk without affecting per-frame rendering performance. - Portable: Flutter doesn’t tie Impeller to a specific client rendering API. You can author shaders once and convert them to backend-specific formats as necessary. - Leverages modern graphics APIs: Impeller uses, but doesn’t depend on, features available in modern APIs like Metal and Vulkan. - Leverages concurrency: Impeller can distribute single-frame workloads across multiple threads if necessary. Signed-off-by: Adam Duskett Signed-off-by: Thomas Petazzoni --- package/flutter-engine/flutter-engine.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/package/flutter-engine/flutter-engine.mk b/package/flutter-engine/flutter-engine.mk index 4701c1f536..32aaa1cccf 100644 --- a/package/flutter-engine/flutter-engine.mk +++ b/package/flutter-engine/flutter-engine.mk @@ -124,6 +124,7 @@ endif ifeq ($(BR2_PACKAGE_HAS_LIBGLES),y) FLUTTER_ENGINE_DEPENDENCIES += libgles +FLUTTER_ENGINE_CONF_OPTS += --enable-impeller-opengles endif ifeq ($(BR2_PACKAGE_LIBGLFW),y) @@ -142,7 +143,7 @@ endif # There is no --disable-vulkan option ifeq ($(BR2_PACKAGE_MESA3D_VULKAN_DRIVER),y) -FLUTTER_ENGINE_CONF_OPTS += --enable-vulkan +FLUTTER_ENGINE_CONF_OPTS += --enable-vulkan --enable-impeller-vulkan endif ifeq ($(BR2_PACKAGE_XORG7)$(BR2_PACKAGE_LIBXCB),yy)