Commit Graph

1376 Commits

Author SHA1 Message Date
Cosmin Sabou
b2ba954d3b Bug 1703887 - Disable bipbop_300_215kbps.mp4.lastframe.html on mac for perma failures. r=jmaher DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D112535
2021-04-19 15:25:16 +00:00
Brendan Early
92dd73d18c Bug 1120222 - Part 2 - Add tests r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D102797
2021-04-19 15:17:27 +00:00
Andreas Pehrson
23ab8a0a95 Bug 1697521 - In MediaRecorder check for multiple tracks synchronously, per spec. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D110549
2021-04-06 09:10:04 +00:00
Andreas Pehrson
3619373e0e Bug 1697521 - Add crashtest. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D110548
2021-04-06 09:10:03 +00:00
Andreas Pehrson
b412b5715d Bug 1405083 - Fix failure paths across head.js, mediaStreamPlayback.js and pc.js. r=padenot
Prior to this patch various failure paths, e.g., runTest() from
mediaStreamPlayback.js would call SimpleTest.finish() twice.

This patch fixes this so no path will call finish only on failure (and not on
success) to make responsibilities clear. This applies to PeerConnectionTest.run
and runTestWhenReady.

runTestWhenReady will be in charge of calling finish for all paths through the
test framework. Its callers runTest and runNetworkTest will stop calling finish.

The responsibility for calling networkTestFinished is moved from
PeerConnectionTest.run to runNetworkTest since the latter calls
startNetworkAndTest which is the analogous start function. At the same time,
networkTestFinished stops calling through to finish since that is now the
responsibility of runTestWhenReady.

All users of the relevant APIs are updated to comply. In many cases related code
is modernized and cleaned up to support the new pattern and to improve
readability.

Differential Revision: https://phabricator.services.mozilla.com/D110405
2021-04-06 07:17:30 +00:00
Bryce Seager van Dyk
ca29af8bbd Bug 1696034 - Expand EME telemetry test to cover cases involving unecnrypted media. r=alwu
Expands the EME telemetry test to cover two additional cases.
1. The EME media is loaded but before playback the src is switched to unecrypted
   media. In this case, we don't expect encrypted playtime to be recorded, but
   we will still collect clearkey playtime as the element still has clearkey
   media keys attached.
2. Same as the above, but where the media keys are also cleared. In this case we
   do not expect either encrypted or clearkey time to be recorded.

Differential Revision: https://phabricator.services.mozilla.com/D110550
2021-04-05 14:32:14 +00:00
Bryce Seager van Dyk
34fc51796d Bug 1696034 - Add a browser test to verify EME related playtime telemetry is gathered. r=alwu
This changeset adds a test to verify that playtime telemetry related to EME is
gathered after playing an encrypted file. It does so by checking that the
VIDEO_ENCRYPTED_PLAY_TIME_MS and VIDEO_CLEARKEY_PLAY_TIME_MS are the same as the
VIDEO_PLAY_TIME_MS after playing an encrypted file (this may not always happen
in the wild, but should hold for test).

To support this test I've added a new eme helper file `eme_standalone.js` this
is an EME helper with no extra dependencies. This allows it to be used in normal
mochitests and browser mochitests, rather than just one or the other. It is also
not coupled with the media mochitests (and `manifest.js`) unlike our existing
EME helpers, so should be more portable.

Differential Revision: https://phabricator.services.mozilla.com/D110446
2021-04-05 14:32:13 +00:00
Butkovits Atila
63a7cc1fb3 Bug 1694645 - disable test_mediarecorder_principals.html on Android for frequent failures. r=intermittent-reviewers,jmaher
Differential Revision: https://phabricator.services.mozilla.com/D110047
2021-03-29 18:41:13 +00:00
alwu
a02d2f3656 Bug 1699249 - part2 : add test for telemetry. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D108886
2021-03-29 15:59:03 +00:00
Paul Adenot
b107dbca24 Bug 1700903 - Add a test. r=kinetik
This is the file attached to the bug, trimmed right after the first cluster:

> truncate --size=66250 ~/lost-delirious-beautiful-1-trimmed.webm

Differential Revision: https://phabricator.services.mozilla.com/D109706
2021-03-26 14:20:49 +00:00
Alexandru Michis
75057cbe4c Backed out changeset b4c24acb1025 (bug 1700717) for causing wrench bustages.
CLOSED TREE
2021-03-25 05:39:32 +02:00
Jeff Muizelaar
593097f5a2 Bug 1700717 - Build SWGL with -ffast-math. r=lsalzman
Most GLSL compilers will do the kinds of optimizations that
fast-math allows so we should take advantage of them too.

Differential Revision: https://phabricator.services.mozilla.com/D109657
2021-03-25 03:08:36 +00:00
Bryce Seager van Dyk
557d12ddf1 Bug 1699434 - Add aac audio test files for different sample rates. r=alwu
Differential Revision: https://phabricator.services.mozilla.com/D109380
2021-03-23 15:03:51 +00:00
Bryce Seager van Dyk
c5ccffda56 Bug 1699509 - Re-enalbe test_playback.html on macos + linux, but don't test ambisonics.mp4 on intermittent configs. r=alwu
Differential Revision: https://phabricator.services.mozilla.com/D108978
2021-03-18 19:24:14 +00:00
Butkovits Atila
33a35f981b Bug 1483259 - disable test_playback.html for frequent failures. r=intermittent-reviewers,jmaher
Differential Revision: https://phabricator.services.mozilla.com/D107373
2021-03-13 22:44:45 +00:00
Bryce Seager van Dyk
8d092d8ef5 Bug 1547199 - Stabilize test_cloneElementVisually_poster.html. r=pehrsons,mconley
Because the `pause` event does not ensure timing of the current frame displayed
switch the test to instead rely on the `ended` event which should provide a more
reliable timing.

Also update a comment and the title of the test to more specifically reflect its
intention.

Differential Revision: https://phabricator.services.mozilla.com/D107891
2021-03-11 18:09:24 +00:00
Andreas Pehrson
1c63f4de58 Bug 1693043 - Add crashtest. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D107489
2021-03-10 21:59:29 +00:00
Bryce Seager van Dyk
400521971e Bug 1695033 - Add test cases for vp8 container stream dimension mismatch. r=alwu
This patch
- adds several test files derived from bipbop.mp4. These files are re-encodes
  that used vp8 and opus. One reference file is added with metadata that is
  correct, and several others are added with bad metadata (it doesn't match the
  stream resolution).
- adds these files to the `gPlayTests` to ensure we can play them.

Differential Revision: https://phabricator.services.mozilla.com/D107723
2021-03-10 19:30:18 +00:00
Andreas Pehrson
43981dc4de Bug 1693045 - Fire NotSupportedError when trying to record multiple tracks of one kind. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D107090
2021-03-04 19:39:28 +00:00
Andreas Pehrson
94e34b3b73 Bug 1693045 - Add mochitest. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D107087
2021-03-04 19:39:26 +00:00
Andreas Pehrson
f2e34c1802 Bug 1673526 - Add crashtests. r=bwc
Differential Revision: https://phabricator.services.mozilla.com/D98353
2021-03-01 14:48:47 +00:00
Bryce Seager van Dyk
375ad7646f Bug 1530897 - Add fuzzed file as crashtest. r=kinetik
This file tickles some asserts due to it containing fuzzed data that leads to
our WebM parser getting extremely large timestamps.

Differential Revision: https://phabricator.services.mozilla.com/D105505
2021-02-17 21:09:48 +00:00
Lee Salzman
ba5d757a8a Bug 1692731 - Accelerate YUV 422 compositing in SWGL. r=jrmuizel
For YUV 422 video, when we are sampling UV planes at half the resolution of the
Y plane, we can interpolate from 2 samples for the UV planes as an approximation
of the 4 samples, allowing us to better pack the math into SIMD vectors and
substantially reduce the number of multiplications.

Differential Revision: https://phabricator.services.mozilla.com/D105137
2021-02-16 21:17:45 +00:00
alwu
1b37ad6843 Bug 1686696 - part4 : add test. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D102250
2021-02-11 20:19:25 +00:00
Andreas Pehrson
bae4243d8d Bug 1577198 - Don't write cluster sizes, and remove the timeslice-based keyframe interval from the vp8 encoder. r=bryce
This patch stops serializing the cluster size in the cluster header, meaning
that we can push single frames to a blob, even when they are in an open cluster.
This will decrease latency when the MediaRecorder is recording a video track.

This also lets us remove the previous hack we had in place for decreasing the
latency - namely to set a short keyframe interval when the timeslice was short.
With this removed, video quality will go up for short timeslices.

This could have an impact on which players support our encoded videos. Manual
tests show ourselves, Chrome and ffplay handling this change without issues.

