Refactor spatial tree accessors and update
Categories
(Core :: Graphics: WebRender, task)
Tracking
()
Tracking | Status | |
---|---|---|
firefox94 | --- | affected |
People
(Reporter: gw, Assigned: gw)
Details
Attachments
(3 files)
Assignee | ||
Comment 1•3 years ago
|
||
In future, spatial tree nodes will not be stored in a flat
vec array. Instead, they'll be retained based on their unique
key. To prepare for this, refactor the spatial tree so that
all access to nodes is done via an accessor, and the tree
update no longer relies on split_mut
.
Updated•3 years ago
|
Assignee | ||
Comment 2•3 years ago
|
||
Previously, the GPU transform palette always stored the local ->
world transform for each spatial node with O(1) access time.
This won't be feasible in future when spatial nodes are retained
and stored with opaque handles.
Although this was previously a small optimization, it's no longer
important. With picture caching and raster roots, querying the
local -> world transform should be relatively rare (and even rarer
once all surfaces establish raster roots).
We still retain the optimization that querying an identity transform
(where the from == to spatial node) avoids a hash lookup and always
resolves to the first transform in the palette, since this is quite
common.
Assignee | ||
Comment 3•3 years ago
|
||
Since spatial node indices will become opaque handles in future,
remove the last part of code outside spatial_tree
that relies
on the index. In this case, switch the hit-testing code to use
the spatial node indices as a hash key. This is unlikely to have
any noticeable performance impact since hit-tests are relatively
rare, and generally only access a small number of spatial nodes.
Pushed by gwatson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/a90fa338971b Pt 1 - Refactor spatial tree accessors and update r=gfx-reviewers,kvark
Comment 5•3 years ago
|
||
bugherder |
Updated•3 years ago
|
Updated•3 years ago
|
Pushed by gwatson@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/aae10c334f6d Pt 2 - Refactor spatial tree accessors and update r=gfx-reviewers,kvark https://hg.mozilla.org/integration/autoland/rev/c3ddc8726b7b Pt 3 - Make spatial node indices an opaque type r=gfx-reviewers,kvark
Comment 7•3 years ago
|
||
bugherder |
Assignee | ||
Updated•3 years ago
|
Updated•3 years ago
|
Description
•