Граф коммитов

351 Коммитов

Автор SHA1 Сообщение Дата
Andreas Pehrson 4b3fa9c67e Bug 1493613 - Move MediaStream control from DOMMediaStream to MediaStreamTrack. r=padenot
This is inherently large, because modifying these bits of DOMMediaStream and
MediaStreamTrack affects all consumers and producers of all DOMMediaStreams and
MediaStreamTracks.

Things are generally much simpler now.

Producers of tracks now create a MediaStream in the graph, add it to a
MediaStreamTrackSource subclass that takes ownership of it, and add the source
to a MediaStreamTrack. Should the producer need a DOMMediaStream it is now much
simpler to create as the only thing needed is the current window. The stream is
a rather simple wrapper around an array of MediaStreamTracks.

HTMLMediaElement is still not as straight forward as other consumers since it
consumes the DOMMediaStream directly, as opposed to a set of tracks.
The new MediaStreamRenderer helper class helps bridge the gap between this fact
and the new track-based MediaStreamGraph interface, as it needs to juggle
registering multiple audio tracks for audio output. This hooks into existing
HTMLMediaElement logic and brings a welcome simplification to all the glue
previously needed there.

Differential Revision: https://phabricator.services.mozilla.com/D37934

--HG--
extra : moz-landing-system : lando
2019-07-31 07:58:17 +00:00
Andreas Pehrson 10202bfc64 Bug 1561254 - Support groupId in constraints. r=achronop,jib,smaug
Differential Revision: https://phabricator.services.mozilla.com/D37692

--HG--
extra : moz-landing-system : lando
2019-07-30 16:28:44 +00:00
Andreas Pehrson 5cd1576eed Bug 1540434 - Convert a bunch of rawptrs related to MediaManager to RefPtr. r=jib
When unplugging a camera in use in a video-only gUM capture, we see a crash in
GetUserMediaWindowListener::Remove when trying to use `aListener` after its last
reference was removed from an nsRefPtrHashTable at the beginning of the method.
As `aListener` was a rawptr, neither this method itself, nor its caller, kept it
alive.

Making this method take a RefPtr instead of a rawptr solves this issue.
This patch also converts other similar rawptrs for good measure.

Differential Revision: https://phabricator.services.mozilla.com/D27520

--HG--
extra : moz-landing-system : lando
2019-04-16 07:37:48 +00:00
Andreas Pehrson 45fe07077f Bug 1494675 - Remove AllocationHandle. r=padenot
The handle was used to keep separate allocations of the same source in a single
process apart. Sources no longer use sharing, so we no longer need allocations
or their handles even as a concept.

Differential Revision: https://phabricator.services.mozilla.com/D24901

--HG--
extra : moz-landing-system : lando
2019-03-27 14:10:24 +00:00
Boris Zbarsky 960ef74fa8 Bug 1535384 part 11. Remove MOZ_CAN_RUN_SCRIPT_BOUNDARY for getUserMedia callbacks. r=jib
nsIDOMGetUserMediaErrorCallback, nsIDOMGetUserMediaSuccessCallback,
and nsIGetUserMediaDevicesSuccessCallback were completely unused, so
they could just go away and all the code got simpler.

Differential Revision: https://phabricator.services.mozilla.com/D23782

--HG--
extra : moz-landing-system : lando
2019-03-19 04:36:46 +00:00
Alex Chronopoulos abfb29171d Bug 1213453 - Correlate video device group id based on device name. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D20372

--HG--
extra : moz-landing-system : lando
2019-03-08 11:52:18 +00:00
Alex Chronopoulos 6efd82fb6f Bug 1213453 - Session-unique group id. r=pehrsons
Spec in [1] mentions: "The browsing session-unique group identifier for the source of the MediaStreamTrack."

[1] https://www.w3.org/TR/mediacapture-streams/#constrainable-properties

Differential Revision: https://phabricator.services.mozilla.com/D20371

--HG--
extra : moz-landing-system : lando
2019-03-08 11:52:06 +00:00
Alex Chronopoulos da31b1b51c Bug 1213453 - Add group id in various MediaManager classes. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D20369

--HG--
extra : moz-landing-system : lando
2019-03-08 11:51:45 +00:00
Narcis Beleuzu ccb04a4f95 Backed out 5 changesets (bug 1213453) for bustages on MediaEngineDefault.cpp . CLOSED TREE
Backed out changeset 118792523194 (bug 1213453)
Backed out changeset 6208d9e15f3d (bug 1213453)
Backed out changeset ec1da6bbf1a7 (bug 1213453)
Backed out changeset f78c357f2f5f (bug 1213453)
Backed out changeset 6903f0739e83 (bug 1213453)
2019-03-08 13:34:52 +02:00
Alex Chronopoulos fae0a858fe Bug 1213453 - Correlate video device group id based on device name. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D20372

--HG--
extra : moz-landing-system : lando
2019-03-08 10:33:55 +00:00
Alex Chronopoulos 68ec14cfe5 Bug 1213453 - Session-unique group id. r=pehrsons
Spec in [1] mentions: "The browsing session-unique group identifier for the source of the MediaStreamTrack."

[1] https://www.w3.org/TR/mediacapture-streams/#constrainable-properties

Differential Revision: https://phabricator.services.mozilla.com/D20371

--HG--
extra : moz-landing-system : lando
2019-03-08 10:33:53 +00:00
Alex Chronopoulos 3a6e2e8c5e Bug 1213453 - Add group id in various MediaManager classes. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D20369

--HG--
extra : moz-landing-system : lando
2019-03-08 10:33:49 +00:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Andreas Pehrson d8bf65f800 Bug 1513973 - Make MediaEngineSource::SetTrack return void. r=jib
All subclasses are now returning NS_OK, so there's no point in keeping nsresult
as the return type.

Differential Revision: https://phabricator.services.mozilla.com/D15193

--HG--
extra : moz-landing-system : lando
2019-01-04 06:39:40 +00:00
Andreas Pehrson e72c999524 Bug 1515873 - Remove aWindowId arg from MediaManager::GetBackend. r=jib
It is unused.

Differential Revision: https://phabricator.services.mozilla.com/D15630

--HG--
extra : moz-landing-system : lando
2019-01-03 05:18:09 +00:00
James Willcox d72a96de1f Bug 1450762 - Don't prompt for device permissions on Android in MediaDevices.enumerateDevices() r=achronop
Differential Revision: https://phabricator.services.mozilla.com/D14575

--HG--
extra : moz-landing-system : lando
2019-01-02 16:44:35 +00:00
Jan-Ivar Bruaroey c8bbcb8047 Bug 1321221 - Implement getDisplayMedia() and update related wpt tests. r=pehrsons,smaug
Differential Revision: https://phabricator.services.mozilla.com/D15058

--HG--
extra : moz-landing-system : lando
2018-12-28 03:12:57 +00:00
Cosmin Sabou 03bc294fa4 Backed out changeset 0e9a610fe05f (bug 1450762) for turning bug 1481028 into permafail. 2018-12-27 01:31:50 +02:00
James Willcox 5535070e5b Bug 1450762 - Don't prompt for device permissions on Android in MediaDevices.enumerateDevices() r=achronop
Differential Revision: https://phabricator.services.mozilla.com/D14575

--HG--
extra : moz-landing-system : lando
2018-12-26 19:33:13 +00:00
Dorel Luca 12e4f91411 Backed out 5 changesets (bug 1513973) for browser-chrome failures in browser/base/content/test/webrtc/browser_devices_get_user_media_screen.js. CLOSED TREE
Backed out changeset 2ddf61b1db11 (bug 1513973)
Backed out changeset 6c839f548745 (bug 1513973)
Backed out changeset 5669b30f2265 (bug 1513973)
Backed out changeset 6781e633d62c (bug 1513973)
Backed out changeset f1892f178011 (bug 1513973)
2018-12-21 23:28:51 +02:00
Andreas Pehrson 4c26324fd2 Bug 1513973 - Make MediaEngineSource::SetTrack return void. r=jib
All subclasses are now returning NS_OK, so there's no point in keeping nsresult
as the return type.

Differential Revision: https://phabricator.services.mozilla.com/D15193

--HG--
extra : moz-landing-system : lando
2018-12-21 20:03:42 +00:00
Jan-Ivar Bruaroey 76f3de75e7 Bug 1512280 - Less verbose code in MediaManager in places. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D13986

--HG--
extra : moz-landing-system : lando
2018-12-12 20:43:23 +00:00
Jan-Ivar Bruaroey c5cf4c239c Bug 1512280 - Add out-parameter to EnumerateDevicesImpl(); clearer semantics and flattens things. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D13985

--HG--
extra : moz-landing-system : lando
2018-12-12 20:42:54 +00:00
Jan-Ivar Bruaroey 5a89bd8fda Bug 1512280 - Make LOG macros clang-format friendlier. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D13859

--HG--
extra : moz-landing-system : lando
2018-12-12 20:42:18 +00:00
Dorel Luca d1d958a798 Backed out 4 changesets (bug 1512280) for bmsvc build bustage
Backed out changeset abe934612616 (bug 1512280)
Backed out changeset 9463a1a3d790 (bug 1512280)
Backed out changeset 9a68c5f1ca0d (bug 1512280)
Backed out changeset 616721cad893 (bug 1512280)
2018-12-12 07:22:49 +02:00
Jan-Ivar Bruaroey 826b382038 Bug 1512280 - Less verbose code in MediaManager in places. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D13986

--HG--
extra : moz-landing-system : lando
2018-12-12 04:22:06 +00:00
Jan-Ivar Bruaroey 3120eb8814 Bug 1512280 - Add out-parameter to EnumerateDevicesImpl(); clearer semantics and flattens things. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D13985

--HG--
extra : moz-landing-system : lando
2018-12-12 04:00:42 +00:00
Jan-Ivar Bruaroey b43cd8e1dd Bug 1512280 - Make LOG macros clang-format friendlier. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D13859

--HG--
extra : moz-landing-system : lando
2018-12-12 02:36:51 +00:00
Jan-Ivar Bruaroey 01afd58c84 Bug 1492479 - Move MediaStreamError out of MediaManager. r=jya
Differential Revision: https://phabricator.services.mozilla.com/D13175

--HG--
extra : moz-landing-system : lando
2018-11-30 05:15:54 +00:00
Jan-Ivar Bruaroey ae9fd82ada Bug 1492479 - Simplify MediaDeviceSetRefCnt by removing one redundant pointer indirection. r=achronop
Differential Revision: https://phabricator.services.mozilla.com/D11842

--HG--
extra : moz-landing-system : lando
2018-11-30 05:15:34 +00:00
Jan-Ivar Bruaroey 8ce38b2a13 Bug 1475209 - Have MediaManager::EnumerateDevices() return a promise. r=achronop,jya
Differential Revision: https://phabricator.services.mozilla.com/D8009

--HG--
extra : moz-landing-system : lando
2018-11-30 05:14:05 +00:00
Jan-Ivar Bruaroey e3194aa305 Bug 1492479 - Have MediaManager::GetUserMedia() return a promise. r=achronop,jya
Differential Revision: https://phabricator.services.mozilla.com/D8008

--HG--
extra : moz-landing-system : lando
2018-11-30 05:13:58 +00:00
Gabriele Svelto 19e52bebd4 Bug 1510582 - Remove useless inclusions of Services.h r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D13240

--HG--
extra : moz-landing-system : lando
2018-11-28 17:25:23 +00:00
Andreas Pehrson 193fd8f3eb Bug 1423241 - Move MediaManager from a stream listener to track listeners. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D12268

--HG--
extra : moz-landing-system : lando
2018-11-23 15:00:20 +00:00
Sylvestre Ledru 804b8b8883 Bug 1204606 - Reformat of dom/media r=jya
# skip-blame

Differential Revision: https://phabricator.services.mozilla.com/D12251

--HG--
extra : moz-landing-system : lando
2018-11-19 13:25:37 +00:00
Alex Chronopoulos 662ff54a4e Bug 934425 - Create a method in MediaManager to look up a given sink id. r=jib
Implement a new method in MediaManager that enumerates audio output devices and looks up for a given sink id asynchronously.

Differential Revision: https://phabricator.services.mozilla.com/D5870

--HG--
extra : moz-landing-system : lando
2018-10-12 08:44:23 +00:00
Alex Chronopoulos 12ad318568 Bug 934425 - Add device info in MediaDevice. r=jib
MediaDevice is the core object for audio device enumeration. By adding AudioDeviceInfo every information of audio devices will be available. In this case device id will be available from the first enumeration and there is no need to enumerate multiple times to get that info.

Differential Revision: https://phabricator.services.mozilla.com/D5869

--HG--
extra : moz-landing-system : lando
2018-10-12 08:48:22 +00:00
Alex Chronopoulos 623b33566d Bug 1479841 - Use promises instead of pledges through out audio device enumeration code path. r=jib
Differential Revision: https://phabricator.services.mozilla.com/D6249

--HG--
extra : moz-landing-system : lando
2018-09-25 17:03:50 +00:00
Boris Zbarsky 6748ffcaed Bug 1478890. Stop using ToXPCOMCallback in GetUserMediaDevices. r=jib 2018-07-28 00:40:29 -04:00
Boris Zbarsky 057c310979 Bug 1478890. Stop using ToXPCOMCallback in GetUserMedia code. r=jib
We don't want to expose nsXPCWrappedJS to the web, and this code is doing that.
2018-07-28 00:40:26 -04:00
Alex Chronopoulos 300cdedf50 Bug 1152401 - Rename SourceSet to MediaDeviceSet to help readability. r=jib
MozReview-Commit-ID: KLXeicyEBFG

--HG--
extra : rebase_source : 02b70606e708d414cfeb3e38a2569c1d85c1d853
2018-07-16 11:30:46 +02:00
Alex Chronopoulos 9e8bb0c379 Bug 1152401 - Update enumerate methods of MediaManager and MediaEngine to accept audio sink type. r=jib
MozReview-Commit-ID: 1RClh9UNQck

--HG--
extra : rebase_source : 23e3f1b9e4ad42f0cff86d3903e2b0c7e5bc6a01
2018-07-16 11:30:46 +02:00
Alex Chronopoulos 367ccc1325 Bug 1152401 - Add MediaDeviceKind member in MediaDevice to differentiate sink devices. r=jib
MozReview-Commit-ID: E6SGabjpqIA

--HG--
extra : rebase_source : ec79f2f8d949334209c0346e624fa4b16c8732a5
2018-07-16 11:29:12 +02:00
Margareta Eliza Balazs 0cf58ddcab Backed out 9 changesets (bug 1152401) for android gv-junit failures org.mozilla.geckoview.test.PermissionDelegateTest.media on a CLOSED TREE
Backed out changeset 987f2e0b2cb1 (bug 1152401)
Backed out changeset e45630a7c7b1 (bug 1152401)
Backed out changeset 95661c6cd914 (bug 1152401)
Backed out changeset d68ab111809f (bug 1152401)
Backed out changeset 10b039210911 (bug 1152401)
Backed out changeset aebabaa96ad3 (bug 1152401)
Backed out changeset 93457990e40f (bug 1152401)
Backed out changeset 1630f67ac197 (bug 1152401)
Backed out changeset aef64bf5b024 (bug 1152401)
2018-07-19 13:35:58 +03:00
Alex Chronopoulos 9e3e8b757e Bug 1152401 - Rename SourceSet to MediaDeviceSet to help readability. r=jib
MozReview-Commit-ID: KLXeicyEBFG

--HG--
extra : rebase_source : 02b70606e708d414cfeb3e38a2569c1d85c1d853
2018-07-16 11:30:46 +02:00
Alex Chronopoulos 0a08cf0372 Bug 1152401 - Update enumerate methods of MediaManager and MediaEngine to accept audio sink type. r=jib
MozReview-Commit-ID: 1RClh9UNQck

--HG--
extra : rebase_source : 23e3f1b9e4ad42f0cff86d3903e2b0c7e5bc6a01
2018-07-16 11:30:46 +02:00
Alex Chronopoulos 0e13e8f104 Bug 1152401 - Add MediaDeviceKind member in MediaDevice to differentiate sink devices. r=jib
MozReview-Commit-ID: E6SGabjpqIA

--HG--
extra : rebase_source : ec79f2f8d949334209c0346e624fa4b16c8732a5
2018-07-16 11:29:12 +02:00
Dan Minor 50a3ab6cd4 Bug 1450658 - Should bring window to front when screen-sharing a window; r=pehrsons
This adds a FocusOnSelectedSource method to PCameras and uses it to focus the
selected window while window sharing. We can't just focus the window as soon as
it is shared because we have a live preview in the getUserMedia permissions
prompt which would cause the prompt to lose focus. Instead, this only focuses the
window when the sharing is not done from a chrome context.


MozReview-Commit-ID: 5jre75E3JLi

--HG--
extra : rebase_source : 5f5154fc9fc7590cc02eb25146e5bc20b2243fa3
2018-05-08 15:55:36 -04:00
Dorel Luca 8e1a0ee1c6 Backed out changeset c13ca75c9bcb (bug 1450658) for Browser-Chrome failures on browser/base/content/test/webrtc/browser_devices_get_user_media_screen.js 2018-05-23 17:07:33 +03:00
Dan Minor 40fcbf60d9 Bug 1450658 - Should bring window to front when screen-sharing a window; r=pehrsons
This adds a FocusOnSelectedSource method to PCameras and uses it to focus the
selected window while window sharing. We can't just focus the window as soon as
it is shared because we have a live preview in the getUserMedia permissions
prompt which would cause the prompt to lose focus. Instead, this only focuses the
window when the sharing is not done from a chrome context.


MozReview-Commit-ID: 5jre75E3JLi

--HG--
extra : rebase_source : 97f472f6ed1c5d6bed1af01fb7243a82b2629b03
2018-05-08 15:55:36 -04:00