Differential Revision: https://phabricator.services.mozilla.com/D95731
2021-02-11 13:39:02 +00:00
Bogdan Tara
36a86026a3 Backed out 6 changesets (bug 1686696) for 1587248.html crashtest failures CLOSED TREE
Backed out changeset 690c6a094f8a (bug 1686696)
Backed out changeset 7f9d487945c3 (bug 1686696)
Backed out changeset 40358a758624 (bug 1686696)
Backed out changeset 36c696166033 (bug 1686696)
Backed out changeset ab149e8fc0d5 (bug 1686696)
Backed out changeset 8fce79f9bd65 (bug 1686696)
2021-02-11 06:29:47 +02:00
alwu
b170f91796 Bug 1686696 - part4 : add test. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D102250
2021-02-11 03:45:30 +00:00
Andreas Pehrson
c2b572a2a9 Bug 1690976 - Add a mochitest checking that third-party ERR_DECODE messages are defaulted. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D104168
2021-02-08 13:03:39 +00:00
Bogdan Tara
647a1a6efc Backed out 2 changesets (bug 1690976) for ES lint failure in test_decode_error_crossorigin.html CLOSED TREE
Backed out changeset ed0ab9078607 (bug 1690976)
Backed out changeset c6c868eaf915 (bug 1690976)
2021-02-08 13:34:59 +02:00
Andreas Pehrson
91585a5f54 Bug 1690976 - Add a mochitest checking that third-party ERR_DECODE messages are defaulted. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D104168
2021-02-08 11:00:36 +00:00
Bogdan Tara
8b058fa239 Backed out 2 changesets (bug 1690976) for test_decode_error_crossorigin.html failures CLOSED TREE
DONTBUILD
Backed out changeset d119750e8469 (bug 1690976)
Backed out changeset ff2dd7ee09b6 (bug 1690976)
2021-02-08 11:56:23 +02:00
Andreas Pehrson
6397bda2df Bug 1690976 - Add a mochitest checking that third-party ERR_DECODE messages are defaulted. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D104168
2021-02-08 08:51:34 +00:00
Mihai Alexandru Michis
f5e5a037d6 Backed out 3 changesets (bug 1629381) for causing failures in test_eme_canvas_blocked.html
CLOSED TREE

Backed out changeset 12ee10496a34 (bug 1629381)
Backed out changeset b0eba102423a (bug 1629381)
Backed out changeset 383fec2e815c (bug 1629381)
2021-01-29 03:18:25 +02:00
Emilio Cobos Álvarez
96e56e3d39 Bug 1629381 - CanvasRenderingContext2D.drawImage shouldn't throw for e.g <video> if there's no valid surface to draw. r=sotaro
As per spec see comment.

Differential Revision: https://phabricator.services.mozilla.com/D103157
2021-01-28 22:20:05 +00:00
Butkovits Atila
b09444da06 Backed out changeset ab82c7e299f4 (bug 1629381) for causing failures on test_eme_canvas_blocked.html. 2021-01-28 07:09:15 +02:00
Emilio Cobos Álvarez
a1d23c5b4f Bug 1629381 - CanvasRenderingContext2D.drawImage shouldn't throw for e.g <video> if there's no valid surface to draw. r=sotaro
As per spec see comment.

Differential Revision: https://phabricator.services.mozilla.com/D103157
2021-01-27 23:55:11 +00:00
alwu
f924a58a6d Bug 1685399 - part13 : add test. r=padenot
As we can only snapshot a telemetry histogram in the chrome process, we have to make them measurable in the chrome process and write a chrome mochitest.

Differential Revision: https://phabricator.services.mozilla.com/D101266
2021-01-19 19:49:23 +00:00
alwu
9edb9d310f Bug 1685399 - part2 : reorgnize functions being used for determining if element is visible. r=padenot,webidl,mccr8
There are several functions related with an element's visibie state, which are confusing. So this patch is going to make them clearer and remove unnecessary function.

- `IsVisible()` : add description to mention that the visibility state is only for layout level, which doesn't represent the actual visible state.
- rename `IsHidden()` to `IsActualInvisible()` : make it represent the actual visible state of an element.
- remove `IsActive()` : current two callers of `IsActive()` only care about if the page is inactive or not, it doesn't care about if page hidden or not. So we can call the owner doc's method directly.

Differential Revision: https://phabricator.services.mozilla.com/D101107
2021-01-19 19:48:43 +00:00
Bryce Seager van Dyk
a42d59200f Bug 1673525 - Add crashtest. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D100399
2021-01-12 08:29:49 +00:00
Andreas Pehrson
08755a6c85 Bug 1601385 - Add crashtest. r=jib
Differential Revision: https://phabricator.services.mozilla.com/D100003
2021-01-12 02:10:58 +00:00
Andreas Pehrson
8815d95804 Bug 1601422 - Add crashtest. r=jib
Differential Revision: https://phabricator.services.mozilla.com/D99935
2021-01-12 09:21:42 +00:00
Andreas Pehrson
8689b6a97e Bug 1601799 - Add mochitest for disabled MediaTracks with mozCaptureStream. r=karlt
Differential Revision: https://phabricator.services.mozilla.com/D99820
2021-01-04 14:35:10 +00:00
Emilio Cobos Álvarez
3987c781d0 Bug 1635914 - Move active flag handling explicitly to BrowsingContext. r=nika
And have it mirror in the parent process more automatically.

The docShellIsActive setter in the browser-custom-element side needs to
be there rather than in the usual DidSet() calls because the
AsyncTabSwitcher code relies on getting an exact amount of notifications
as response to that specific setter. Not pretty, but...

BrowserChild no longer sets IsActive() on the docshell itself for OOP
iframes. This fixes bug 1679521. PresShell activeness is used to
throttle rAF as well, which handles OOP iframes nicely as well.

Differential Revision: https://phabricator.services.mozilla.com/D96072
2020-12-11 15:43:19 +00:00
alwu
9d7be35d14 Bug 1677880 - waiting 'timeupdate' to ensure video is still playing after resuming decoding. r=bryce
In D96896, we chose to suspend video decoding before starting video in order to avoid the race where the video decode is completed by the time it should be suspended.

However, it causes another issue which is affecting the play promise, because we would only resolve the play promise when we have enough data that is related with decoding.

Therefore, in this patch, I choose not to wait until video reaches to the end, instead to wait `timeupdate` to ensure that the video is still playing after resuming video decoding.

If we don't rely on looping to the end, then we don't need to start video from `3` second which is used to shorten the time before video reaches to the end. That gives us more time to reach the completed state (6s, the video's duration) which should prevent us hitting the race again.

Differential Revision: https://phabricator.services.mozilla.com/D97800
2020-12-10 14:58:46 +00:00
Bryce Seager van Dyk
95bee43f32 Bug 1675360 - Add test coverage for createMediaKeys in iframes. r=karlt
Provide coverage that ensures we can:
- Call navigator.requestMediaKeySystemAccess() and receive access
- Call createMediaKeys on the access object
in iframes that are same and different origin.

This should work when waiting for an iframe to fire the load event, but I also
provide a case for if we do not wait for load. It's undesirable to not wait for
the load, but we've historically worked in this case (if this was intentional is
not clear to me). So providing such a test allows for coverage of this case as
long as we want to continue supporting it. Said test will be red as of this
patch, but an immediate follow up will restore our compat with this case.

Differential Revision: https://phabricator.services.mozilla.com/D97321
2020-12-09 23:55:28 +00:00
Andreas Pehrson
321d0d9ea2 Bug 1489160 - Add crashtest. r=karlt
Differential Revision: https://phabricator.services.mozilla.com/D98315
2020-12-07 20:48:35 +00:00
alwu
3b7cdfa5d4 Bug 1634489 - part2 : add test. r=jya
Differential Revision: https://phabricator.services.mozilla.com/D98652
2020-12-04 01:53:33 +00:00
Karl Tomlinson
c9898c330c Bug 1636540 AudioBufferSourceNode with empty buffer crashtest r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D97107
2020-11-16 18:57:03 +00:00
alwu
08db5b63fe Bug 1551884 - suspend video decoding before start video in order to ensure we can always receive mozentervideosuspend event. r=bryce
As `mozentervideosuspend` would only be dispatched when we're in buffering or decoding state, we would miss the event if MDSM already entered other state. eg. completed state.

Differential Revision: https://phabricator.services.mozilla.com/D96896
2020-11-16 20:31:24 +00:00
Jean-Yves Avenard
6d2df84e41 Bug 1672072 - P8. Create decoder asynchronously. r=mattwoodrow,bryce,padenot,mjf,ipc-reviewers,mccr8
PDMFactory::CreateDecoder is changed to return a MozPromise that will contain the MediaDataDecoder once created.

This will allow to later make RemoteDecoderManager fully asynchronous and no longer require an IPC sync call to start the RDD process.

We also modify the WebrtcMediaDataDecoderCodec to never create a decoder on the main thread, which could cause deadlocks under some circumstances.

Differential Revision: https://phabricator.services.mozilla.com/D96364
2020-11-13 07:46:44 +00:00