This repository has been archived by the owner on Feb 25, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6k
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
flar
commented
Dec 20, 2022
217c86b
to
4fe453d
Compare
This was referenced Dec 22, 2022
@endless7 does this solution answer your concerns about the correlation of ops to bounds in the R-Tree? |
flar
commented
Dec 22, 2022
ColdPaleLight
approved these changes
Dec 22, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fantastic! LGTM!
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/flutter
that referenced
this pull request
Dec 22, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/flutter
that referenced
this pull request
Dec 22, 2022
auto-submit bot
pushed a commit
to flutter/flutter
that referenced
this pull request
Dec 23, 2022
…117563) * 23582159a [web] Render in custom target (flutter/engine#37738) * 766f8fd91 Roll Fuchsia Mac SDK from UsYNZnnfR_s0OGQoX... to Xu_G6EQQ2UG48e5qI... (flutter/engine#38457) * 6f829b7e3 Roll Dart SDK from fc0a3217b39a to cb6245d8f8d3 (1 revision) (flutter/engine#38458) * 74d9ba455 Roll Skia from f1610a251e3a to 67904a365fdc (1 revision) (flutter/engine#38459) * 19de6262b Roll Skia from 67904a365fdc to c93fa176c9ca (6 revisions) (flutter/engine#38460) * 147ac7d02 Display list R-Tree culling (flutter/engine#38429) * 3549fb1ed Roll Skia from c93fa176c9ca to 33807a735c32 (3 revisions) (flutter/engine#38464) * d76ccb8f4 Roll Dart SDK from cb6245d8f8d3 to 47b0d07e6be9 (3 revisions) (flutter/engine#38465) * 2c9e1d98d Roll Skia from 33807a735c32 to 89742d768c97 (3 revisions) (flutter/engine#38467) * 3b115f033 Revert "[web] Render in custom target (#37738)" (flutter/engine#38469) * ca0c843bf Roll Fuchsia Mac SDK from Xu_G6EQQ2UG48e5qI... to W0GUdjHi4gI48optN... (flutter/engine#38468)
This PR shows a net gain in the builder benchmarks for the kRtree and kBoundsAndRtree sub-measurements: |
XilaiZhang
added a commit
that referenced
this pull request
Dec 23, 2022
This reverts commit 147ac7d.
I got it. Thanks!! |
loic-sharma
pushed a commit
to loic-sharma/flutter-engine
that referenced
this pull request
Jan 3, 2023
* collect DL indices in RTree for clip culling * fix bounds in unit test and minor opt in Dispatch * normalize inline matrix objects and minor fixes to unit test * remove over-eager DCHECK and improve R-Tree comments * formatting * include vector for Windows * method rename and distribute child nodes more evenly * add R-Tree specific unit tests and debug checks * add comments about geometry to R-Tree unit tests and adjust spacing * licenses * licenses attempt 2 * fix potential overflow with uint32_t * aggressively const DisplayList fields and methods * add implementation comments per review feedback
loic-sharma
pushed a commit
to fluttergithubbot/flutter
that referenced
this pull request
Jan 6, 2023
…lutter#117563) * 23582159a [web] Render in custom target (flutter/engine#37738) * 766f8fd91 Roll Fuchsia Mac SDK from UsYNZnnfR_s0OGQoX... to Xu_G6EQQ2UG48e5qI... (flutter/engine#38457) * 6f829b7e3 Roll Dart SDK from fc0a3217b39a to cb6245d8f8d3 (1 revision) (flutter/engine#38458) * 74d9ba455 Roll Skia from f1610a251e3a to 67904a365fdc (1 revision) (flutter/engine#38459) * 19de6262b Roll Skia from 67904a365fdc to c93fa176c9ca (6 revisions) (flutter/engine#38460) * 147ac7d02 Display list R-Tree culling (flutter/engine#38429) * 3549fb1ed Roll Skia from c93fa176c9ca to 33807a735c32 (3 revisions) (flutter/engine#38464) * d76ccb8f4 Roll Dart SDK from cb6245d8f8d3 to 47b0d07e6be9 (3 revisions) (flutter/engine#38465) * 2c9e1d98d Roll Skia from 33807a735c32 to 89742d768c97 (3 revisions) (flutter/engine#38467) * 3b115f033 Revert "[web] Render in custom target (flutter#37738)" (flutter/engine#38469) * ca0c843bf Roll Fuchsia Mac SDK from Xu_G6EQQ2UG48e5qI... to W0GUdjHi4gI48optN... (flutter/engine#38468)
gspencergoog
pushed a commit
to gspencergoog/flutter
that referenced
this pull request
Jan 19, 2023
…lutter#117563) * 23582159a [web] Render in custom target (flutter/engine#37738) * 766f8fd91 Roll Fuchsia Mac SDK from UsYNZnnfR_s0OGQoX... to Xu_G6EQQ2UG48e5qI... (flutter/engine#38457) * 6f829b7e3 Roll Dart SDK from fc0a3217b39a to cb6245d8f8d3 (1 revision) (flutter/engine#38458) * 74d9ba455 Roll Skia from f1610a251e3a to 67904a365fdc (1 revision) (flutter/engine#38459) * 19de6262b Roll Skia from 67904a365fdc to c93fa176c9ca (6 revisions) (flutter/engine#38460) * 147ac7d02 Display list R-Tree culling (flutter/engine#38429) * 3549fb1ed Roll Skia from c93fa176c9ca to 33807a735c32 (3 revisions) (flutter/engine#38464) * d76ccb8f4 Roll Dart SDK from cb6245d8f8d3 to 47b0d07e6be9 (3 revisions) (flutter/engine#38465) * 2c9e1d98d Roll Skia from 33807a735c32 to 89742d768c97 (3 revisions) (flutter/engine#38467) * 3b115f033 Revert "[web] Render in custom target (flutter#37738)" (flutter/engine#38469) * ca0c843bf Roll Fuchsia Mac SDK from Xu_G6EQQ2UG48e5qI... to W0GUdjHi4gI48optN... (flutter/engine#38468)
This was referenced Jun 1, 2023
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes: flutter/flutter#92740
This PR uses an R-Tree (when computed by the Builder) to cull the dispatching of a DisplayList similar to what is done in SkPicture objects when constructed with a bbox factory.
Some additional changes:
Push
which means the rectangles need to be tagged withop_index_ - 1
. I eventually want to move the bounds calculations to before thePush
calls and then potentially use them to proactively cull operations that will never be visible due to clipping.The basic principle here is to add the "index" of every rendering op to the DisplayList R-Tree. At rendering time, if the DL is a super-set of the current clip bounds then an R-Tree search is done on those bounds and only the indicated rendering ops are executed. Also executed are all attribute ops, any saveLayer/restore enclosing a chosen rendering op, and any transform/clip operations that will be followed by a matched rendering op before their next restore.
Previous PR prototypes (now obsolete):