I've been working on a redesign of the compositor, in order to make
rust-layers more functional as a standalone library and also to simplify
ownership of the layer tree. In the current design, there are two
parallel trees, one of rust-layer ContainerLayers/TextureLayers and one
of servo CompositorLayers.

The main aspects of the rework:

* ContainerLayers (and thus rust-layers) will know about tiling and
BufferRequests.
* ComposiorLayer will disappear, instead tacked on via generics to
ContainerLayer with its methods replaced by ContainerLayer helper
methods in servo.
* The layer tree will be a simple tree owned by Scene, hopefully
eliminating mutable roots.

Old design:
https://docs.google.com/drawings/d/1xcsfjxAsfhpAFIv0C9bMnC1VgiEPsmY5cawdBdiKCT4/edit?usp=sharing
New design:
https://docs.google.com/drawings/d/1oohFBhHM-AlhKbehTt8gbPPYWtrX_eZE7W7LXPSSxj0/edit

I have a patch for the first two parts, which I hope to post soon. It's
big and complicated, because of the inherent messiness of reworking the
tree structure. My hope is that it can land soon and I can begin to move
onto the last phase of the redesign.

After the first patch lands and before the work is done, performance may
regress, because I've had to create more mutable roots
(std::cell::RefCell) to access the data that used to be in
ContainerLayer. These should disappear in the future. My hope is that
functionality does not regress, though the change is large and invasive,
so there may be new unexpected failures. I will try to stay on top of
everything.

--Martin
_______________________________________________
dev-servo mailing list
dev-servo@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-servo

Reply via email to