Commit graph

8894 commits

Author SHA1 Message Date
bors-servo
57846678c2
Auto merge of #26638 - szeged:texi2d_2, r=jdm
Add support for WebGL2 TexImage2D

Adds initial support for one of the WebGL2 `TexImage2D` call.

<!-- Please describe your changes on the following line: -->
I've enabled the `conformance2/textures/image/` tests and updated the test expectations.

---
<!-- 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] There are tests for these changes

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->
@mmatyas @zakorgy @jdm
<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
2020-05-26 06:13:27 -04:00
Istvan Miklos
b298160ff2 Add support for WebGL2 TexImage2D
Adds initial support for one of the WebGL2 `TexImage2D` call.
2020-05-26 11:33:58 +02:00
bors-servo
95a818e262
Auto merge of #26630 - kunalmohan:gpu-sampler, r=jdm
Add GPUSampler to WebGPU implementation

Add dom_struct and webidl for GPUSampler, implement GPUDevice.createSampler() method.

<!-- Please describe your changes on the following line: -->
r?@kvark

---
<!-- 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
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
2020-05-25 17:54:25 -04:00
Simon Sapin
d103e06ba9 Use dynamic dispatch in mozjs::panic::wrap_panic
Pick up https://github.com/servo/rust-mozjs/pull/512

Fixes https://github.com/servo/servo/issues/26585

This diff is best viewed with "ignore whitespace changes", because of indentation change.
2020-05-25 20:34:05 +02:00
Kunal Mohan
dd04716b85 Add GPUSampler to WebGPU implementation
Add dom_struct and webidl for GPUSampler, implement GPUDevice.createSampler() method.
2020-05-26 00:00:35 +05:30
bors-servo
ce076a8382
Auto merge of #26623 - jdm:imagebitmap-gate, r=gterzian
Add a preference to control ImageBitmap while it's incomplete.

Hubs tries to make use of incomplete APIs to load textures and this causes errors. It works fine if we hide the interface instead.
2020-05-25 00:08:19 -04:00
Josh Matthews
d3867c32db Add a preference to control ImageBitmap while it's incomplete. 2020-05-23 11:43:15 -04:00
bors-servo
dde7204756
Auto merge of #26624 - jdm:script-unminify, r=asajeffrey
Use temporary files instead of pipes for JS unminification.

This change allows me to use `--unminify-js` when loading a local Hubs server. Previously there would be multiple hung js-beautifier processes and the page would never make any progress.
2020-05-22 19:20:30 -04:00
Josh Matthews
8f4cb28a6d Use temporary files instead of pipes for JS unminification. 2020-05-22 14:40:50 -04:00
Kunal Mohan
39f336b527 Implement client-side logic for WebGPU id recycling 2020-05-22 21:22:19 +05:30
bors-servo
94063d67a8
Auto merge of #26564 - kunalmohan:gpu-id-rotation, r=jdm
Upgrade wgpu version to "0.5.0" and add server-side code for id recycling for WebGPU

<!-- Please describe your changes on the following line: -->
I have updated the cargo.lock to use a wgpu-core at a more recent commit where IdentityHandlerFactory was introduced.
r?@kvark

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [ ] `./mach build -d` does not report any errors
- [ ] `./mach test-tidy` does not report any errors
- [ ] These changes fix #___ (GitHub issue number if applicable)

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
2020-05-21 13:24:55 -04:00
Kunal Mohan
f3fa53b849 update rust toolchain 2020-05-21 21:51:49 +05:30
bors-servo
70700c20ed
Auto merge of #26594 - mrobinson:animationiteration, r=jdm
Implement animationiteration event

This event is triggered when an animation iterates. This change also
moves iteration out of style calculation to an "update animations" which
is the next part of having animation event handling match the HTML spec.

This change causes a few more tests to pass. Some of the other tests which
exercise this functionality require `animationstart` events.

---
<!-- 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)
- [x] There are tests for these changes

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
2020-05-21 10:11:45 -04:00
Martin Robinson
873cdd1336 Implement animationiteration event
This event is triggered when an animation iterates. This change also
moves iteration out of style calculation to an "update animations" which
is the next part of having animation event handling match the HTML spec.
2020-05-21 15:19:34 +02:00
Kunal Mohan
a4f911699a Upgrade wgpu-core version to 0.5.0 and implement server-side logic for wgpu id recycling
Remove current implementation of MapReadAsync
2020-05-21 18:28:49 +05:30
bors-servo
1986adee0b
Auto merge of #26520 - szeged:texi2d, r=jdm
Add support for WebGL2 TexImage2D

Adds initial support for one of the WebGL2 `TexImage2D` call.

<!-- 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
- [x] These changes fix part of #26512
- [x] There are tests for these changes

@mmatyas @zakorgy @jdm
<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
2020-05-21 08:16:00 -04:00
Istvan Miklos
035cb6ebaa Add support for WebGL2 TexImage2D
Adds initial support for one of the WebGL2 `TexImage2D` call.
2020-05-21 10:49:51 +02:00
Gregory Terzian
bd31860c5d serviceworker: turn-off event-loop, don't assume current scope, clear runtime on shutdown 2020-05-21 13:21:28 +08:00
Gregory Terzian
89eb7c2aa2 serviceworker: make job queue unique per origin 2020-05-21 13:21:21 +08:00
bors-servo
e17b53eba5
Auto merge of #26546 - splav:tls-protected-checks, r=jdm
check http_state in determine_request_referrer

<!-- Please describe your changes on the following line: -->
Check https status inside determine_request_referrer.
---
<!-- 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 #14506 (GitHub issue number if applicable)

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
2020-05-19 18:03:35 -04:00
Alexandrov Sergey
357b486455 make is_origin_trustworthy a method of ServoUrl + fix localhost handling 2020-05-19 20:06:59 +03:00
Alexandrov Sergey
a7c5c97616 check http_state in determine_request_referrer 2020-05-19 20:06:59 +03:00
bors-servo
cab9104d92
Auto merge of #26499 - utsavoza:ugo/issue-26287/10-05-2020, r=jdm
Add creator URL, creator base URL and creator origin to browsing context

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #24944 and fix (partially) #26287
- [x] There are tests for these changes
2020-05-19 12:45:11 -04:00
bors-servo
79b6758cb9
Auto merge of #26484 - servo:layout-2020-style-prep, r=SimonSapin
Implement concept of dirty root
2020-05-19 11:40:58 -04:00
Anthony Ramine
036f123c4e Implement concept of dirty root 2020-05-19 16:26:36 +02:00
Anthony Ramine
518c0660c6 Make Node::style_and_layout_data be a DomRefCell<T>
That way we can use borrow_mut_for_layout and borrow_mut.
2020-05-19 15:51:55 +02:00
Utsav Oza
9b0b03a432 Update wpt-tests metadata 2020-05-19 16:32:10 +05:30
bors-servo
c183f95297
Auto merge of #26551 - Manishearth:per-view, r=asajeffrey
Update to handle per-view eye transforms

Depends on https://github.com/servo/webxr/pull/175
2020-05-18 11:21:33 -04:00
Manish Goregaokar
d627476893 Update to treat view transforms as native-relative 2020-05-18 08:20:54 -07:00
Manish Goregaokar
a97dcd9ad6 Update to use webxr_api::ViewerPose 2020-05-18 08:20:33 -07:00
Manish Goregaokar
794624b42b Move viewports to being per-session, not per-frame 2020-05-18 08:20:19 -07:00
Manish Goregaokar
eaad692c0b Use cached projection matrix 2020-05-18 08:19:42 -07:00
Manish Goregaokar
708824700f Make views a per-frame deal 2020-05-18 08:19:42 -07:00
Utsav Oza
4c637e0601 Update wpt-tests metadata 2020-05-18 19:07:57 +05:30
Utsav Oza
55a3eb6bf4 Run mach test-tidy 2020-05-18 19:07:57 +05:30
Utsav Oza
ab672577e8 Add creator URL, creator base URL and creator origin in browsing context 2020-05-18 19:07:57 +05:30
Utsav Oza
1c78728ff1 Parse location url relative to the entry settings object 2020-05-18 19:07:57 +05:30
Anthony Ramine
15db31769c Make DomRefCell not mutate the borrow flag non-atomically 2020-05-18 10:23:46 +02:00
bors-servo
1a74382603
Auto merge of #26541 - kunalmohan:copy-buffer-to-buffer, r=kvark,jdm
Validate copybuffertobuffer() + some spec update

The spec update includes renaming bindings to entries, adding CommandEncoderState and renaming GPUBufferSize to GPUSize64.

<!-- Please describe your changes on the following line: -->
r?@jdm @kvark

---
<!-- 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
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
2020-05-15 23:41:34 -04:00
Kunal Mohan
1aeae47299 Validate copybuffertobuffer() + some spec update
The spec update includes renaming bindings to entries and
adding CommandEncoderState.
2020-05-15 22:55:08 +05:30
Simon Sapin
1f6efbf9e9 Correctly paint the CSS canvas’ background
https://drafts.csswg.org/css-backgrounds/#special-backgrounds

Fixes https://github.com/servo/servo/issues/25559
Closes https://github.com/servo/servo/pull/26121, as it is an alternative.
2020-05-15 13:37:09 +02:00
Kunal Mohan
e5065c7eb2 Share single gpu_id_hub among all threads in a process 2020-05-15 01:15:01 +05:30
bors-servo
329f081e6a
Auto merge of #26513 - jdm:webgl2-formats, r=asajeffrey
Reject incompatible webgl texture pixel data

The tests that would make these changes most visibly correct unfortunately rely on texImage3D which isn't implemented yet, so they error out too soon. However, when I comment out that code, these changes avoid a bunch of panics in the webgl thread because of invalid data type combinations being accepted, and removing the incorrect non-filterable texture fallback behaviour for webgl 2 when more texture formats are supposed to be filterable.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] There are tests for these changes
2020-05-13 18:33:37 -04:00
Josh Matthews
7151ee25c8 webgl: Reject incompatible 2d texture pixel data based on texture data type. 2020-05-13 16:22:31 -04:00
bors-servo
52d9fb57fb
Auto merge of #26434 - jdm:playground, r=Manishearth
Allow BabylonJS playground to load

These changes fix the JS errors that currently appear when loading the page. You can't use the editor, but the webgl canvas works just fine.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #26428 and fix #25478
- [x] There are tests for these changes
2020-05-13 15:40:23 -04:00
bors-servo
b2a6928224
Auto merge of #26491 - huangjiahua:fix, r=Manishearth
Handle cancelAnimationFrame() when called within a requestAnimationFr…

…ame() callback

<!-- Please describe your changes on the following line: -->
In order to handle `cancelAnimationFrame()` in the callback, the `raf_callback_list` is moved to
`current_raf_callback_list`, and each callback is cloned in the iteration of `current_raf_callback_list` to avoid "borrowed twice".

---
<!-- 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 #26251

<!-- Either: -->
- [X] There are tests for these changes OR
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
2020-05-13 14:38:04 -04:00
Josh Matthews
097a84671a dom: Implement current window event. 2020-05-13 14:36:32 -04:00
Josh Matthews
19f4be38d2 dom: Implement stub queryCommandSupported. 2020-05-13 14:36:32 -04:00
Josh Matthews
3abaff85f3 webgl: Mark float/half-float textures as filterable in webgl2. 2020-05-13 14:15:41 -04:00
huangjiahua
c253ad8399 Handle cancelAnimationFrame() when called within a requestAnimationFrame() callback 2020-05-13 15:41:09 +08:00