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

189 Коммитов

Автор SHA1 Сообщение Дата
Jeff Gilbert 5b753da289 Bug 1470325 - s/FooBinding/Foo_Binding/g - r=qdot
MozReview-Commit-ID: JtTcLL5OPF0
2018-06-26 17:05:01 -07:00
Andi-Bogdan Postelnicu 60732a90a5 Bug 1453795 - DOM/Media - Initialize member fields in classes/ structures. r=jyavenard
--HG--
extra : rebase_source : 0c785260497fadf98cf3cff8b9fcae8ea699c2c1
2018-06-15 10:25:02 +03:00
Andreas Pehrson d70fe4dd85 Bug 1458166 - Remove listeners before destroying MediaStreams. r=bryce
If listeners are still registered to a MediaStream on MediaStream::Destroy
(triggered by MediaStream::UnregisterUser below), they will catch and act
on further events from the MediaStream (such as a track ending).

This may dispatch runnables that are unnecessary since we know we are
shutting down.

If we first remove the listeners from the MediaStream we will never see
said events.

MozReview-Commit-ID: IZ1kENqL2C8

--HG--
extra : rebase_source : 6f9201827a30f119b4c116d0cb798858408aed20
2018-05-07 11:36:35 +02:00
Sebastian Hengst 0819f35e51 Backed out 4 changesets (bug 525063) on request from Andi. a=backout
Backed out changeset 516c4fb1e4b8 (bug 525063)
Backed out changeset 6ff8aaef2866 (bug 525063)
Backed out changeset bf13e4103150 (bug 525063)
Backed out changeset d7d2f08e051c (bug 525063)
2018-04-13 16:01:28 +03:00
Tristan Bourvon a3a77c0312 Bug 525063 - Initialize uninitialized class attributes in m-c. r=ehsan 2018-04-10 21:11:02 +02:00
Alex Chronopoulos 2ef6a59abe Bug 1387454 - Create a MediaStreamGraph according to the given sample rate. r=padenot
MozReview-Commit-ID: 4YP8oWIVyjy

--HG--
extra : rebase_source : 54c83c0aa122fecc9e07868405e42d31b2172516
2018-04-03 20:02:15 +03:00
Tom Ritter 3d9500b9f6 Bug 1440195 Add a random context seed for AudioContext and MediaStream r=baku
MozReview-Commit-ID: sHpVCgd8Fs

--HG--
extra : rebase_source : e1bbeab189b7a64c4ce051b74bc19a706b0fa1e8
2018-03-01 11:00:12 -06:00
Byron Campen [:bwc] 5331725296 Bug 1425621 - Part 3: Implementation for MediaStream.onremovetrack. r=pehrsons
MozReview-Commit-ID: 70Hsr4G4cp6

--HG--
extra : rebase_source : fd25ff1b39b9923f85b43dcc9d55c92d39baec65
extra : intermediate-source : f6c7d3fda2f3fcc9ecb8be6daa2f665bafa16a9c
extra : source : 574c407e80072fd2ad7827e4e22d0202bddc3cd1
2017-12-20 12:36:19 -06:00
Jean-Yves Avenard a21ef82be7 Bug 1404997 - P14. Rename members to clarify the finish meaning. r=padenot
We have different concept of "finish" between the base class and its hierarchy.
Attempt to clear the sitatuation by renaming the members and related methods.

MozReview-Commit-ID: vFsXhMK5GY

--HG--
extra : rebase_source : 65eda9257e447584161da51af7c240e31027c501
2017-12-06 19:00:22 +01:00
Andreas Pehrson 167e43c316 Bug 1208378 - Implement MediaStreamTrack's muted state and events. r=jib,smaug
MozReview-Commit-ID: 1Sp9utMnWXI

--HG--
extra : rebase_source : f2d1036ab37ed9882c0bb9aa1d7b7d68eb7799e4
2017-11-06 19:03:52 +01:00
Andreas Pehrson 368e21e1b1 Bug 1407542 - Remove back reference to consumer in MediaStreamTrack. r=jib,smaug
It doesn't matter that this is traversed by the cycle collector when the track is live and playing.
It prevents cycle collection of any number of MediaStreams that contain (thus consume) this track.

MozReview-Commit-ID: GvdLfWDTVQQ

--HG--
extra : rebase_source : 29e65d25bd7cdf03e32ff4aa736b0ff762ebf1c1
2017-10-10 20:48:58 +02:00
Andreas Pehrson 83671598ea Bug 1407542 - Implement static chrome-only MediaStream method to get number of MSG-MediaStreams. r=jib,smaug
MozReview-Commit-ID: B0nDXzMBGlJ

--HG--
extra : rebase_source : 920fe77580a82f305e2604b89816b0bb3846c0e4
2017-10-23 19:09:47 +02:00
Andreas Pehrson d918302551 Bug 1319446 - DirectMediaStreamListener, you are dead to me. r=padenot
MozReview-Commit-ID: KwztE5ogSj9

--HG--
extra : rebase_source : e8e6bb3548c5697c5db901c0310ea5067a30c895
2017-09-27 12:01:46 +02:00
Andreas Pehrson d67db3baee Bug 1296531 - Expose GraphRate through DOMMediaStream. r=jesup
MozReview-Commit-ID: 6kwuLiEgtDI

--HG--
extra : rebase_source : d20ae258718a609e4a340a0357882e6bfcb3ad5b
extra : source : 95833ca114c076cd45ae4f76c8459f851d93514d
2016-11-17 09:57:02 +01:00
Andrew McCreight 78807d8776 Bug 1391005 - Eliminate NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED. r=peterv
Replace it with NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION, because it
has been the same for a while.

MozReview-Commit-ID: 5agRGFyUry1

--HG--
extra : rebase_source : 5388c56b2f6905c6ef969150f0c5b77bf247624d
2017-08-29 16:02:48 -07:00
Matthew Gregan 2f8cc7804c Bug 1388236 - Remove B2G-only AudioChannel code from MSG. r=padenot 2017-08-10 13:00:08 +12:00
Nicholas Nethercote 90eaa02ea0 Bug 1382099 - Remove MOZ_WIDGET_GONK from dom/media/. r=gerald.
As well as the obvious #ifdefs, this allows DOMHwMediaStream to be
removed, and also the "phone-state-changed" observer.

--HG--
extra : rebase_source : 373280183e228bd4b9bd9d866959409f2444c77e
2017-07-24 10:08:55 +10:00
Paul Adenot 4029e408c3 Bug 1378067 - Label more runnables in dom/media (GraphDriver.cpp, CubebUtils.cpp, DOMMediaStream.cpp). r=jesup
MozReview-Commit-ID: EQzR1AfzvzE

--HG--
extra : rebase_source : 9950d07eb1e8e9b1d07f94c10d7c5cf0008a8141
2017-07-18 11:26:58 +02:00
Sebastian Hengst cb2227a5c7 Backed out changeset 6dc016256eba (bug 1378067) for bustage at dom/media/webaudio/WebAudioUtils.cpp:107. r=backout on a CLOSED TREE 2017-07-18 11:51:22 +02:00
Paul Adenot ac12821115 Bug 1378067 - Label more runnables in dom/media (GraphDriver.cpp, CubebUtils.cpp, DOMMediaStream.cpp). r=jesup
MozReview-Commit-ID: EQzR1AfzvzE
2017-07-18 11:26:58 +02:00
Paul Adenot 404c800005 Bug 1341555 - Consolidate use of the MSG's AbstractMainThread, and stop having AbstractMainThread on MediaStreams. r=pehrsons
MozReview-Commit-ID: 5hGDQcfpH6a

--HG--
extra : rebase_source : 41bb678f37cfcdbc9912a25f45a5ca488084aabe
2017-06-29 11:30:57 -07:00
Paul Adenot 6e485889b8 Bug 1330360 - Create new MSGs for each nsPIDOMWindow. r=jesup
MozReview-Commit-ID: 5m1MGcLmT7J

--HG--
extra : rebase_source : b9c05464bb545c047b7718a048eb7e5de3fe275d
2017-06-23 16:18:34 -07:00
Bill McCloskey f115503a0b Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-26 14:19:58 -07:00
Dan Minor 052a7764f8 Bug 1319489 - Allow DOMMediaStream constructor to accept a nullptr for aWindow; r=jesup
For testing purposes, it is useful to pass a null aWindow to the DOMMediaStream
constructor. This limits the amount of code that needs to be mocked to create
a mock media stream.

MozReview-Commit-ID: Jgm1m7N0FU4

--HG--
extra : rebase_source : 90ab0157bd0d75cb53190bf4a5d388971a6fdd1b
2017-06-21 12:51:33 -04:00
Jean-Yves Avenard 10d2da1b08 Bug 1374596: P7. Fix includes as per coding style. r=padenot
MozReview-Commit-ID: 5WfOWcOoxg0

--HG--
extra : rebase_source : 988c09623e83a0d9188d9ff5d705314e2c43e756
2017-06-20 17:56:55 +02:00
Jean-Yves Avenard b930da7f1c Bug 1374596: P3. Fix MediaStream* headers. r=padenot
MozReview-Commit-ID: 5dIPrLqxUtm

--HG--
extra : rebase_source : d672119a7805738e6f04bf0691d2f9afce509757
2017-06-20 17:32:18 +02:00
Jonathan Hao dca1a28633 Bug 1217238 - Reduce time precision when privacy.resistFingerprinting is on. r=mystor
This patch is adapted from Tor bug 1517.

To offer some protection against timing attacks by JS content pages, in this
patch we round the various time-exposing APIs (such as Date and
Event.timeStamps) to the nearest 100 ms when the pref "privacy.resistFingerprinting" is on.

MozReview-Commit-ID: eGucM9nGTn

--HG--
extra : rebase_source : 3ee600b07943f3954e9a2a9561391f2f7821bb86
2017-06-06 11:45:14 +08:00
Jan-Ivar Bruaroey aa0a07c837 Bug 1354642 - Add MakeRefPtr<> helper class. r=Ehsan
MozReview-Commit-ID: es34uMTZ00

--HG--
extra : rebase_source : 8738a70a47cceece1b56b66f741e29275c066d92
2017-04-07 15:08:42 -04:00
Jean-Yves Avenard b7844bd5c3 Bug 1319987: P9. More coding style fixes. r=gerald
MozReview-Commit-ID: DhFRqkWQZny

--HG--
extra : rebase_source : 03ed44efc83fe9cab7fc975229ac4e5746aff96b
2017-01-27 13:20:37 +01:00
Bevis Tseng 72d516ef01 Bug 1314833 - Part 2.2: Use AbstractThread::CreateDirectTaskDrainer() to Drain Direct Tasks Dispatched to MediaStreamGraph. f=rjesup,r=padenot,jwwang
MozReview-Commit-ID: 1KgE3uKu4CG

--HG--
extra : rebase_source : 2ad950afe84675fb9bc4c449e53e7c0d52270175
2016-12-07 22:00:12 -10:00
Andreas Pehrson 7256570f32 Bug 1317501 - Don't notify dom objects synchronously from MSG runnables in DOMMediaStream. r=padenot
--HG--
extra : rebase_source : 9fcd61afbecc1234c4ee80ba5197448ee838aad4
2016-12-07 08:56:14 +01:00
Andreas Pehrson d6e397323b Bug 1321235 - Let ended MediaStreamTracks be removable. r=jesup
MozReview-Commit-ID: A3V3SY4L3HL

--HG--
extra : rebase_source : d2273729e88983aa74a4b4f1c456b1a06092d160
2016-12-01 19:35:48 +01:00
Andreas Pehrson 825d513165 Bug 1301675 - Rename BasicUnstoppableTrackSource to BasicTrackSource. r=jib
They are not unstoppable any longer. We just don't forward Stop() to the real source.

MozReview-Commit-ID: FdFccMsD3eb

--HG--
extra : rebase_source : e29a1abb8f2060cb72399d61d91ca3a00128f08c
2016-09-16 15:19:28 +02:00
Andreas Pehrson bffd28794f Bug 1208316 - Punch a hole for media element captureStream to only go inactive as source ends. r=jib
MozReview-Commit-ID: 3H0m3fYMw1Y

--HG--
extra : rebase_source : 0eedf84ee9360fada6b4f4d17cb7bdf296f861e8
2016-09-15 14:18:22 +02:00
Andreas Pehrson da3ba8634d Bug 1208316 - Route notifications of ending tracks through MediaStreamTrack instead of DOMMediaStream. r=jib
MozReview-Commit-ID: KMFE5HXEOtJ

--HG--
extra : rebase_source : 279dffcdd325a5ac78f115803269a724887b6ac0
2016-09-23 17:03:13 +02:00
Andreas Pehrson d88a8a02fa Bug 1208316 - Rename MediaStreamTrack::NotifyEnded to OverrideEnded. r=jib
Better semantics for what I want to do with NotifyEnded in later patches in the bug.

MozReview-Commit-ID: 8X0BdiVncNo

--HG--
extra : rebase_source : f36f5a17f2294c6ad9b5db2593b41eb8cd8a9a15
2016-09-08 11:06:21 +02:00
Andreas Pehrson 456866fe62 Bug 1208316 - Implement MediaStream.active. r=jib, r=smaug
MozReview-Commit-ID: Fzk5vepqQ35

--HG--
extra : rebase_source : 1ddf804e4ca8604b36cf0e8b4752f638c45c9561
2016-09-08 13:44:49 +02:00
Sebastian Hengst 3c1524e5e0 Bug 1306137 - remove b2g camera code: Remove dom/camera/ and code which depends on it. r=aosmond,bkelly
MozReview-Commit-ID: 7gvZrDtmcZP

--HG--
extra : rebase_source : 31f06357fdc36566465668f55bf3fcc5402fe9e0
2016-10-04 20:16:28 +02:00
Nicholas Nethercote b71747b2ac Bug 1299727 - Rename NS_WARN_IF_FALSE as NS_WARNING_ASSERTION. r=erahm.
The new name makes the sense of the condition much clearer. E.g. compare:

  NS_WARN_IF_FALSE(!rv.Failed());

with:

  NS_WARNING_ASSERTION(!rv.Failed());

The new name also makes it clearer that it only has effect in debug builds,
because that's standard for assertions.

--HG--
extra : rebase_source : 886e57a9e433e0cb6ed635cc075b34b7ebf81853
2016-09-01 15:01:16 +10:00
Andreas Pehrson 821c28c6c3 Bug 1259788 - Use RefPtr<MediaStream> in NewRunnableMethod() in DOMMediaStream. r=jesup
MozReview-Commit-ID: F7nNCJBcWGz

--HG--
extra : rebase_source : b3e9243e60f9d1bcc51b459747d8a927ed5b4555
2016-08-18 18:24:50 +02:00
Andreas Pehrson dfb49b5ab0 Bug 1259788 - Raise "addtrack" in separate tasks. r=jesup
Turns out runnables added through
MediaStreamGraph::DispatchToMainThreadAfterStreamStateUpdate on the same
iteration are all run in the same task. Creating them in the owning dom stream
in one task solves the timing issues and lets us add them
(and raise "addtrack") in individual tasks.

MozReview-Commit-ID: 9Q3NoFrmnQs

--HG--
extra : rebase_source : aa391668ec424d2f9b1485f6218d7d1f9948abc9
2016-08-22 12:23:37 +02:00
Andreas Pehrson 091e8c0b00 Bug 1259788 - Support MediaStream sources for HTMLMediaElement.mozCaptureStream(). r=jesup
This adds support for HTMLMediaElement.mozCaptureStream() and
mozCaptureStreamUntilEnded() for a HTMLMediaElement playing a MediaStream.

This is up to spec, while capturing a HTMLMediaElement playing a file is not.
This incompatibility means we cannot mix sources for the returned MediaStream.

As such, a MediaStream returned while the HTMLMediaElement was playing a file
will only have content while the element is playing files. If the src changes
to a MediaStream, the stream will be empty.

It works the same way if a MediaStream was captured while the HTMLMediaElement
was playing another MediaStream.

This is due to TrackID management - MediaDecoder doesn't care, and creates new
tracks when you seek, so users are unable to keep track, while for MediaStream
we control everything from main thread and keep track of the TrackIDs used
previously.

This also adds a separate path from MediaElementAudioSourceNode so that we don't
forward video tracks when the returned MediaStream is only used internally for
WebAudio. We should in that case not require a DOMMediaStream but just forwarding
tracks to a TrackUnionStream should be enough, and will save us some cpu cycles.
This is however fine for now as it's simpler.

MozReview-Commit-ID: Bg8hESDISDU

--HG--
extra : rebase_source : 83885a73ec8cfc5fbe3c30a9330a52cd6b6dff12
extra : source : f1aec79078869c0a6435a1c06957c649d7a40dd9
2016-08-23 17:51:50 +02:00
Andreas Pehrson 83dcc7266e Bug 1259788 - Break out AddTrackInternal() from DOMMediaStream::CreateDOMTrack. r=jesup
Sometimes a track is added to a stream synchronously (before the stream is
exposed to script), and sometimes asynchronously (see the mediacapture-main spec
on the "addtrack" event).

In the latter case we might still need to create the MediaStreamTrack object
synchronously for tracking purposes. CaptureStream of Media element playing a
MediaStream wants this.

MozReview-Commit-ID: 7me8xzN7rwj

--HG--
extra : rebase_source : 4f129b127b855e47aad2ae9ab3981ffde057412d
2016-08-12 13:50:41 +02:00
Jan-Ivar Bruaroey 594073da3e Bug 1213517 - make getUserMedia store initial constraints on resulting tracks. r=jesup
MozReview-Commit-ID: 291CrmVmq4x

--HG--
extra : rebase_source : d29e6996ee93b01c8abe3a98a3f6d05e98bce3c5
2015-11-24 23:42:26 -05:00
Iris Hsiao 725d265c2c Backed out changeset 0fc93ec9ccd7 (bug 1213517) 2016-07-18 15:41:37 +08:00
Jan-Ivar Bruaroey e7503fa4a5 Bug 1213517 - make getUserMedia store initial constraints on resulting tracks. r=jesup
MozReview-Commit-ID: 291CrmVmq4x

--HG--
extra : rebase_source : d29e6996ee93b01c8abe3a98a3f6d05e98bce3c5
2015-11-24 23:42:26 -05:00
ctai fd36b32d94 Bug 1266646 - Move group of MediaStreamListener to a new header file. r=pehrsons
This can reduce the include header dependency. MediaStreamVideoSink will inherit from DirectMediaStreamTrackListener. But we can't use forward declaration on MediaStreamListener because the usage of nsTArray<RefPtr<MediaStreamVideoSink>>.

MozReview-Commit-ID: 328s4Kw9NvW

--HG--
extra : transplant_source : %D2%18%E3%3B%0C%D8%F04%F3%EB%EB%A0%A7%8B%B1%A9%AB%97rY
2016-06-30 15:07:48 +08:00
ctai 533acf2e59 Bug 1266646 - Rename MediaStreamDirectListener and MediaStreamTrackDirectListener to DirectMediaStreamListener and DirectMediaStreamTrackListener respectively. r=pehrsons
Rename those two function to better name alignment with AddDirectListener and AddDirectTrackListener.

MozReview-Commit-ID: 6QY08oyih1X

--HG--
extra : transplant_source : %5C%1C%23%AC%D7%0D%97%24%CB%ED%8E%D5%60/%5E%07%F2%85Z%DA
2016-04-29 11:45:25 +08:00
Andreas Pehrson e028368c0f Bug 1280445 - Remove wrapper from MediaStream. r=jesup, r=padenot
MozReview-Commit-ID: CTCFloIUXKa

--HG--
extra : rebase_source : b1c2073c638bb65c19a0f40e8d17e9a5bae15c98
extra : source : c6d854b3209e7de7d97153c0bfc492c1d5f1e6b5
2016-06-29 12:27:13 +02:00
Andreas Pehrson e1e731a6c0 Bug 1208328 - Don't block ended tracks on removal from MediaStream. r=jesup
After ending the MediaInputPort (to the playback stream) gets removed if locked
to the track specifically. Trying to remove the track at this point would try to
block it in the same MediaInputPort - but since it doesn't exist would trigger
an NS_ERROR instead.

MozReview-Commit-ID: IpRL6FAGxPp

--HG--
extra : rebase_source : 7fea1d440c8e03911861acd64323083944591f0e
extra : intermediate-source : aa209325161f45a5607982af76ef1784208690a5
extra : source : dbb4b83be583eacc401648c5c33091958c29c4c3
2016-05-31 14:55:51 +02:00