Skip to content

Only Build Display Items for Background if Really Necessary #19672

Closed as not planned

Description

@pyfisch

There are at least two cases where Display Items for backgrounds are emitted when they are not needed for rendering:

  1. Lower background layer is completely covered by opaque upper layer.
  2. A background image or gradient where at least one size is equal zero.

I am not sure what the performance impact of both optimizations would be. While it is very common that a gradient and a solid fallback color are specified (case 1.) there are some optimizations on the webrender side to avoid actual painting by the GPU.

Activity

  1. mrobinson commented on May 22, 2025

    @mrobinson
    Member

    I think this makes less sense for the moment now that WebRender handles culling and we don't build an intermediate display list.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions