How flutter-team-archive/engine works
Flutter Engine is a portable runtime that hosts Flutter applications across platforms. The principal workflow is an embedding or host application starting the engine, which runs Dart code and produces graphics for a platform surface. The repository also contains display-list recording, Impeller rendering, platform integration, I/O, accessibility, plugins, and shader-compilation support. The README establishes these capabilities; sampled source confirms Android multi-engine creation and GPU-pipeline construction. Many subsystem links are dashed because their implementation was not sampled.
Main entry points: engine.cc Engine Core · pipeline_descriptor.cc GPU Pipelines · platform Platform Embedders · layer_tree.cc Layer Compositor
Components 21
Hosting and Runtime
- Platform Embedders
shell/platform - Engine Core
shell/common/engine.cc - Dart Runtime
runtime - Isolate Manager
runtime/platform_isolate_manager.cc
Graphics and Rendering
- Display Lists
display_list/display_list.cc - Layer Compositor
flow/layers/layer_tree.cc - Compositor Context
flow/compositor_context.cc - Render Surfaces
flow/surface.cc - Impeller Display Lists
impeller/display_list - GPU Pipelines
impeller/renderer/pipeline_descriptor.cc - Graphics Backends
impeller/renderer/backend - GPU API
lib/gpu/render_pipeline.cc
Platform Services
- Plugin Architecture
shell/platform/android/io/flutter/embedding/engine/FlutterEngineConnectionRegistry.java - Accessibility
shell/platform - File and Network I/O
lib/ui/io_manager.cc - Platform Views
flow/layers/platform_view_layer.cc
Runtime Toolchain
- Shader Compiler
impeller/compiler/compiler.cc - Font Subsetting
tools/font_subset/main.cc
Runtime Foundation
- Task Runners
common/task_runners.cc - Persistent Cache
common/graphics/persistent_cache.cc
Other components
- Host Application
Connections 18
- Host Application → Platform Embedders: starts
- Platform Embedders → Engine Core: hosts
- Engine Core → Dart Runtime: runs Dart
- Engine Core → Isolate Manager: manages isolates
- Engine Core → Display Lists: composes graphics
- Display Lists → Layer Compositor: feeds composition
- Layer Compositor → Compositor Context: composes layers
- Compositor Context → Render Surfaces: renders to
- Impeller Display Lists → GPU Pipelines: uses pipeline
- GPU API → GPU Pipelines: configures
lib/gpu/render_pipeline.cc - GPU Pipelines → Graphics Backends: creates pipelines
- Platform Embedders → Plugin Architecture: provides plugins
shell/platform/android/io/flutter/embedding/engine/FlutterEngine.java - Engine Core → Accessibility: supports
- Engine Core → File and Network I/O: provides I/O
- Layer Compositor → Platform Views: represents views
- Shader Compiler → GPU Pipelines: compiles shaders
- Engine Core → Task Runners: uses task runners
- Engine Core → Persistent Cache: uses cache