Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[paint] Paint based on a paint tree instead of the layout tree #12

Open
usadson opened this issue Jul 2, 2023 · 0 comments
Open

[paint] Paint based on a paint tree instead of the layout tree #12

usadson opened this issue Jul 2, 2023 · 0 comments
Labels
🖌️ paint Painting the pages

Comments

@usadson
Copy link
Owner

usadson commented Jul 2, 2023

At the moment, the page is painted by walking the layout tree, and invoking paint calls if needed. This is fine, but having a paint tree that is constructed based on a layout tree is better for a few reasons:

  1. The paint tree can be individually optimized, for example if there are two overlapping background with the same size, only the last one is needed.
  2. The paint tree can be divided to compliment the tile-based rendering.
  3. Scrolling the page can reuse existing tiles that are painted using these paint nodes, and new tiles can be painted without losing the complete page.

Blocks #21.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🖌️ paint Painting the pages
Projects
Status: Todo
Development

No branches or pull requests

1 participant