Skip to content
This repository has been archived by the owner on Jul 10, 2023. It is now read-only.

Avoid unnecessary buffer requests #118

Merged
merged 1 commit into from
Oct 2, 2014
Merged

Avoid unnecessary buffer requests #118

merged 1 commit into from
Oct 2, 2014

Conversation

mrobinson
Copy link
Member

Now that layers can mask their children, we should avoid issuing buffer
requests for areas outside of the mask region. At the same time, layers
can now be positioned and sized so that they do not intersect with their
parents at all. In those cases, we still need to issue buffer requests
for the layers even if their parents do not intersect the redraw region.

rect_in_window.size);

match layer_rect.intersection(&layer_bounds) {
redraw_rect: TypedRect<LayerPixel, f32>) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is dirty_rect a better name here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dirty_rect definitely works for me.

Now that layers can mask their children, we should avoid issuing buffer
requests for areas outside of the mask region. At the same time, layers
can now be positioned and sized so that they do not intersect with their
parents at all. In those cases, we still need to issue buffer requests
for the layers even if their parents do not intersect the redraw region.
zwarich pushed a commit that referenced this pull request Oct 2, 2014
Avoid unnecessary buffer requests
@zwarich zwarich merged commit a2717c9 into servo:master Oct 2, 2014
@mrobinson mrobinson deleted the redraw-optimization branch October 14, 2014 20:58
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants