Skip to content

Scene.toImage/toImageSync does not include TextureLayer contents #107576

@jonahwilliams

Description

@jonahwilliams

See also flutter/engine#34624

When calling Scene.toImage/toImageSync, we first flatten the scene into a single display list, and then rasterize it on the engine thread. This flattening happens on the Ui thread, unlike regular rendering which happens on the engine/raster thread. The UI thread does not have access to the texture registry necessary to draw textures, so they are not included in the scene.

We should update these APIs so they post a task to the engine thread to flatten with a texture registry.

@dnfield @zanderso

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High-priority issues at the top of the work listcustomer: googleVarious Google teamsengineflutter/engine related. See also e: labels.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions