Skip to content

[DisplayList] Inconsistencies with how opacity peephole compatibility is tracked #149622

@flar

Description

@flar

The compatibility of a layer or DisplayList with opacity peephole optimizations is tracked in 2 separate mechanisms.

The bounds accumulator checks for overlapping primitives which interferes with opacity optimizations.
The compatibility of the current rendering attributes is checked on each rendering operation and recorded as a flag.

A couple of the rendering options in the DisplayListBuilder (drawAtlas, drawVertices, drawDisplayList, drawText*) sometimes pass along a "we can't tell if our operations overlap so we need to disable opacity optimization" but they do so through the mechanism that tracks rendering attributes rather than through the bounds accumulator which would be a more accurate assessment of their conditions. This does not appear to introduce any bugs, but these cases should be tracked consistently in case we come up with a more sophisticated way to evaluate the opacity peephole conditions in the future.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issues that are less important to the Flutter projectengineflutter/engine related. See also e: labels.team-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    Status

    🤔 Needs Triage

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions