| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch fixes a couple of issues in the compositor:
1) Remove the delayed composition code. Previously, this would schedule
a composite for 12ms in the future. This doesn't really make any sense
with WR. There's no point in doing a composite unless WR has provided
a new frame to be drawn. This fixes issues in several benchmarks where
we were doing multiple composite / renders per rAF, which is a waste
of CPU time. This *does* make the framerate slower in some cases (such
as a slow rAF callback) but it's more correct - otherwise we were just
compositing the same frame multiple times for no real benefit.
2) Inform the window of the current animation state of the compositor.
Specifically, if an animation (or rAF) is currently active, the
window system switches to use event polling, and does not block on
the OS-level event loop. In the case of active animation, we just
assume that we want to be running as the vsync interval and not
blocking. This means the compositor thread only sleeps on vsync
during animation, which reduces OS scheduling and results in much
smoother animation.
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Notify embedder when history changes
`WindowMethods::set_page_url` is only called when the embedder set the URL. It is not called when the page url is updated. I believe that instead we should just pass the URL to `head_parsed`.
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #15439 #15643 and #15642 (github issue number if applicable).
<!-- Either: -->
- [ ] There are tests for these changes OR
- [x] These changes do not require tests because I'm not sure how to test that
<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/15794)
<!-- Reviewable:end -->
|
| | |
|
|/
|
|
|
|
|
| |
Just use WebRender's ClipId directly. This will allow us to create and
use ReferenceFrames in the future, if we need to do that. It will also
make it easier to have Servo responsible for creating the root
scrolling area, which will allow removing some old hacks in the future.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
This reimplemntation of the feature uses ScrollRootIds to scroll
particular scrollable areas of the page.
Fixes #13736.
Fixes #10753.
|
| |
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Remove concept of Layers from Servo
<!-- Please describe your changes on the following line: -->
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).
<!-- Either: -->
- [ ] There are tests for these changes OR
- [x] These changes do not require tests because this PR should not change behavior.
<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
Layers were a feature of the legacy drawing path. If we re-add them at
some point, it probably makes more sense to make them a product of
display list inspection.
This change also remove a bunch of dead painting code.
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/13848)
<!-- Reviewable:end -->
|
| |
| |
| |
| |
| |
| |
| |
| | |
Layers were a feature of the legacy drawing path. If we re-add them at
some point, it probably makes more sense to make them a product of
display list inspection.
This change also remove a bunch of dead painting code.
|
|/
|
|
| |
r=emilio
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This removes paint threads, rust-layers dependency, and changes
optional webrender types to be required.
The use_webrender option has been removed, however I've left
the "-w" command line option in place so that wpt
runner can continue to pass that. Once it's removed from there
we can also remove the -w option.
Once this stage is complete, it should be fine to change the
display list building code to generate webrender display
lists directly and avoid the conversion step.
|
|
|
|
| |
keyboards.
|
|
|
|
|
|
|
|
| |
and fix the jerky scrolling "pops" during flings on Mac.
See the comments in compositor.rs for more details.
Requires servo/webrender#302 and servo/webrender_traits#64.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We needed a separate thread in the chrome process because communication to the
compositor is done through a trait object, and cross-process virtual calls are
forbidden.
Also, the fact that these messages are ultimately handled by the compositor is
an implementation detail; conceptually, the relevant constellation is supposed
to handle these messages.
So instead, the script thread will now send the messages to the constellation,
which will ask the compositor to handle them.
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Don't block the script listener thread on window.close().
Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data:
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy --faster` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).
Either:
- [ ] There are tests for these changes OR
- [x] These changes do not require tests because no tangible effect
Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process.
This does not appear to have any effect. I believe this has been the case
since e84106535175211526729e532058a7514a0de372, when the helper thread was
introduced.
It was added in a7ef1cd35e9347a285f245041db4eb94047f4ab0, where it blocked the
script thread rather than this helper thread.
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/11337)
<!-- Reviewable:end -->
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This does not appear to have any effect. I believe this has been the case
since e84106535175211526729e532058a7514a0de372, when the helper thread was
introduced.
It was added in a7ef1cd35e9347a285f245041db4eb94047f4ab0, where it blocked the
script thread rather than this helper thread.
|
| | |
|
|/ |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Add new compositor message to get scroll_offset;
Add new layout query for computed value of overflow-x/y;
Implement layer_id method for ThreadSafeLayoutNode;
Add new layout query for layer_id;
Implement script interface for getting scrollTop and scrollLeft, as well as relavant helper functions.
|
|
|
|
|
|
|
|
|
| |
This changes headless operation to strictly be a runtime option, rather
than a compile-time one. Note that the old headless version still relied
on a display server to support WebGL, while it now requires one all the
time.
Fixes #8573
|
|
|
|
|
|
|
|
|
|
| |
has loaded.
This avoids a flash of unstyled content, which looks especially bad in
browser.html since unstyled content is white and browser.html has a
transparent background.
Closes #9996.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead, schedule a delayed composite after each frame of an animation.
The previous code would cause jank, because the following sequence
frequently occurred:
1. The page uses `requestAnimationFrame()` to request a frame.
2. The compositor receives the message, schedules a composite,
dispatches the rAF message to the script thread, composites, and goes to
sleep waiting for vblank (frame 1).
3. The script makes a change and sends it through the pipeline.
Eventually it gets painted and is sent to the compositor, but the
compositor is sleeping.
4. The compositor wakes up, sees the new painted content, page flips,
and goes to sleep (frame 2). Repeat from step 1.
The problem is that we have two composition frames, not just one. This
halves Web apps' framerate!
This commit fixes the problem by scheduling the composite in step 2 to
12 ms in the future. We already have this delayed-composition
functionality in the form of the scrolling timer, which I repurposed and
renamed to the "delayed composition timer" for this task. This change
gives the page 12 ms to prepare the frame, which seems to usually be
enough, especially with WebRender.
Note that simply removing the scheduled composite after rAF is not the
correct solution. If this is done, then pages that call rAF and don't
modify the page won't receive future rAFs, since the compositor will be
sleeping and won't be notified of vblank.
Fixes a bunch of jank in browser.html. The remaining jank seems to be a
problem with browser.html itself.
|
|
|
|
|
|
|
|
| |
WebRender is an experimental GPU accelerated rendering backend for Servo.
The WebRender backend can be specified by running Servo with the -w option (otherwise the default rendering backend will be used).
WebRender has many bugs, and missing features - but it is usable to browse most websites - please report any WebRender specific rendering bugs you encounter!
|
| |
|
|
|
|
| |
Resolves #9223
|
| |
|
|
|
|
|
| |
Resolves #9222. Moved Epoch from components/msg/compositor_msg to
components/gfx_traits/lib. Updated use statements to reflect the move.
|
|
|