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

7739 Коммитов

Автор SHA1 Сообщение Дата
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 9a907cfbfc Bug 1259788 - Add a new disabled mode for MSG tracks. r=jesup
MozReview-Commit-ID: 1dMTR4Wmcd8

--HG--
extra : rebase_source : 8c2ea262d53901a11ec5c0e5067f328461dee8f2
2016-08-15 14:19:42 +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
Andreas Pehrson ba31cb2444 Bug 1259788 - Allow MediaStreamTrack::ForwardTrackContentsTo to take an explicit TrackID. r=jesup
MozReview-Commit-ID: EqsRdVJVuWu

--HG--
extra : rebase_source : 0008e6da5a4f49acdd567c0a84e432687599453e
extra : source : 7403911293c523f9714a693b91f9cafe5f5b3234
2016-07-06 10:37:28 +02:00
Andreas Pehrson d95d7de7da Bug 1259788 - Fix MediaStreamTrack logging. r=jesup
MozReview-Commit-ID: 43Pz8VcSXQ

--HG--
extra : rebase_source : e5fc6dc4cc1e3e5a7d65a5d742100dad89317b35
2016-08-12 14:03:33 +02:00
Andreas Pehrson 7fe05b7baa Bug 1259788 - Fix AudioStreamAnalyser debug canvas drawing. r=jib
MozReview-Commit-ID: 9kRWvdfFvbS

--HG--
extra : rebase_source : 81f9d4631eab4d5f39f6eed475e5ce50a5e4992c
extra : source : f5b558833cad65d3f4be73759ee066ac39ffa4ce
2016-07-06 10:34:18 +02:00
Andreas Pehrson 9d17b1873b Bug 1259788 - Make AudioStreamAnalyser (test-only) work with dynamically added tracks. r=jib
MozReview-Commit-ID: 1mpHKMyTHy8

--HG--
extra : rebase_source : a36487983862911b71e08a8c3ecee86b371a9860
extra : source : 083af945296f4630a603481d23797dab870d6dd7
2016-07-06 10:33:30 +02:00
Andreas Pehrson 702bbad147 Bug 1259788 - Multi-track support for MediaTrackList. r=jesup
MozReview-Commit-ID: 1av5uvyCMYv

--HG--
extra : rebase_source : d60ecefbe55bf3d77521aaf3aced427e0012411a
extra : source : e108109d193b5f18e358fcb226d7700c5103d9cc
2016-08-24 10:58:04 +02:00
Andreas Pehrson 342a7b0a17 Bug 1259788 - Add test for output MediaStreamTracks when media element captures MediaStream. r=jib
MozReview-Commit-ID: CikbebBmpQp

--HG--
extra : rebase_source : ac99203c904208d29318a508b15b5b7c20928167
2016-08-22 12:01:54 +02:00
Andreas Pehrson dba71afe5e Bug 1259788 - Add video content test for captureStream of MediaElement playing a MediaStream. r=jib
MozReview-Commit-ID: F6X0E0VeqP9

--HG--
extra : rebase_source : d15ab649de706aa374112d8d7a99cb276de8343c
2016-08-18 17:37:19 +02:00
Andreas Pehrson 92ec66172a Bug 1259788 - Add audio content test for captureStream of MediaElement playing a MediaStream. r=jib
MozReview-Commit-ID: HyR1EjCsYko

--HG--
extra : rebase_source : fb17f9e7b5dfbdad73ae0ffdbb3ea3d9ea215343
extra : source : 8a120ed4120932d54d47b49c474109a2981add97
2016-08-08 18:49:30 +02:00
Andreas Pehrson 515d54094e Bug 1259788 - Create haveEvents() and friends in head.js. r=jib
When we expect multiple events of the same type (in this case "addtrack" on
MediaStream) we can use this convenience function to attach a listener and
wait for the expected number of events before removing the listener and resolving.

This also adds a function to check that there were no extra events of the same
kind after the expected N events, and a function that checks that we don't see
a certain event within a given timeout period.

MozReview-Commit-ID: 1P8MkEI0Yzm

--HG--
extra : rebase_source : a815d5834c71785359613c2fb5af3cdb14ba1a54
2016-08-22 12:01:39 +02:00
Dan Glastonbury 0e76b94eb8 Bug 1297429 - Fix video suspend intermittent failures. r=jwwang
On Linux x64 PGO try, HTMLMediaElement was reliably invoking
decoder->NotifyOwnerActivityChanged() after SetVisible(false) was
called. This caused the pending suspend to be cancelled and the test
waits for an event that never arrives.

Fixed by adding 'forced hidden' to MediaDecoder that overrides the
element visibility that comes from HTMLMediaElement.

MozReview-Commit-ID: 5aRhxxZ5cZd

--HG--
extra : rebase_source : 5a4e1c44ddd2265eab545f8fe19c4ae47cebf7bf
2016-08-25 12:10:05 +10:00
Jean-Yves Avenard cb7d929883 Bug 1244489: Do not expect currentTime to always be 0 by the time playing is fired. r=jwwang
The playing event is sent asynchronously. By the time the playing event
actually gets fired, it is possible that playback has already started.

MozReview-Commit-ID: 1iD3ZSmWtmb

--HG--
extra : rebase_source : c9ea91b5102370f3b063a05f69f7eaf805bd8eb0
2016-08-23 21:31:13 +12:00
Dan Glastonbury 0f59ea17ee Bug 1295844 - Add webm testing files to video decode suspend tests. r=gerald
Test files transcoded from gizmo.mp4 using:
ffmpeg -i gizmo.mp4 -vcodec vp9 -acodec opus gizmo.webm
ffmpeg -i gizmo.webm -vcodec copy -an gizmo-noaudio.webm

MozReview-Commit-ID: 4OB8G9NtS7A

--HG--
extra : rebase_source : e43b586371fae927d0e997064169e2e56de6b476
2016-08-17 13:04:35 +10:00
Jean-Yves Avenard 745006a3fc Bug 1297880: Have GetSeekable return an empty range if duration is not r=jwwang
yet known. r?jwwang

MozReview-Commit-ID: 4e1k42FlW1z

--HG--
extra : rebase_source : 47c94026157a278192f2388a4d92768d5454c384
2016-08-25 13:36:51 +12:00
JW Wang d13f41c2a0 Bug 1294616 - Somewhat improve the string performance by defining string literals whose length is known at compile time. r=cpearce
MozReview-Commit-ID: LAlqMDtGQN7

--HG--
extra : rebase_source : 4f2cdc9cb9ee7e4dd024d47dad329304f6ba70ae
extra : source : 6db22a524b1452fc50bf56535e7c619a8441dcfe
2016-08-15 15:41:53 +08:00
JW Wang a208d2cb40 Bug 1295073 - Remove the aRealTime parameter from the MediaDecoderStateMachine constructor. r=cpearce
MozReview-Commit-ID: BXMVAV1R3gx

--HG--
extra : rebase_source : 0749ff95de361da3c935dfe113690aa8c5e7dc2a
2016-08-15 14:54:10 +08:00
Munro Mengjue Chiang b6c7822e72 Bug 1296684 - export DeviceChangeCallback.h no matter webrtc is enabled or not; r=jib
MozReview-Commit-ID: 9xocLhe1QZw

--HG--
extra : rebase_source : cfa81f49e8b98b93c90a6ea436ee106db7a12f00
2016-08-22 18:16:28 +08:00
Chia-hung Tai 80a7e0d9a0 Bug 1292335 - Call mozCaptureStreamUntilEnded in loadedmetadata. r=pehrsons.
MozReview-Commit-ID: 5S3jR9V23Yn

--HG--
extra : rebase_source : 65fa7e3f76318d1149a9700fae96a55a9a395d31
2016-08-22 11:01:27 +08:00
James Cheng c6899c4863 Bug 1290830 - [Part2] Remove the GMP types using genral types instead. r=cpearce
MozReview-Commit-ID: 3EKwTNPddI1

--HG--
extra : rebase_source : 00f7267a76ad299b52d02b16425bb266ee58985b
2016-08-02 15:05:21 +08:00
James Cheng b74f50bca9 Bug 1290830 - [Part1] Detach the GMPDecryptorProxyCallback interface to DecryptorProxyCallback. r=cpearce
MozReview-Commit-ID: EPGf0ITakPO

--HG--
extra : rebase_source : 1186be0680789c1f9e66366e549fd5ec5b418a38
2016-08-01 17:37:18 +08:00
Sebastian Hengst 2f9e419db4 Backed out changeset 7e3e593e8141 (bug 1295352) for failing mda test test_getUserMedia_basicTabshare.html. r=backout on a CLOSED TREE 2016-08-23 20:46:13 +02:00
Andreas Pehrson e00a5345bd Bug 1295352 - Check state in MediaEngines' NotifyPull(). r=jesup
GetEndOfAppendedData() returns null and calls a NS_ERROR() if the track we're
looking for doesn't exist - to indicate an error in the caller's code.

When we end a MediaEngine track we set the state to stopped, which we can use
to guard the calls to GetEndOfAppendedData() (and appending data in general).
The locking is already in place.

MozReview-Commit-ID: DuknmBF883H

--HG--
extra : rebase_source : 6304e61a4050f0ea9c31ee01f5b42f5cb45b9bf6
2016-08-23 10:45:09 +02:00
Cykesiopka a16f7b0f6a Bug 1296316 - Convert nsNSSShutDownObject::CalledFromType to an enum class. r=mgoodwin
enum classes are in general safer than plain enums, and as such should be
preferred.

MozReview-Commit-ID: 1FK89SNhdk4

--HG--
extra : rebase_source : 764c4855026c02d8c9e33ca33637fec54ea5ca31
2016-08-20 23:00:19 +08:00
Ryan VanderMeulen 82663d8710 Merge inbound to m-c. a=merge 2016-08-23 10:05:18 -04:00
Iris Hsiao 1db439cf3b Backed out changeset d6d2cc94bb92 (bug 1295906) for M-e10s crashes on Windows 7 debug 2016-08-23 15:39:20 +08:00
Jean-Yves Avenard 551e91fa7d Bug 1195723: [flac] P15. Add metadata mochitest. r=kamidphish
MozReview-Commit-ID: vVAA2Gnls8

--HG--
extra : rebase_source : afea7fc313d6178fd44154202c5fcb94ad4ab1e3
2016-08-18 16:34:56 +10:00
Jean-Yves Avenard 4f31c80e25 Bug 1195723: [flac] P14. Add support for metadata. r=kamidphish
MozReview-Commit-ID: GDlmGcWRNsM

--HG--
extra : rebase_source : 7e5bbe7186935cc05db5fcd590aa23db6f55eabf
2016-08-18 16:06:38 +10:00
Jean-Yves Avenard 6c04460e8c Bug 1195723: [flac] P13. Add mochitest files. r=kamidphish
MozReview-Commit-ID: 34FlM9HcTDo

--HG--
extra : rebase_source : 67ecb3f56f51be797f68cb1b1799d721854b1271
2016-08-18 15:30:52 +10:00
Jean-Yves Avenard 07e2fafa73 Bug 1195723: [flac] P12. Add sniffer for streaming flac. r=kamidphish
MozReview-Commit-ID: P62v6vsXzs

--HG--
extra : rebase_source : aec72ae19890e3c21f4557c4899cf1697e7e94cc
2016-08-18 13:07:11 +10:00
Jean-Yves Avenard 72e257f20f Bug 1195723: [flac] P9. Hook up flac decoder and demuxer. r=kamidphish
MozReview-Commit-ID: 5Md6mcZkME

--HG--
extra : rebase_source : 8cee6fbc41f7de347702af4d03372a058a86d655
2016-08-17 15:45:06 +10:00
Jean-Yves Avenard ee63d6aef9 Bug 1195723: [flac] P8. Add flac MediaDecoder. r=kamidphish
MozReview-Commit-ID: BQ9fERFEFcg

--HG--
extra : rebase_source : 04d365967a1caa1104e17b78b5b7c1fa46da27ae
2016-08-17 15:42:18 +10:00
Jean-Yves Avenard 51fc514176 Bug 1195723: [flac] P7. Add flac demuxer. r=kamidphish
MozReview-Commit-ID: 5db0hAsDjji

--HG--
extra : rebase_source : 976dbcbcb46b82a7e09a38106df9ad7d2578f829
2016-08-17 15:40:14 +10:00
Jean-Yves Avenard c347ee4238 Bug 1195723: [flac] P6. Add support for raw flac metadata decoding. r=kamidphish
We also move flac related files to their own flac folder.

MozReview-Commit-ID: YnV3HNbjZe

--HG--
extra : rebase_source : 5f064723d68a877d9790f0c51c5d1579d7a9bac4
2016-08-17 15:33:50 +10:00
Jean-Yves Avenard 23f6b3cb6f Bug 1195723: [adts] P4. Add extra mimetype for adts/aac. r=kamidphish
When the content is served by Apache, a file with an .aac extension always see its Content-Type set to x-aacp.

MozReview-Commit-ID: 65NANlKNQek

--HG--
extra : rebase_source : 5f5d4bf65117f862a22698b450dedd2d5f0ef8d1
2016-08-17 15:25:02 +10:00
Randell Jesup dc0ebbd114 Bug 1297101: Reduce audio/video load from fake video/audio for android debug r=dminor
Debug is slow already, and VM emulator debug is glacial and times out a lot
2016-08-22 20:57:13 -04:00
Randell Jesup f2c343d0ec Bug 1297101: disable test_peerConnection_SetParameters on Android VM opt r=dminor 2016-08-22 20:57:11 -04:00
Thomas Wisniewski 6c4149c011 Bug 1017704 - Move DropJSObjects into the destructor in AudioBuffer.cpp. r=mccr8
--HG--
extra : rebase_source : a4c5ee7e40bf26814df7b9397b9862fb08684069
2016-08-20 20:32:52 -04:00
Randell Jesup 327ccb88b0 Bug 1297083: Don't insert audio for GetUserMedia N times if opened N times r=pehrsons 2016-08-22 10:59:00 -04:00
Jean-Yves Avenard 7e55ae1ff5 Bug 1195723: [ogg/flac] P3. Add flac support in ogg. r=kamidphish
This feature is intended to debug the flac parser only and is behind a hidden pref.
There's lots of redundant code in OggCodecState, there's need for a serious cleanup there.

MozReview-Commit-ID: 9H4efd2cfuE

--HG--
extra : rebase_source : cd5f6d16dd319391a0469b8317a18ef1d5e58331
2016-08-04 17:21:53 +10:00
Jean-Yves Avenard f27ae02841 Bug 1195723: [ogg] P2. Refactor mimetype parsing for ogg. r=kamidphish
Make it just like MP4, WebM and all the others new demuxers.
Additionally, make the ogg related preferences part of MediaPrefs.

MozReview-Commit-ID: DTedHyIMv9I

--HG--
extra : rebase_source : 8bfdf971993281454776a7c4fa644c9fc7c5ee8c
2016-08-04 17:14:28 +10:00
Jean-Yves Avenard 75d3e82740 Bug 1195723: [flac] P1. Primitive flac frame parser. r=kamidphish
Currently only handle metadata decoding.

MozReview-Commit-ID: JL4vqtY5kUS

--HG--
extra : rebase_source : 1470a92d12ccf3088d5663cd6d58cedc63922586
2016-08-04 17:09:34 +10:00
Jean-Yves Avenard 07a86a0f91 Bug 1296453: [MSE] P2. Clean up SourceBufferResource. r=gerald
The code was designed around the need for a MediaResource::Read which is
no longer possible since bug 1190238

MozReview-Commit-ID: 7s76YWg93jS

--HG--
extra : rebase_source : 3f6756193c352cf766471dd8cb1fb7646af191e6
2016-08-23 17:38:46 +12:00
Jean-Yves Avenard 8e46c367ed Bug 1296453: [MSE] P1. Fix eviction. r=gerald
The MP4 demuxer returns INT64_MAX when all data can be safely evicted
from the MediaResource.
Additionally, the MP4Demuxer will read the MediaResource using
CacheReadAt.

Eviction in the SourceBufferResource had a safeguard to ensure we would
never evict data we hadn't read yet. This was done by keeping the
position of the last data read in the mOffset member. CacheReadAt
however doesn't update mOffset.

As a result, no data was ever removed from the input buffer when using
MP4.

MozReview-Commit-ID: 2tAWzpMlOjG

--HG--
extra : rebase_source : bec585ca46e7fd0665c00bce525aaacede1b3897
2016-08-23 17:18:22 +12:00
JW Wang 144902b400 Bug 1295906 - Move |mVideoFrameContainer->ClearCurrentFrame()| out of MediaFormatReader::ReleaseResources(). r=jya
MozReview-Commit-ID: E0bm0zNoaZ7

--HG--
extra : rebase_source : bf9705ba84b99745adc91fae96495f1b13f4d5ea
2016-08-17 17:11:19 +08:00
JW Wang df3e437d3a Bug 1295893 - Add entry/exit actions to state transitions of MDSM. r=kaku
MozReview-Commit-ID: Ak17K7kEigC

--HG--
extra : rebase_source : fd1508b1ecb001ce88de45e8c6391d544bab5ca4
2016-08-12 16:06:30 +08:00
Jean-Yves Avenard e3d7cee89e Bug 1270016: P3. Only check audio format at decode time. r=kamidphish
With raw streaming flac, we can't determine the audio format at the time the codec is opened.
Additionally, when using streaming flac, we do not have a STREAMINFO block. The FFmpeg flac decoder check that extradata is null and not its size and would error due to an invalid extradata.

MozReview-Commit-ID: KZ3n8b8WUMo

--HG--
extra : rebase_source : a0dd8f517d730b1414c6461fc5c5e5b08d0d8b10
2016-08-16 16:21:18 +10:00