Skip to content

Code to transfer the fine-grained bounds in DrawDisplayList should have a cap #133436

@flar

Description

@flar

Currently the code that transfers the bounds of a DisplayList that has an RTree into another that also has an RTree will iterate over all bounds of all ops, even if they don't fit inside the current clip or cull rect of the target DisplayList. For one app that generated a picture with 300,000 DrawLine calls that extended hundreds of thousands of pixels off of the screen, it depends on proper culling of the DisplayLists in order to achieve decent performance on small screens.

The code in that method should pass the current cull rect of the DisplayList to the search-and-consolidate method to avoid a huge potentially quadratic consolidation of rectangles far outside the current view.

Another possible solution is described in #139323 which avoids copying all of the rects during the build phase of a DL.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listc: proposalA detailed proposal for a change to Flutterengineflutter/engine related. See also e: labels.team-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    Status

    ⚡ Performance

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions