Commit graph

6710 commits

Author SHA1 Message Date
bors-servo
fa94fc7146
Auto merge of #21922 - Eijebong:storage, r=SimonSapin
Add support for StorageEvent.initstorageevent()

Fixes #21874

<!-- 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/21922)
<!-- Reviewable:end -->
2018-10-12 14:16:07 -04:00
bors-servo
69e5243810
Auto merge of #21856 - zcorpan:zcorpan/remove-td-th-interfaces, r=jdm
Remove the HTMLTable{Header,Data}CellElement interfaces

Fixes #17222.

<!-- Please describe your changes on the following line: -->
This removes the `HTMLTableHeaderCellElement` and `HTMLTableDataCellElement` interfaces and uses the `HTMLTableCellElement` interface for both `th` and `td` elements, as per the spec.

---
<!-- 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 #17222.

<!-- 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. -->

<!-- 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/21856)
<!-- Reviewable:end -->
2018-10-12 09:30:41 -04:00
bors-servo
5f463d3c97
Auto merge of #21911 - servo:webgl, r=jdm
Simplify ctx.drawImage a bit

There is no need to swap between RGBA and BGRA twice.

<!-- 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/21911)
<!-- Reviewable:end -->
2018-10-12 04:45:11 -04:00
Manish Goregaokar
40641ac8a4 More accurate names for .started and .stopped 2018-10-11 14:28:05 -07:00
Bastien Orivel
5347e25d1a Add support for StorageEvent.initstorageevent()
Fixes #21874
2018-10-11 22:17:46 +02:00
Fernando Jiménez Moreno
091ad49d68 Allow reusing AudioBuffers 2018-10-11 19:27:21 +02:00
Anthony Ramine
bb2101f540 Simplify ctx.drawImage a bit
There is no need to swap between RGBA and BGRA twice.
2018-10-11 15:46:42 +02:00
bors-servo
ddcb72f750
Auto merge of #21906 - Manishearth:minor-webaudio-fixes, r=ferjm
Minor WebAudio fixes

Stuff I discovered whilst working on https://github.com/servo/media/pull/148

r? @ferjm

<!-- 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/21906)
<!-- Reviewable:end -->
2018-10-11 08:46:18 -04:00
Manish Goregaokar
600f997a51 Increase webaudio sample rate threshold to match firefox 2018-10-10 17:32:12 -07:00
Manish Goregaokar
ceb2cd2279 Handle case when OfflineAudioContext doesn't receive all the buffers 2018-10-10 16:29:43 -07:00
chansuke
7b3cf27c69 Add task source for media element 2018-10-10 22:15:37 +09:00
bors-servo
7a88a2e28a
Auto merge of #21877 - servo:webgl, r=jdm
Improve some byte-swap and premultiply operations

<!-- 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/21877)
<!-- Reviewable:end -->
2018-10-09 20:15:40 -04:00
Anthony Ramine
6c469b90b1 Share some code between 2D canvas and WebGL 2018-10-09 14:57:02 +02:00
bors-servo
3b153af49c
Auto merge of #21543 - ceyusa:wip-player, r=<try>
Add <audio> and <video> player backends

These patches enables audio and video playing inside Servo.

It is bit hackish way to enable it, thus the purpose of this pull request is for an early request for comments.

It is tested with the current servo-media GStreamer backend in Linux.

~~The produced layout is not correct, since the elements after the video seems to be stacked behind, and the same with the scrolling bars.~~

~~There is no JavaScript interface yet~~, neither controls.

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

<!-- 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/21543)
<!-- Reviewable:end -->
2018-10-09 04:15:18 -04:00
bors-servo
552af0043a
Auto merge of #21785 - sumit0190:new_markasdirty, r=jdm
Add framebuffer check for mark_as_dirty, #21691

<!-- Please describe your changes on the following line: -->
Check `bound_framebuffer` in each `mark_as_dirty` call, so that we don't dirty the canvas if we don't have a bound framebuffer.

---
<!-- 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 #21691  (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [X] These changes do not require tests because there isn't a direct way to test it (yet).

<!-- 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. -->

<!-- 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/21785)
<!-- Reviewable:end -->
2018-10-08 21:45:55 -04:00
Fernando Jiménez Moreno
11ac049d27 Make sure we do not skip the HaveMetadata state. Fixes a bunch of tests 2018-10-08 16:12:04 +02:00
Fernando Jiménez Moreno
6b0acc9cd8 Handle Player errors 2018-10-08 16:12:04 +02:00
Fernando Jiménez Moreno
0db628028a Update servo-media: handle decoder errors and use safer/nicer player API 2018-10-08 16:12:04 +02:00
Fernando Jiménez Moreno
e31339245c Move player setup to common path, deal with setup error and clean debug msgs 2018-10-08 16:12:04 +02:00
Víctor Manuel Jáquez Leal
59d8c95b23 Network EOF does't imply media processing EOS
Since media processing is highly asynchronous, there is no need to
match one event with the other. Then error handling is done when
the player emits the EOS event.

The have_metadata attribute is not required anymore.
2018-10-08 16:12:03 +02:00
Fernando Jiménez Moreno
1c92240310 Fix HAVE_METADATA and HAVE_CURRENT_DATA state transitions 2018-10-08 16:12:03 +02:00
Fernando Jiménez Moreno
dba61ad1df Do not set metadata until we have enough data 2018-10-08 16:12:03 +02:00
Fernando Jiménez Moreno
5bbd09769c Set input size 2018-10-08 16:12:03 +02:00
Fernando Jiménez Moreno
50582f1548 Rustfmt and make tidy happy 2018-10-08 16:12:03 +02:00
Fernando Jiménez Moreno
f4ba7e503b Media element duration param 2018-10-08 16:12:03 +02:00
Fernando Jiménez Moreno
6904535865 videoWidth and videoHeight params 2018-10-08 16:12:02 +02:00
Fernando Jiménez Moreno
da0e92d7f8 Cancel fetch in some media data processing steps 2018-10-08 16:12:02 +02:00
Fernando Jiménez Moreno
b656ae195f Player pause 2018-10-08 16:12:02 +02:00
Fernando Jiménez Moreno
8fd9b72eb7 Add show poster flag 2018-10-08 16:12:02 +02:00
Fernando Jimenez Moreno
468c59a217 Abort in-progress fetching process during load algorithm 2018-10-08 16:12:02 +02:00
Fernando Jiménez Moreno
c1bd551b11 Clarify some FIXMEs and bail out if we fail pushing data to player 2018-10-08 16:12:02 +02:00
Fernando Jiménez Moreno
3fbeb398d4 Revert import style format 2018-10-08 16:12:02 +02:00
Fernando Jiménez Moreno
72b1df343e Move unsafe_no_jsmanaged_fields to trace 2018-10-08 16:12:01 +02:00
Fernando Jiménez Moreno
8c40ef459b Do not share entire FrameRenderer with layout, only current frame 2018-10-08 16:12:01 +02:00
Fernando Jiménez Moreno
1f406ef0a0 Player does not need to go inside a mutexed Arc 2018-10-08 16:12:01 +02:00
Víctor Manuel Jáquez Leal
da5d1d462f dom: add media_data() method to LayoutDom implementation 2018-10-08 16:12:00 +02:00
Víctor Manuel Jáquez Leal
74a9edfed3 dom: media: implement LayoutHTMLMediaElementHelpers trait for LayoutDom 2018-10-08 16:12:00 +02:00
Víctor Manuel Jáquez Leal
524750f41f dom: framerenderer: implement HTMLMediaFrameSource trait for MediaFrameRenderer 2018-10-08 16:12:00 +02:00
Víctor Manuel Jáquez Leal
6e3c2fe41a dom: add mediaframewebrenderer 2018-10-08 16:11:59 +02:00
Víctor Manuel Jáquez Leal
781b3b712b Provide webrender_api::RenderApiSender to ScriptThread and DOM Window
This will allow the HTMLMediaElement later to get a handle to the
RenderApi for rendering video frames.

At a later time, all media handling should be moved to its own
thread/process that is communicated with via IPC. At that point this
can be removed again.

Original-patch-by: Sebastian Dröge <sebastian@centricular.com>
2018-10-08 16:11:59 +02:00
Víctor Manuel Jáquez Leal
77c7eda0bf HACK: don't call media_source_failure_steps when eos
Because gstreamer's appsrc queue might be big enough to swallow
the whole video holding the metadata extraction until EOS.
2018-10-08 16:11:59 +02:00
Víctor Manuel Jáquez Leal
ce76b5780a dom: htmlmediaelement: add initial player bits
Also removes the usage of audio-video-metadata crate (?)
2018-10-08 16:11:59 +02:00
Víctor Manuel Jáquez Leal
0ff9ecc18a add a fixme message of not implemented mode 2018-10-08 16:11:59 +02:00
Víctor Manuel Jáquez Leal
c8bc9c8740 htmlmediaelement: typo 2018-10-08 16:11:59 +02:00
Anthony Ramine
05ef233097 Add a couple of bug links 2018-10-08 13:13:24 +02:00
Anthony Ramine
551c405b0f Avoid ctx.getImageData in canvas.toDataURL 2018-10-08 12:19:10 +02:00
Anthony Ramine
77c28bdfc9 Abstract some stuff common to ctx.getImageData and ctx.putImageData 2018-10-08 11:39:09 +02:00
Anthony Ramine
e62dbabb46 Handle some transparent black cases in ctx.getImageData 2018-10-07 02:52:06 +02:00
Anthony Ramine
241dba064d Align ctx.createImageData and ctx.getImageData with the spec 2018-10-06 11:41:48 +02:00
Anthony Ramine
75e6f5dfaa Avoid copying pixels in ctx.putImageData sometimes 2018-10-06 02:59:25 +02:00