Commit Graph

857 Commits

Author SHA1 Message Date
Randell Jesup
486d30379d Bug 1274083: don't return early from rate changes if we overflow r=jmspeex
MozReview-Commit-ID: DVSp3VpiIJw
2016-05-20 01:53:27 -04:00
Wes Kocher
9f7d2279d9 Backed out changeset e96398029a1c (bug 1181073) for failing the test it added CLOSED TREE 2016-05-19 10:17:55 -07:00
Michael Layzell
6274f21dc8 Bug 1181073 - Relax setTimeout throttling for background tabs using web audio, r=bkelly 2016-05-19 09:34:01 -04:00
Chris Peterson
353ee65255 Bug 1272513 - Part 1: Suppress -Wshadow warnings-as-errors in some directories. r=glandium 2016-05-11 00:00:01 -07:00
Paul Adenot
4616d008f9 Bug 1130010: Implement the new AudioNode.disconnect methods. r=dminor,ehsan
Initial patch by Thomas Escalon <tesc.bugzilla@gmail.com>.

MozReview-Commit-ID: KDnmKIGWYL
2015-06-05 11:17:14 +02:00
Sebastian Hengst
39bd9f8b8e Backed out changeset ac56ced6aba2 (bug 1130010) for bustage. r=backout 2016-07-18 19:45:12 +02:00
Sebastian Hengst
dc8c385089 Backed out changeset 6acd35b64dc9 (bug 1130010) 2016-07-18 19:44:37 +02:00
Paul Adenot
9e394fe9b6 Bug 1130010 - Add tests for the new {AudioParam,AudioNode}.disconnect() methods. r=dminor
Initial patch by Thomas Escalon <tesc.bugzilla@gmail.com>.

MozReview-Commit-ID: 2cptcTYuzDQ
2016-07-18 18:53:24 +02:00
Paul Adenot
c1df31800a Bug 1130010: Implement the new AudioNode.disconnect methods. r=dminor,ehsan
Initial patch by Thomas Escalon <tesc.bugzilla@gmail.com>.

MozReview-Commit-ID: KDnmKIGWYL
2015-06-05 11:17:14 +02:00
Dan Minor
de01c6c54d Bug 1263910 - Make AudioBufferAddWithScale handle unaligned buffers; r=padenot
ReverbAccumulationBuffer often produces unaligned buffers due to the way
it wraps around results. This modifies AudioBufferAddWithScale on SSE2
platforms to handle unaligned buffers by performing scalar operations
until both the input and output buffers are aligned to 16 bytes. It then
does as many vector operations as possible and switches back to scalar
operations for anything that is left over.

This could also be done within the ReverbAccumulationBuffer code but doing
it directly within the AudioNodeEngine code makes it available to other
callers in the future, at the cost of a few extra branches in the case
where everything was aligned anyway.

MozReview-Commit-ID: Ky0uIe5LMVq

--HG--
extra : rebase_source : 0c9970807262c8a13be5ad866e470d78ff6c1bb9
2016-05-10 06:37:45 -04:00
Jean-Yves Avenard
d31cb0499b Bug 1206637: P2. Replace all cached preferences with MediaPrefs ones. r=cpearce
Additionally, clean up stray and unused Preferences.h header.

MozReview-Commit-ID: IcPrD2inkDE

--HG--
extra : rebase_source : c3c6e37767627db3601090c2855a3dfa98cb4368
2016-05-10 11:02:28 +10:00
Dan Minor
b34705d0d2 Bug 1270055 - Add test for DynamicsCompressor with gain; r=karlt
MozReview-Commit-ID: 7vT7oaheZaS

--HG--
extra : rebase_source : 5885808d29139e468003b3414297494decf9ee1f
2016-05-05 09:20:52 -04:00
Alastor Wu
b5d99318b3 Bug 1235612 - Part 3: Implement the logic of audible state notification for agent owners. r=baku
MozReview-Commit-ID: 6CueLPpuXWm

--HG--
extra : rebase_source : d40603e2ecc006a7b21f8b9adeb3a244e9821a2f
2016-05-03 17:59:32 +08:00
Dan Minor
68f5130961 Bug 1270055 - Unaligned buffer used in DynamicsCompressor; r=padenot
MozReview-Commit-ID: 4xVYjCGblTV

--HG--
extra : rebase_source : 28400783fa926ebc2832529e32688033e3420e3c
2016-05-04 06:49:07 -04:00
Kyle Huey
941ab1f522 Bug 1268313: Part 7 - Move NS_NewRunnableMethod and friends to mozilla::NewRunnableMethod. r=froydnj 2016-05-05 01:45:00 -07:00
Kyle Huey
7311b10562 Bug 1268313: Part 2 - Replace some NewRunnableMethods with NS_NewNonOwningRunnableMethod. r=froydnj 2016-05-05 01:44:59 -07:00
Alastor Wu
c8fae1998b Bug 1242874 - part4 : wrap the volume/mute/suspend for notifyStartedPlaying. r=baku
MozReview-Commit-ID: 2FMfEVuODmu

--HG--
extra : rebase_source : 96e49e6e8d074a9bd5d9a7e6a60e7ec01cc88402
2016-05-03 09:52:44 +08:00
Alastor Wu
30466d68e1 Bug 1242874 - part3 : implement different suspended methods. r=baku, r=jwwang
MozReview-Commit-ID: HHYX29gbLwk

--HG--
extra : rebase_source : d774e1338c6e0cd2ce8b4329b28ad9650011a7e5
2016-05-03 09:52:38 +08:00
Alastor Wu
40bc1f6803 Bug 1242874 - part1 : create suspened types. r=baku
MozReview-Commit-ID: FUAPZAdPVse

--HG--
extra : rebase_source : c9faf34965d7e2be9b76881c95dfeff62036587f
2016-05-03 09:50:24 +08:00
Dan Minor
1eb1d5f91e Bug 1266112 - Remove unnecessary alignment checks from AudioNodeEngine.cpp; r=padenot
Assuming that Bug 1266405 fixed the underlying cause for the unaligned
buffers we were seeing, the checks in AudioBufferAddWithScale and
AudioBlockCopyWithScale shoudl no longer be necessary.


MozReview-Commit-ID: 4OQ4qQVjEP3

--HG--
extra : rebase_source : fda9b1f7604a2732c9dea4985bfd47ce9293bc0f
2016-04-29 08:35:30 -04:00
Paul Adenot
00e45c5141 Bug 1259831 - Remove the auto-suspend logic for AudioContext. r=karlt
MozReview-Commit-ID: JoSMPVfbgJb
2016-03-29 16:57:19 +02:00
Carsten "Tomcat" Book
dfff02b90d Backed out changeset fd833da413ad (bug 1268313)
--HG--
extra : rebase_source : f857127091900871034f44d89095895abe9932dc
2016-04-29 14:21:25 +02:00
Carsten "Tomcat" Book
ba3fe0975c Backed out changeset 85ce8cb0639a (bug 1268313)
--HG--
extra : rebase_source : 56d1cf41a2dc4959b67f834e07192a5c772176a8
2016-04-29 14:21:16 +02:00
Carsten "Tomcat" Book
2dc450ceba Backed out changeset a8bae4554679 (bug 1259831)
--HG--
extra : rebase_source : 18ccc0c8c21d4d42afa5e8db22921b5468117b30
2016-04-29 14:21:12 +02:00
Paul Adenot
1011bcc2a0 Bug 1259831 - Remove the auto-suspend logic for AudioContext. r=karlt
MozReview-Commit-ID: JoSMPVfbgJb
2016-03-29 16:57:19 +02:00
Nicholas Nethercote
2511b2c327 Bug 1267550 (part 2) - Rename MOZ_WARN_UNUSED_RESULT as MOZ_MUST_USE. r=froydnj.
It's an annotation that is used a lot, and should be used even more, so a
shorter name is better.

MozReview-Commit-ID: 1VS4Dney4WX

--HG--
extra : rebase_source : b26919c1b0fcb32e5339adeef5be5becae6032cf
2016-04-27 14:16:50 +10:00
Kyle Huey
48a594a09e Bug 1268313: Part 7 - Move NS_NewRunnableMethod and friends to mozilla::NewRunnableMethod. r=froydnj 2016-04-28 14:08:25 -07:00
Kyle Huey
72c9966484 Bug 1268313: Part 2 - Replace some NewRunnableMethods with NS_NewNonOwningRunnableMethod. r=froydnj 2016-04-28 14:08:24 -07:00
Carsten "Tomcat" Book
7fcba36865 Backed out changeset 1681062d82dd (bug 1242874) for timeouts in own test browser_mediaPlayback_suspended_multipleAudio.js 2016-04-28 13:59:23 +02:00
Carsten "Tomcat" Book
b4a55fdcfc Backed out changeset d09b20eeb382 (bug 1242874) 2016-04-28 13:59:04 +02:00
Carsten "Tomcat" Book
0a62793b79 Backed out changeset df13b449ffcc (bug 1242874) 2016-04-28 13:59:02 +02:00
Alastor Wu
4e7da2f687 Bug 1242874 - part4 : wrap the volume/mute/suspend for notifyStartedPlaying. r=baku
MozReview-Commit-ID: GRjxz1E0C9r

--HG--
extra : transplant_source : %88%D7%C7q%3C%8A%98%C0%84k%AF%90%F7%5D%83%CC%BEa%B1%F2
2016-04-28 00:23:48 +08:00
Alastor Wu
daaa9802c9 Bug 1242874 - part3 : implement different suspended methods. r=baku, r=jwwang
MozReview-Commit-ID: Co4avRLWGRK

--HG--
extra : transplant_source : b%17%81%60%94_%F1%C2%5D%B1%B3%D5%F3%5C%7D4p%7F%03%EB
2016-04-28 00:23:42 +08:00
Alastor Wu
14fb7102ce Bug 1242874 - part1 : create suspened types. r=baku
MozReview-Commit-ID: 1RJvbzMOCpu

--HG--
extra : transplant_source : %E8%3F%7BLD%F3%B8%98%3E%CA%A5%5C7%B7%9B%D0%BEFrr
2016-04-28 00:21:22 +08:00
Kyle Huey
7579799b01 Bug 1266595: Replace Chromium Task with Runnable. r=froydnj 2016-04-27 17:06:05 -07:00
Dan Minor
4b3726dd99 Bug 1265405 - Add test case for PeriodicWave normalization; r=padenot
MozReview-Commit-ID: B85kaip1xQT

--HG--
extra : rebase_source : 565fe160a510cad0bf1f406404e33121a0783a3c
2016-04-22 09:47:07 -04:00
Dan Minor
c86fe66751 Bug 1265405 - Use a dictionary to specify how PeriodicWave should be normalized (or not); r=padenot
MozReview-Commit-ID: IH7no48COML

--HG--
extra : rebase_source : 649afa948369812a93667929e1b9bf1cba93172a
2016-04-25 11:37:20 -04:00
Dan Minor
11d3cf6d22 Bug 1265405 - Add a dictionary to specify how PeriodicWave should be normalized (or not); r=smaug
MozReview-Commit-ID: CR5kO8MXdZv

--HG--
extra : rebase_source : 10ac8c5f18b18fdc92d8eb2013354bbbf2da0c9e
2016-04-26 06:54:38 -04:00
Dan Minor
317ceb9c8e Bug 1267579 - Add test case; r=padenot
MozReview-Commit-ID: KQQKuw7KSXg

--HG--
extra : rebase_source : a5360f568149c32b279dfdec206773acf5b943f7
2016-04-26 09:24:42 -04:00
Dan Minor
d9f8adcc4b Bug 1267579 - Unexpected result when using OscillatorNode with custom wave shape; r=padenot
This fixes some division by zero errors introduced by Bug 1222405 when the
fundamental frequency is zero.

MozReview-Commit-ID: A7qfJjJOJ3H

--HG--
extra : rebase_source : 02506b547c5f78495c449bba9f476d3f42cf7ed0
2016-04-26 09:41:54 -04:00
Paul Adenot
0d3dbc04dc Bug 996685 - Report an error in the console when a cross-origin media element is used with a Media(ElementAudio|Stream)SourceNode. r=pehrsons
MozReview-Commit-ID: 8VP7Sv8unUq
2016-04-26 17:46:31 +02:00
ctai
4e89100cf8 Bug 1266644 - Rename DOMMediaStream:: CreateXXXStream to DOMMediaStream:: CreateXXXStreamAsInput. r=jesup r=pehrsons
MozReview-Commit-ID: 4X0Q1XuENa4
2016-04-25 11:43:27 +08:00
ctai
8fcb64e480 Bug 1266644 - Rename StreamBuffer to StreamTracks. r=jesup r=pehrsons
Rename StreamBuffer to StreamTracks. We still need a place to keep the track information in every MediaStream, even the StreamBuffer::Track::mSegment is empty.

--HG--
rename : dom/media/StreamBuffer.cpp => StreamTracks.cpp
rename : dom/media/StreamBuffer.h => StreamTracks.h
2016-01-26 10:49:01 +08:00
Kyle Huey
c73656947b Bug 1265927: Move nsRunnable to mozilla::Runnable, CancelableRunnable to mozilla::CancelableRunnable. r=froydnj 2016-04-25 17:23:21 -07:00
Paul Adenot
62993a3f50 Bug 1265397 - Add a length attribute to OfflineAudioContext. r=smaug
MozReview-Commit-ID: J3TqIDI4saW
2016-04-25 11:45:59 +02:00
Paul Adenot
d6dc2d1ec6 Bug 1267096 - Check the return value of Promise::Create in AudioContext::StartRendering. r=smaug
MozReview-Commit-ID: 6w6XDDPbbiV

--HG--
extra : rebase_source : b4019e46f164af4cbe53e6437dddda4b8c1292a9
2016-04-25 11:16:08 +02:00
Jan Beich
d8d938eb8b Bug 1266772 - Unbreak FreeBSD build after bug 881587. r=dminor
MozReview-Commit-ID: 5oZ1R0vYnRm

--HG--
extra : transplant_source : %BDk%E1x%29%1E%D5%92%40%24%ACVN%CB%F0U%2A%B6_%B2
2016-04-22 15:31:09 +00:00
Dan Minor
48b7390289 Bug 1266405 - AudioBufferSourceNode::CopyFromBuffer should not borrow unaligned buffers; r=padenot
MozReview-Commit-ID: 82DZJ8BFWaq

--HG--
extra : rebase_source : 20d5a43df87cf826971bef149a1f29ee75c1c0d2
2016-04-21 10:01:19 -04:00
Dan Minor
3fde1b5f43 Bug 1265400 - Use unsigned long for AudioBuffer length and numberOfChannels; r=smaug
MozReview-Commit-ID: 47ZDDvj5QrA

--HG--
extra : rebase_source : 2c441c7d04ec84eeec526a9a93607ffcac263617
2016-04-20 12:32:17 -04:00
Dan Minor
eb586d648d Bug 1266047 - Fix crash in mozilla::AudioBufferAddWithScale_SSE r=padenot
This adds alignment checks to fallback to scalar operations if the
received buffers are not properly aligned. Bug 1266112 is the follow on
to either fix the alignment problem or add a vector path for the aligned
portion of the buffers.

MozReview-Commit-ID: 5HCXzipXlqD

--HG--
extra : rebase_source : 0dff8258c4cc0d468c18267680f053ff1a240ad5
2016-04-20 11:54:50 -04:00
JW Wang
e7a6f22684 Bug 1265629 - Remove unused MediaDecoderReader::BreakCycles(). r=kaku. 2016-04-20 14:45:19 +08:00
Paul Adenot
ec07e4a3d1 Bug 1265403 - Support chaining AudioParam automation methods. r=smaug
MozReview-Commit-ID: 7Jh5eWtfU4t
2016-04-19 14:52:27 +02:00
Dan Minor
d54abe3ef7 Bug 881587 - Use SSE2 version of AudioNodeEngine.cpp routines added in bug 815643. r=padenot
MozReview-Commit-ID: 3cfU3oTruAC

--HG--
extra : rebase_source : 527061c1b0ff8b9905f6b91f5d29f61adbdfe2d2
2016-04-14 08:57:21 -04:00
Paul Adenot
ed065c9fa9 Bug 881587 - Add SSE2 version of AudioNodeEngine.cpp routines added in bug 815643. r=tterribe
MozReview-Commit-ID: 4aTdyTQEuuj

--HG--
extra : rebase_source : 30c6be909791d4310ea98eaa02139cb8aca24ed9
2013-06-12 02:56:44 +02:00
Dan Minor
80b9a8662f Bug 877662 - Use SSE2 versions of AudioNodeEngine functions r=padenot
MozReview-Commit-ID: AJ2f5YBobPv

--HG--
extra : rebase_source : 6dcf2eda9ba92ec960ffd8aa538008c49c474dd2
2016-03-18 16:24:02 -04:00
Dan Minor
ff12a068d6 Bug 877662 - Update SSE2 versions of AudioNodeEngine functions r=padenot
This updates the original SSE2 implementations to match the current
AudioNodeEngine API and adds them to the build.

MozReview-Commit-ID: KULBD7KTr3n

--HG--
extra : rebase_source : 05adf8a26cb33a4b9d9c9d200d3ed8b1831f6995
2016-04-11 16:10:45 -04:00
Paul Adenot
1bc7b6b66f Bug 877662 - Add an SSE2 implementation of AudioNodeEngine.cpp functions. r=ehsan
MozReview-Commit-ID: GhxFwFlmqPr

--HG--
extra : rebase_source : 73c3ca69123b8ffafa010d0fe3b7205fe5f6f89b
2013-06-11 02:01:54 +02:00
Dan Minor
8c7cbbbf79 Bug 877662 - Align audio buffer allocations to 16 byte boundaries r=padenot
To be able to use SSE2 routines, we need to audio buffers to be allocated
on 16 byte boundaries.

MozReview-Commit-ID: 2mjxMWqysFd

--HG--
extra : rebase_source : 8bd7d48b767b7bcfa5874061586b9b41c26a18ae
2016-04-13 15:31:50 -04:00
Dan Minor
7bd057f84a Bug 877662 - Add AlignmentUtils.h r=padenot
MozReview-Commit-ID: E5peJVX2qFo

--HG--
extra : rebase_source : 5b54f30f4013dd03731b8332b773b7c06484d901
2016-04-12 10:51:35 -04:00
Andreas Pehrson
ee5913bb8b Bug 1208371 - Move MediaStreamTrack's label to MediaStreamTrackSource. r=jib
MozReview-Commit-ID: Aj7Cht4zxc6

--HG--
extra : rebase_source : c454a9f2b81a6a1eb574c1abee0fab64abbe5b72
2016-01-22 16:27:37 +08:00
Andreas Pehrson
f33e7b4b07 Bug 1208371 - Wait for "loadedmetadata" before setting up nodes in test_mediaElementAudioSourceNodeCrossOrigin.html. r=padenot
MozReview-Commit-ID: HruqsknDHi7

--HG--
extra : rebase_source : bf83b46e1f5f46f777490163a6a6ee34190b38bb
2016-01-05 11:17:16 +08:00
Andreas Pehrson
fc68de1ab0 Bug 1208371 - Modify WebAudio source nodes tests to wait for tracks befoure measuring nr of samples. r=padenot
Otherwise we don't get an accurate nr-of-nonzero-samples measurement as
the sources now lock on to a track (main thread) before attaching a
listener.

MozReview-Commit-ID: Jhsr6kgkdcM

--HG--
extra : rebase_source : d94804a601936f456b6bf1b5abc927e9a0bd0329
2016-01-05 10:16:28 +08:00
Andreas Pehrson
c12c63404d Bug 1208371 - Lock MediaStreamAudioSourceNode onto the first AudioStreamTrack in mInputStream at time of construction. r=mt,padenot
MozReview-Commit-ID: GLE5dVLEdEL

--HG--
extra : rebase_source : 5faf4f9a7d68728545bfcf7436fb0c234502d70d
2016-01-22 11:29:40 +08:00
Andreas Pehrson
a47ce20618 Bug 1208371 - Rename CreateOwnDOMTrack/CreateClonedDOMTrack to CreateDOMTrack/CloneDOMTrack. r=jib
MozReview-Commit-ID: DOGiwcYycJY

--HG--
extra : rebase_source : 197fc7a7c5d36200f987c38f26ab77ec8ea2d290
2016-01-05 10:16:26 +08:00
Andreas Pehrson
58ac7b5fd2 Bug 1208371 - Make remaining DOMMediaStream principal sources use MediaStreamTrack. r=mt
MozReview-Commit-ID: 1hgHp5dlBZJ

--HG--
extra : rebase_source : 30d7d5bccc663ef00a640b4f385278a336191088
2016-02-01 22:46:34 +08:00
Andreas Pehrson
5cc032f3e6 Bug 1208371 - Turn DOMMediaStream::PrincipalChangeObserver into PrincipalChangeObserver<DOMMediaStream>. r=mt
MozReview-Commit-ID: JkBUEGdavZX

--HG--
extra : rebase_source : aca48148a30fc16db6a6435c592480a61174d96b
2016-01-22 12:10:41 +08:00
Andreas Pehrson
d29c47befe Bug 1208371 - Allow MediaInputPorts mapped to a destination TrackID. r=roc
This lets us know the track's TrackID in the destination stream before
the input port has been processed.
For sanity we only allow mapping to a destination TrackID if the
destination stream does not have any TRACK_ANY input ports already
assigned to it as that can cause intermittent TrackID collisions.

MozReview-Commit-ID: ClFyQl0nYFC

--HG--
extra : rebase_source : 25fa0f34cb4fa9293a572bff03fe005c33be0195
2016-01-05 10:16:22 +08:00
Andreas Pehrson
9899305f28 Bug 1208371 - Add a MediaStreamTrackSource interface. r=roc
This lets a MediaStreamTrack communicate with its source/producer on the
main thread. It's for now used for stopping a track at the source and
retrieving some metadata, but it could also be a link between actual
sinks of a track and the source, to for instance let the source optimize
by scaling down the resolution when all sinks want lowres-video.

MozReview-Commit-ID: D4SJLr0aqhJ

--HG--
extra : rebase_source : ea511b5c86ca4836bfa980825f04617fef498261
2016-04-06 14:46:56 +02:00
Paul Adenot
352f3c7654 Bug 1241096 - Add a better memory reporting system for AudioBuffers. r=erahm
MozReview-Commit-ID: GHiauyyD3R2
2016-04-01 13:36:41 +02:00
Carsten "Tomcat" Book
18f9b34175 Backed out changeset 5d5b5862ab90 (bug 1241096) for crashtest crashes 2016-04-01 09:42:07 +02:00
Paul Adenot
2b277c167c Bug 1241096 - Add a better memory reporting system for AudioBuffers. r=erahm
MozReview-Commit-ID: GHiauyyD3R2
2016-04-01 08:27:08 +02:00
Geoff Brown
3c73a0f0ec Bug 1257948 - More Android test manifest cleanup; r=jmaher 2016-03-22 07:22:43 -06:00
Geoff Brown
29977660c0 Bug 1251013 - Update android_version annotations in test manifests - mochitest; r=jmaher 2016-03-17 10:00:48 -06:00
Ehsan Akhgari
d2a9ec7408 Bug 1257343 - Port test_bug1027864.html to mochitest-plain so that it can be turned on in e10s mode; r=mrbkap 2016-03-16 19:03:20 -04:00
Ehsan Akhgari
9588951fb9 Bug 1257341 - Port test_ScriptProcessorCollected1.html to mochitest-plain so that it can be turned on in e10s mode; r=mrbkap 2016-03-16 18:58:55 -04:00
Ehsan Akhgari
ecf86396c9 Bug 1257337 - Port test_AudioParamDevtoolsAPI.html to mochitest-plain so that it can be turned on in e10s mode; r=mrbkap 2016-03-16 18:57:18 -04:00
Ehsan Akhgari
d92ea6155c Bug 1257333 - Port test_AudioNodeDevtoolsAPI.html to mochitest-plain so that it can be turned on in e10s mode; r=mrbkap 2016-03-16 18:50:53 -04:00
Karl Tomlinson
a293753929 Back out changeset 3c6fec908401 (bug 1255618) for timeout on Android 4.3 API15+ opt
--HG--
extra : amend_source : 351bd0c4843add8a21dd3721fbde9fb32e00766b
2016-03-15 20:52:18 +13:00
Karl Tomlinson
32877f50d8 mochitest for bug 1255618 r=Ehsan
MozReview-Commit-ID: 9SImAja2jXH

--HG--
extra : rebase_source : 71f4e8c72c864867b3cf004a12a02ee29ca07b59
2016-03-14 16:58:18 +13:00
Karl Tomlinson
f531d372a2 bug 1255618 remove AudioContext from global window at unlink r=Ehsan
mDestination is cleared during unlink, which means that after that point the
window can't do much with the AudioContext, nor should need to do so.

MozReview-Commit-ID: E45aCpEfJEu

--HG--
extra : rebase_source : cafd502552b7126bcdddc2544c4c28c1b62a701f
2016-03-11 20:54:31 +13:00
Boris Zbarsky
20514713f3 Bug 1255718. Remove the unused JSContext argument of AudioBuffer::Create. r=ehsan 2016-03-11 16:43:31 -05:00
Carsten "Tomcat" Book
e070379821 merge mozilla-inbound to mozilla-central a=merge 2016-03-11 16:50:43 +01:00
Joel Maher
c2f5092ca2 Bug 1242682 - Separate dom/media into its own subsuite. r=gbrown, a=tomcat
MozReview-Commit-ID: ERgFe60aJF8
2016-03-10 11:03:52 -08:00
Wes Kocher
0c4a0e7ccb Backed out changeset 20d8879ac256 (bug 1242682) a=backout CLOSED TREE
MozReview-Commit-ID: AH8yw9fw2kD

--HG--
extra : source : 5a2e0878d6c258b36b0ee8712a2afcde6ad94c78
2016-03-04 11:41:25 -08:00
Joel Maher
4719fa3568 Bug 1242682 - Separate dom/media into its own subsuite. r=armenzg, a=Tomcat
MozReview-Commit-ID: 55QtAPlIltM
2016-02-04 13:35:06 -08:00
Dan Minor
3b0b90c4ba Bug 1158741 - Implement a version of omxSP_FFTInv_CCSToR_F32_Sfs in openmax DL's FFT that is not scaled r=padenot
The new routine actually multiplies by two for consistency with the other FFT
routines in use.

MozReview-Commit-ID: Hk2Dg3fR2cQ

--HG--
extra : rebase_source : 08bdbbd65d372a3d0eb69568313cec33ccea6af3
2016-01-25 06:38:29 -05:00
Joel Maher
8b55ee9fcd backout bug 1242682 for failures due to buildbot config issues
MozReview-Commit-ID: LsAxnbITmAq
2016-03-01 10:23:53 -08:00
Joel Maher
a9ad590555 Bug 1242682 - Separate dom/media into its own subsuite. r=armenzg, a=Tomcat
MozReview-Commit-ID: 55QtAPlIltM
2016-02-04 13:35:06 -08:00
Louis Christie
ccbdff988a Bug 1231793: Part 7 - Fixed various tests. r=jya 2016-02-17 00:28:50 +11:00
Nathan Froyd
778b4efbe3 Bug 1247395 - use UniquePtr for control messages in MediaStreamGraphImpl; r=roc 2016-01-20 16:14:33 -05:00
Paul Adenot
6190ea3fb0 Bug 1241499 - Initialize the HRTF database lazily. r=karlt
--HG--
extra : commitid : CR6URDULVd6
2016-01-21 16:15:57 +01:00
Birunthan Mohanathas
d7371d07d0 Bug 1235261 - Part 1: Rename nsAutoTArray to AutoTArray. r=froydnj 2016-02-02 17:36:30 +02:00
Phil Ringnalda
d381b4bca6 Back out 7 changesets (bug 1235261) for cpptest failures in TestTArray
CLOSED TREE

Backed out changeset d66c3f19a210 (bug 1235261)
Backed out changeset 467d945426bb (bug 1235261)
Backed out changeset 32b61df13142 (bug 1235261)
Backed out changeset c50bb8ed4196 (bug 1235261)
Backed out changeset 0ff0fa6fe81f (bug 1235261)
Backed out changeset df70e89669da (bug 1235261)
Backed out changeset 064969357fc9 (bug 1235261)
2016-01-31 10:10:57 -08:00
Birunthan Mohanathas
373593275e Bug 1235261 - Part 1: Rename nsAutoTArray to AutoTArray. r=froydnj 2016-01-31 17:12:12 +02:00
Kyle Huey
91efc5a86c Bug 1241764: Replace nsPIDOMWindow with nsPIDOMWindowInner/Outer. r=mrbkap,smaug 2016-01-30 09:05:36 -08:00
Chris Manchester
d6f59759cd Bug 1243096 - Remove ini manifests containing only support-files and move their contents to TEST_HARNESS_FILES. r=gps
--HG--
extra : commitid : FyLge9QyfDF
2016-01-27 17:46:34 -08:00
Jeff Walden
1e1850242d Bug 1079844 - Change various non-js/ files/tests/etc. to refer to detaching of ArrayBuffers rather than neutering. (DOM references to "neutering" of DOM things remain as neutering.) r=bz
--HG--
rename : dom/media/webaudio/test/audioBufferSourceNodeNeutered_worker.js => dom/media/webaudio/test/audioBufferSourceNodeDetached_worker.js
rename : dom/media/webaudio/test/test_audioBufferSourceNodeNeutered.html => dom/media/webaudio/test/test_audioBufferSourceNodeDetached.html
extra : rebase_source : acc6f8336a3ffb084a0e95865710748edd9354d9
2016-01-25 18:10:22 -08:00
Dan Minor
31ec45b291 Bug 1240054 - Only rebuild BandLimitedTables if more partials are required r=padenot
We currently rebuild the BandLimitedTables whenever we encounter a lower
fundamental frequency but it is only necessary to rebuild the tables if we
can fit more partials below the Nyquist frequency. Rebuilding the tables
unnecessarily can cause performance problems, particularly in the case where
the frequency is continually lowered.

--HG--
extra : rebase_source : e53c773d53f723d5b34270d6214a5812ec1eb7f0
2016-01-18 08:51:29 -05:00
Jean-Yves Avenard
d822675be4 Bug 1240411: P1. Clean up webaudio headers. r=cpearce
Remove redundant virtual keyword and add missing override if any.
2016-01-19 19:47:28 +11:00
Emilio Cobos Álvarez
b5364082de Bug 866513 - Non-empty MediaStreamTrack labels. r=jib 2016-01-16 13:39:00 +01:00
Chris Peterson
74f570e360 Bug 1240264 - Annotate intentional switch fallthroughs in dom/media/. r=cpearce
dom/media/MediaManager.cpp:1905:7 [-Wimplicit-fallthrough] unannotated fall-through between switch labels
dom/media/webm/WebMBufferedParser.cpp:133:7 [-Wimplicit-fallthrough] unannotated fall-through between switch labels
2016-01-14 01:42:18 -08:00
Karl Tomlinson
409ab8ea16 bug 1230406 remove invalid assertion of equality between float and int32_t r=padenot
--HG--
extra : rebase_source : 659172cf1d400c45a0ddd09345a9a1a6f193975b
2016-01-06 20:05:41 +13:00
Paul Adenot
abac115f81 Bug 1237557 - Suppress the exception if calling the callback fails when finishing a decodeAudioData operation, because there is not much we can do. r=ehsan
--HG--
extra : commitid : B4I1BhYOaBn
2016-01-07 16:58:39 +01:00
Dan Minor
12fd2984bf Bug 1105513 - Add a NEON version for AudioBlockPanStereoToStereo when aIsOnTheLeft is an array r=padenot
--HG--
extra : rebase_source : 9905b14962aec450f3b439026124d05e4b4accf3
2015-12-17 13:15:54 -05:00
Karl Tomlinson
70874c9c94 bug 1223670 make SetMozAudioChannelType() private because the type will not change after construction r=baku
--HG--
extra : rebase_source : 0ea51bcec4b7fb9833ffd120b6312a8806a0b35e
2015-12-04 01:18:11 +13:00
Karl Tomlinson
b51dbbde34 bug 1223670 throw not supported when creating a node from a stream with different channel r=baku
--HG--
extra : rebase_source : d481a95731d7b9203d7ea33db57276fd4176f3da
2015-12-10 10:51:02 -05:00
Karl Tomlinson
4c7f0b9c22 bug 1223670 replace public constructors with fallible factory methods r=baku
--HG--
extra : rebase_source : ae9bc2fbaf1fd547c7355b642b45b9ef062cff25
2015-12-10 11:25:54 -05:00
Alastor Wu
f0d62419f0 Bug 1228564 - part 2 : check audio capturing when the agent is registered/unregistered. r=baku. 2015-12-24 17:28:45 +08:00
Alastor Wu
6a38526a4d Bug 1228564 - part 1 : revert the changeset of bug 1190040. r=baku. 2015-12-24 17:17:30 +08:00
Sebastian Hengst
3c1eb47e3a Backed out changesets 961f205d340d, 14a4637e9d96 and 14a4637e9d96 (bug 1228564) for failing Android M(4) test_browserElement_inproc_AudioChannel.html. r=backout 2015-12-27 22:28:08 +01:00
Alastor Wu
7ff9329b36 Bug 1228564 - part 2 : check audio capturing when the agent is registered/unregistered. r=baku.
--HG--
extra : commitid : B7NcXGTFGrv
2015-12-24 17:28:45 +08:00
Alastor Wu
b4cb129af1 Bug 1228564 - part 1 : revert the changeset of bug 1190040. r=baku.
--HG--
extra : commitid : JZF4VU0qxpg
2015-12-24 17:17:30 +08:00
Julian Seward
7f3e3b8977 Bug 1232326 - Uninitialised value use in AudioBufferInPlaceScale. r=dminor.
--HG--
extra : rebase_source : 608cb061bb6da051dd781ff6fdbbdb5ec8e1cc6d
2015-12-16 17:36:21 +01:00
Bogdan Postelnicu
76c1720d24 Bug 1232646 - initialize 3 variables: mCurve, mTimeConstant, mDuration. r=cpearce
--HG--
extra : rebase_source : 3a0899948c5bddfab76af0de03e85484156f416b
2015-12-15 05:21:00 +01:00
Bogdan Postelnicu
ac6c0718c7 Bug 1231124 - addded mCurve to constructor. r=smaug 2015-12-09 00:00:00 +01:00
Boris Zbarsky
602de001f4 Bug 1230692. Fix WebAudioDecodeJob to properly suppress exceptions from its callbacks. r=ehsan 2015-12-07 18:42:11 -05:00
Chris Peterson
46bb7c80dd Bug 1228947 - Replace mfbt/Constants.h with math.h. r=roc
--HG--
extra : rebase_source : 4ab2c4a917ea90055e48bd6adcb53904f2266ee0
2015-11-27 20:49:55 -08:00
Nathan Froyd
ffeb7c7fe3 Bug 1229963 - use UniquePtr<T[]> instead of nsAutoArrayPtr<T> in dom/media/; r=cpearce 2015-12-02 18:07:59 -05:00
Dan Minor
57ace7e27d Bug 1222405 - (part 3) Build band limited tables lazily r=padenot
This builds the band limited tables for each range index individually as
required.

--HG--
extra : rebase_source : 022665e3b83b82bcdcec3cabf3ddda9c2dce2ebf
2015-11-27 15:01:28 -05:00
Dan Minor
5c9b087388 Bug 1222405 - (part 2) Build band limited tables after fundamental frequency is known r=padenot
If we build the band limited tables after the fundamental frequency is known,
we can exclude partials that are above the nyquist frequency for the sampling
frequency being used.

We rebuild the band limited tables each time we see a request for data for a
lower fundamental frequency so we have the required partials.

--HG--
extra : rebase_source : 067075c7c8a90580650bf850c50ca7d8fc1eb6ff
2015-11-13 11:17:39 -05:00
Dan Minor
eec8d40aad Bug 1222405 - (part 1) Store PeriodicWave components for later use r=padenot
We need to store the components used to create the PeriodicWave for later use
if we want to be able to build the band limited tables lazily.

--HG--
extra : rebase_source : d760433e6fe5490a60da761be7e2148a6504d20d
2015-11-12 10:40:45 -05:00
Nathan Froyd
c381a6b86c Bug 1218454 - part 2 - don't #include nsContentUtils.h from CallbackObject.h; r=bz
We used to need nsContentUtils.h here for nsCxPusher, but since that got
moved to ScriptSettings.h, we no longer need nsContentUtils.h for
anything.
2015-10-26 12:14:47 -04:00
Lars T Hansen
b62493634b Bug 1176214 - Part 11: Changes to DOM, except for WebGL. r=bz, r=clb
--HG--
extra : rebase_source : 9c9d3f493822d68be20597d9974292ed5ec4ab70
2015-11-25 19:04:50 +01:00
JW Wang
e4cbe0c128 Bug 1228939 - 1. add mSeekable to MediaInfo. 2. use MediaEventSource to notify the decoder when the media is not seekable. 3. remove unused code. r=jya. 2015-12-02 15:42:32 +08:00
Nicholas Nethercote
ddc78c3b0c Bug 1229458 - Remove SizeOfIncludingThisMustBeUnshared() from string classes. r=mccr8.
The patch changes all uses of SizeOfIncludingThisMustBeUnshared() to
SizeOfIncludingThisIfUnshared(). This incurs the (tiny) cost of an unnecessary
IsReadonly() check for guaranteed-unshared strings, but avoids the possible
assertion failures that would occur when MustBeUnshared() was used incorrectly
on shared strings, which is an easy mistake to make.

--HG--
extra : rebase_source : b1e91f1c19bcbe0521b0ce461d6c90512ca938ef
2015-12-01 15:36:26 -08:00
Karl Tomlinson
b0b63d25cd bug 1227411 add logging of AudioParam API use r=padenot
--HG--
extra : rebase_source : 5399d15dc0e81c5745c2952e39d3d74ba6ce08c4
2015-11-24 18:08:13 +13:00
Karl Tomlinson
3e2ffb81fd bug 1227411 add some initial logging of AudioNode API use r=padenot
--HG--
extra : rebase_source : 9ffb6c3da3468b305d31f7d907a674671674611f
2015-11-24 15:55:10 +13:00
Karl Tomlinson
c95ab76c6c bug 1227411 add WEB_AUDIO_API_LOG r=padenot
--HG--
extra : rebase_source : c27e117a0a6af5fe8913dabb656842281643ecc4
2015-11-24 12:48:17 +13:00
Chris Pearce
cea22429d5 Bug 1226450 - Report audio/video codecs used in HTMLMediaElement and WebAudio via telemetry. r=jya 2015-11-25 12:52:48 +13:00
JW Wang
328ebd72a1 Bug 1226569. Part 1 - Use MediaEventSource to publish MetadataLoaded and FirstFrameLoaded events. r=jya. 2015-11-23 10:35:18 +08:00
JW Wang
b194bb0f80 Bug 1219163. Part 2 - Move some functions that are never called from the interface of AbstractMediaDecoder down the class hierarchy. r=jya. 2015-11-23 10:26:49 +08:00
JW Wang
a7be18a6e3 Bug 1219163. Part 1 - Remove unused functions from AbstractMediaDecoder. r=jya. 2015-11-23 10:19:04 +08:00
Karl Tomlinson
b859c7f93d bug 1222202 implement query interface to nsIMemoryReporter r=bz
--HG--
extra : rebase_source : 5920d3df2b4629bc379959011a5d2a971776311d
2015-11-16 13:08:21 +13:00
Karl Tomlinson
50201f89c3 bug 1225003 test no crashes in decodeAudioData() and offline context memory reporting r=erahm
--HG--
extra : rebase_source : d7c0389512088d5b308a7f0ad9f667e36aaad3f2
2015-11-18 10:52:35 +13:00
Karl Tomlinson
dbdd106a64 bug 1225003 null-check mBuffer in SizeOfExcludingThis() r=padenot
--HG--
extra : rebase_source : b8b63f861e2d58d4b45a4d4ec3d7c187afc882b6
2015-11-17 08:58:48 +13:00
Karl Tomlinson
bc68ee1302 bug 1223520 avoid leaking NaNs to and from the otherwise unused imaginary frequency components r=padenot
The zeroth component is not removed from the BufferComplexMultiply() call so
as not to disrupt alignment.

The mOutputBuffer[halfSize].i assertions are removed because the code no
longer uses these components, and so their values are irrelevant.

--HG--
extra : rebase_source : 96014bdb66a86e1d764979f7b1a313c24196a60b
extra : histedit_source : 59ef41301d48a7f80798d8dbecc43aa85703c26f
2015-11-11 20:34:41 +13:00
Karl Tomlinson
9c3d0ed0df test for bug 1223520 r=padenot
--HG--
extra : rebase_source : 126c624ab62c82bddb45141ea2f8f7e7446f521e
extra : histedit_source : 4b2ba424644f0ab5493de4978ca9170b5ece4be1
2015-11-12 12:16:32 +13:00
Karl Tomlinson
f9ed76a4de bug 1224102 reduce the size of the final FFT convolution stage if possible r=padenot
--HG--
extra : rebase_source : 18d699f2710d9094811e0d734bcb1cf085c147c6
extra : histedit_source : 0393d5f2d3251aae45f07473e103c026921054bc
2015-11-12 17:34:13 +13:00
JW Wang
8dedbfa33d Bug 1223599 - Remove the throttling argument from AbstractMediaDecoder::NotifyDataArrived(). r=jya. 2015-11-11 17:59:16 +08:00
Dan Minor
229f2b76cc Bug 1171436 - support at least 8192 elements for PeriodicWave r=padenot
This increases the maximum PeriodicWave size to 8192 and adds an optimization
to use 8192 elements only in the case where we receive more than 4096
components. In accordance with the spec, a maximum number of components is no
longer enforced.

--HG--
extra : rebase_source : ecb9a401fabdb14f23f690c44944ece434599055
2015-10-27 22:05:47 -04:00
JW Wang
4f2d0e76bc Bug 1220558. Part 1 - remove unused arguments from MediaDecoderReader::DispatchNotifyDataArrived() and its callees/callers. r=jya. 2015-11-11 07:43:38 +08:00
Carsten "Tomcat" Book
4d6f05d2f8 merge mozilla-inbound to mozilla-central a=merge 2015-11-09 14:55:30 +01:00
Gregor Wagner
96837db759 Bug 1222478 - Enable more mulet tests. r=gerard-majax 2015-11-06 20:01:45 +01:00
Karl Tomlinson
de1e2244a1 bug 1221836 return output pointer from FFTConvolver::process() to save a buffer copy r=padenot
--HG--
extra : rebase_source : 99568b7c3095f44a061f783cefd5d6cbeebfa496
2015-11-04 21:23:18 +13:00
Karl Tomlinson
754b0bf4f3 bug 1221833 remove now-unused direct convolver r=padenot
--HG--
extra : rebase_source : 648461a4d49b58d72eb18826b4cd43f62230852b
2015-11-04 09:21:45 +13:00
Karl Tomlinson
9211c999d3 bug 1221833 remove first two half-block-size convolver stages r=padenot
Efficiency is proportional to stage size, so start with the largest size
possible.

--HG--
extra : rebase_source : 34915efce1eb94e18f53adf35dc939301242467a
2015-11-04 09:02:57 +13:00
Karl Tomlinson
3bc589b269 bug 1221833 replace initial direct convolution stage with fft r=padenot
--HG--
extra : rebase_source : 2cc20db26a95b56683d24853622fbe3cac016b45
2015-11-04 08:40:12 +13:00
Karl Tomlinson
02e971d1d8 bug 1221833 reduce FFTConvolver latency by one block r=padenot
--HG--
extra : rebase_source : 1bf6b117a8d50717c04bb6f149bd16e2fc86976a
2015-11-04 06:32:49 +13:00
Karl Tomlinson
3a15f3bba0 bug 1221830 double maximum realtime convolver stage size to 2048 r=padenot
Now, the most FFT work that happens during one realtime processing block is
when one 2048-size stage and the 256-size stage are performed at the same
phase-offset.  Before FFT timing was controlled by initial input buffer offset
(bug 1221831), two 1024-size stages as well as the 512- and 256-size stages
performed FFTs at one offset.  Thus, the maximum work in one block is reduced
by a ratio of about 11 to 9.

Measurements also indicate a similar reduction in total rendering thread
CPU usage.

Previously the alignment of the eleven 1024-size realtime stages was such
that, in three consecutive blocks, two 1024-size stages would peform their
FFTs.  Now, the 2048-size stages is aligned so that none of these perform
their FFTs in consecutive blocks.

--HG--
extra : rebase_source : 7265374c1642661db1d4f4d630ddc8294be689c7
2015-11-04 11:46:21 +13:00
Karl Tomlinson
fe5dd59db9 bug 1221830 use WEBAUDIO_BLOCK_SIZE constant in FFTConvolver r=padenot
--HG--
extra : rebase_source : 08b570d5f6f2f3d121706867935253c9d898dd55
2015-11-04 07:39:41 +13:00
Karl Tomlinson
8f7fd34a0b bug 1221830 use WEBAUDIO_BLOCK_SIZE slice size for background convolver thread r=padenot
as with the main thread.

The comment was incomplete as ReverbConvolverStage also supports multiples of
the FFT halfsize, but only values up to WEBAUDIO_BLOCK_SIZE.

--HG--
extra : rebase_source : 34f11834dd425075e8948f47dcc5283dcb50fc42
2015-11-03 16:36:53 +13:00
Karl Tomlinson
0c21da20ee bug 1221830 use WEBAUDIO_BLOCK_SIZE constant in Reverb methods r=padenot
--HG--
extra : rebase_source : b7e18f2aa4abf271f45428efac16ee1e703a6652
2015-11-03 16:35:32 +13:00
Karl Tomlinson
0336bb8152 bug 1221831 remove now-unnecessary m_preDelayBuffer r=padenot
--HG--
extra : rebase_source : 77283553705714838d3a3275c57a9cad32d27e7c
2015-11-03 14:14:40 +13:00
Karl Tomlinson
5d90fce0de bug 1221831 use initial input buffer offset to control when convolver stages perform their FFT r=padenot
--HG--
extra : rebase_source : 76c468519435033b4f9a726c6d5ca2e6b44dade9
2015-11-03 12:28:14 +13:00
Karl Tomlinson
90f122ced0 bug 1221831 remove unused Reverb::latencyFrames() r=padenot
--HG--
extra : rebase_source : c5acf681fe724a9258a2fc106d2f8c0b9056c6d3
2015-11-03 13:56:35 +13:00
Karl Tomlinson
eb5e6e879d bug 1221831 remove unused Reverb::reset() r=padenot
--HG--
extra : rebase_source : 2a1f6ef489ca1f00d4f7a7ccdd7fa132c67543d0
2015-11-03 13:53:27 +13:00
Paul Adenot
ff0b8109b3 Bug 1219403 - r=karlt
--HG--
extra : rebase_source : 90488330acc388d8f04ac5a5cd3d330c9768d5a7
2015-11-05 09:36:25 +01:00
Dan Minor
4d8b873ab9 Bug 1214239 - [Web Audio] StereoPannerNode ignores input gain when pan is 0 r=padenot
This modifies the special case code for pan == 0.0f to apply the input gain.

--HG--
extra : commitid : LAEwrqMnjQi
extra : rebase_source : 735cabd0f9bc7a857a8382c712329e8353b88ad0
2015-10-21 11:59:58 -04:00
Karl Tomlinson
bcb7e273a6 bug 1220041 scale when copying for inverse FFT to avoid iterating twice r=padenot
--HG--
extra : rebase_source : ed8826cac68bc28c5b019547a7da5451a87a2c29
2015-10-30 15:24:23 +13:00
Karl Tomlinson
a8b0ab9f02 bug 1220041 remove unnecessary temp buffer and copy with libav FFT r=padenot
--HG--
extra : rebase_source : c69808b42f0d5463d5642176755e4562e07ae8b5
2015-10-30 15:18:33 +13:00
Karl Tomlinson
0aa21f1517 bug 1220037 test convolution r=padenot
This is in the mochitest suite so that Android and B2G tests can run it, but
designed so that it can be moved to web-platform-tests when they run on all
platforms.

--HG--
extra : rebase_source : 775f1d9e4122d52cd58c0d6893681d31268cb715
2015-10-30 15:32:16 +13:00
Karl Tomlinson
f5856e8397 bug 1220037 pack and unpack Nyquist for MOZ_LIBAV_FFT r=padenot
BufferComplexMultiply knows nothing about this format and so ends up
corrupting the DC coefficient if packed Nyquists are multiplied.

--HG--
extra : rebase_source : feccac4be8d278dc0be020185065a1a9fa596d9c
2015-10-30 14:48:08 +13:00
Karl Tomlinson
68c055849f bug 1094925 adopt spec changes for one channel per input ChannelMerger behavior r=padenot
https://github.com/WebAudio/web-audio-api/issues/304

NotSupportedError is chosen for more sensible meaning and consistency with
other nodes.

--HG--
extra : rebase_source : a5b8b8af0aeb3751d299b5fe785afb9a99fe5dea
2015-10-30 10:22:45 +13:00
Karl Tomlinson
8a5e7c46c2 bug 930257 schedule Analyser inactive check when sending last null chunk r=padenot
(Doing the extra ProcessBlock for the sake of downstream nodes was unnecessary
 even before the inactive check was delayed until after their processing, because
 downstream nodes would have only had null chunks to process anyway.)

--HG--
extra : rebase_source : d1dd8a228a23520a23e77e29ae3d5040e6505eb8
2015-10-23 08:47:34 +13:00
Karl Tomlinson
d56d2e6f1c bug 930257 finish Oscillator on processing last non-null block r=padenot
--HG--
extra : rebase_source : 4032a336958a52f436d0f926d76ff8e6e1fd1b68
2015-10-23 09:23:52 +13:00
Karl Tomlinson
dc70c3e748 bug 930257 finish BufferSource on processing last non-null block r=padenot
Since changes for bug 1217625, the node and downstream nodes won't be made
inactive until after downstream nodes have done their processing, and so there
is no need to wait for the first silent output block.

This essentially reverts 5c607f3f39d55544838f3111ede9e11a00d3c25e.

--HG--
extra : rebase_source : f449c427b580239f9072cc7c580585f10b69608f
2015-10-23 08:55:57 +13:00
Karl Tomlinson
e2c3511d96 bug 1217625 suspend inactive AudioNodeStreams r=padenot
--HG--
extra : rebase_source : c005e06d4fb233f7b68d192be6dd154450f01428
2015-10-23 11:38:11 +13:00
Karl Tomlinson
3c93b81fd5 bug 1217625 remove ADD_STREAM_SUSPENDED r=padenot
Sometimes we'll need an initial suspended count of 2, which is not supported
by this API, but this is not necessary anyway.

--HG--
extra : rebase_source : 56ecca7c14025ea7e18ba9a20e0b7725a610b429
2015-10-22 22:14:46 +13:00
Karl Tomlinson
e6e2a0f9e8 bug 1217625 perform checks for transition to inactive outside of stream processing r=padenot
This will allow streams to be suspended when they are discovered inactive.
Suspending is not possible while iterating over stream lists for processing.

The approach of delaying the transition to inactive state may result in a
couple of extra processing iterations, but can save on the number of messages
that need to be created when compared to the approach of traversing downstream
nodes during stream processing.

--HG--
extra : rebase_source : b6707da5afa9323058b3f70b7743c13380618dad
2015-10-23 09:37:45 +13:00
Karl Tomlinson
dd0c6e4731 bug 1221855 test Web Audio memory reporting r=erahm
--HG--
extra : rebase_source : 12c4a94a47b75fa9aaf03d3f6a13b5c0bb19fb86
2015-11-06 16:16:39 +13:00
Karl Tomlinson
5620614cf8 bug 1221855 null-check mInputBuffer in SizeOfExcludingThis() r=padenot
--HG--
extra : rebase_source : bd3574578981a8dad9263aedf38a4331364e4d57
2015-11-06 15:00:17 +13:00
Birunthan Mohanathas
9985829ecc Bug 1219392 - Capitalize mozilla::unused to avoid conflicts. r=froydnj 2015-11-02 07:53:26 +02:00
JW Wang
89a23d426c Bug 1219169. Part 1 - Remove AbstractMediaDecoder::OnStateMachineTaskQueue(). r=jya. 2015-11-02 10:36:48 +08:00
Karl Tomlinson
6f17ae280f bug 1187785 bind frequencyIndex by value instead of reference
to test all indices, not the last one several times.

--HG--
extra : rebase_source : 8176094474ddfefcc4e021f772a211577b5ec3f8
2015-10-30 10:07:14 +13:00
Karl Tomlinson
08b9621b96 bug 1220042 make AlignedTArray base class inheritance private r=jwwang
because base class methods will not be safe with different Elements() and
Length() methods.

--HG--
extra : rebase_source : 7616f0eb12e1d8098620682f6eb9b4c5f40f873f
2015-10-29 22:58:10 +13:00
Paul Adenot
b42848e60e Bug 1218694 - Return the AudioNode connected to when calling AudioNode.connect(). r=smaug
--HG--
extra : rebase_source : c5a58a51f1f43aad2fe64d872009dee88c564503
2015-10-28 13:54:35 +09:00
Dan Minor
b08af755c4 Bug 1214545 - Update getFrequencyResponse to have NaN at index with invalid frequencies r=padenot
--HG--
extra : commitid : KEtSH8KHUDX
extra : rebase_source : fbcf1714a66629b473a693c548f2e6eebef22ee6
2015-10-20 23:36:45 -04:00
Julian Seward
8bd076f172 Bug 1216081 - OscillatorNodeEngine::mFinalFrequency is used uninitialised. r=padenot. 2015-10-20 12:59:37 +02:00
Karl Tomlinson
5db355303c bug 1020370 use int64_t to avoid overflow in subsample calcs r=padenot
ratioDen can be large when playbackRate is low.

Subsample skipping is limited to uint32_t values supported by speex resampler.

--HG--
extra : rebase_source : 26a14f212b5fd3fdd62820f458db3a7cf3673e93
extra : histedit_source : 733829a4b2ba6aab7c651f362dbc47553f9dfc59
2015-10-16 11:56:24 +13:00
Karl Tomlinson
c31207d4a3 bug 1020370 adjust assert to tolerate large skipFracNum r=padenot
--HG--
extra : rebase_source : 35b6077976ccdc4c2b9d9fd4c778c6362fdd1daa
extra : histedit_source : 7adb8e3296924a1c8ffcb4665122c40ee48f42a4
2015-10-16 11:31:45 +13:00
Karl Tomlinson
28235c90c6 mochitest for bug 913854 r=padenot
--HG--
extra : rebase_source : 8b8e282f34cda23ba924ef4f7201d59b94a7c7af
2015-10-16 01:52:37 +13:00
Karl Tomlinson
fef64ad5d0 bug 1215096 correct off-by-one error in playback position of resampled buffers r=padenot
"The behavior of an expression of the form E1 op = E2 is equivalent to E1 = E1
op E2 except that E1 is evaluated only once", which means that the subtraction
of -= was happening before conversion from double to unsigned int.

The "+ 0.5" was subtracted before the truncation toward zero, causing rounding
to nearest minus one, except when nearest was zero.

--HG--
extra : rebase_source : 3b2335da7a244245ea2fcf5c80760dc1645e6dae
2015-10-16 01:40:07 +13:00
Karl Tomlinson
145e364521 bug 1214493 restore fractional start time accidentally rounded in 13e85dc6b41b r=padenot
--HG--
extra : rebase_source : 524269e54597bffcdeafc96940cbe14b8850c6a7
2015-10-15 18:56:56 +13:00
Nathan Froyd
01583602a9 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi

--HG--
rename : mfbt/nsRefPtr.h => mfbt/RefPtr.h
2015-10-18 01:24:48 -04:00
Nathan Froyd
583afa0965 Bug 1207245 - part 3 - switch all uses of mozilla::RefPtr<T> to nsRefPtr<T>; r=ehsan
This commit was generated using the following script, executed at the
top level of a typical source code checkout.

 # Don't modify select files in mfbt/ because it's not worth trying to
 # tease out the dependencies currently.
 #
 # Don't modify anything in media/gmp-clearkey/0.1/ because those files
 # use their own RefPtr, defined in their own RefCounted.h.
find . -name '*.cpp' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    grep -v 'mfbt/RefPtr.h' | \
    grep -v 'mfbt/nsRefPtr.h' | \
    grep -v 'mfbt/RefCounted.h' | \
    grep -v 'media/gmp-clearkey/0.1/' | \
    xargs perl -p -i -e '
 s/mozilla::RefPtr/nsRefPtr/g; # handle declarations in headers
 s/\bRefPtr</nsRefPtr</g; # handle local variables in functions
 s#mozilla/RefPtr.h#mozilla/nsRefPtr.h#; # handle #includes
 s#mfbt/RefPtr.h#mfbt/nsRefPtr.h#;       # handle strange #includes
'

 # |using mozilla::RefPtr;| is OK; |using nsRefPtr;| is invalid syntax.
find . -name '*.cpp' -o -name '*.mm' | xargs sed -i -e '/using nsRefPtr/d'

 # RefPtr.h used |byRef| for dealing with COM-style outparams.
 # nsRefPtr.h uses |getter_AddRefs|.
 # Fixup that mismatch.
find . -name '*.cpp' -o -name '*.h'| \
    xargs perl -p -i -e 's/byRef/getter_AddRefs/g'
2015-10-18 00:40:10 -04:00
JW Wang
d3c9b0b0df Bug 1212723. Part 2 - remove unused argument aCloneDonor from MediaDecoderReader::Init(). r=jya. 2015-10-13 15:28:57 +08:00
Baptiste Emmanuel
e080509fbe Bug 1069825 - Check if we compare two automation curves occuring at the same time during overlap checking. r=padenot 2015-06-01 20:01:48 +02:00
Baptiste Emmanuel
440512963b Bug 1110344 - Replace float by double in AudioTimelineEvent ctor to prevent a rounding issue. r=padenot
--HG--
extra : rebase_source : 5814a4bc4eec9cb0b80d3de49c09b9bb060aa01f
2015-06-03 11:58:30 +02:00
JW Wang
a072559a2a Bug 1212701. Part 1 - remove AbstractMediaDecoder::OnDecodeTaskQueue(). r=jya. 2015-10-12 12:05:49 +08:00
Karl Tomlinson
2c37fa9568 bug 1210267 remove custom AudioParam::Release and disconnect in destructor r=baku
AudioParam has no derived type (and DisconnectFromGraphAndDestroyStream calls
no virtual functions) so no need for special release.

--HG--
extra : rebase_source : 1192d8e02d9545a310f175378468c856ef8f5f99
2015-10-02 14:24:51 +13:00
Karl Tomlinson
fcc5b0442a bug 1210267 use DOMEventTargetHelper::LastRelease instead of custom Release r=baku
AudioNode already has NS_IMPL_CYCLE_COLLECTING_RELEASE_WITH_LAST_RELEASE,
which performs mRefCnt.incr/decr for LastRelease(), so the kungFuDeathGrip
virtual AddRef/Release in DisconnectFromGraph() is additional noise when
debugging/tracing ownership.

Unlink() already assumes that the caller holds a reference (and it does).

--HG--
extra : rebase_source : 2ecfb16a89524588979365cfe3078df91724dad3
2015-10-01 00:14:26 +13:00
Paul Adenot
6c0eec35f6 Bug 1203616 - Test that waveshaper nodes don't corrupt their input buffer. r=karlt
--HG--
extra : rebase_source : a137eb3deef4fadfa686ff083712c1a614ec6fd8
2015-10-08 11:16:31 +02:00
Paul Adenot
e1154a6a56 Bug 1203616 - Properly scale the input buffer of a WaveShaperNode before processing it with the curve. r=karlt
--HG--
extra : rebase_source : b2505272bf0b177dfb0c6215d0e232a591b6650a
2015-10-08 11:16:31 +02:00
Andrea Marchesini
c53e405b13 Bug 1211511 - AudioChannelAgent::NotifyStartedPlaying and NotifyStoppedPlaying should use the same level of playback notification, r=roc 2015-10-07 20:06:47 +01:00
JW Wang
68837e7538 Bug 1211793 - Remove unnecessary creation of "MediaDecoder" log module. r=gerald. 2015-10-07 14:27:26 +08:00
sajitk
eb1836bb1e Bug 1180940 - Changed return type of AudioDestinationNode::CreateAudioChannelAgent method to return errors, if any methods that it calls fail. Added code to handle the return value in AudioContext::Init(), and its callers. r=baku 2015-10-05 04:35:00 +02:00
JW Wang
aadc51ecc8 Bug 1211766 - Remove AbstractMediaDecoder::GetReentrantMonitor(). r=jya. 2015-09-30 07:04:49 +08:00
Karl Tomlinson
31f93552de bug 1210266 unfriend AudioBufferSourceNode from AudioNode r=padenot
--HG--
extra : rebase_source : 8476dc3499835906378c910f879be7a2652fea81
2015-10-01 00:19:10 +13:00
Karl Tomlinson
8e20d26e10 bug 1210266 remove unused AudioNode::Callback() r=padenot
--HG--
extra : rebase_source : dd0e1f311982fb90852f8cb48f3e4517bf5fa8ce
2015-10-01 00:17:32 +13:00
Karl Tomlinson
2733a284c9 bug 1210266 remove unused AudioParam::Node() r=padenot
--HG--
extra : rebase_source : 095ffee90f8055792842f371712117ea1fcf92b9
2015-09-18 12:16:38 +12:00
Karl Tomlinson
4799b667a3 bug 1210266 use parameter index instead of node callback for sending timeline events r=padenot
--HG--
extra : rebase_source : 27a8ac26a83788c057a225fca47c49af1a021401
2015-10-01 15:48:20 +13:00
Karl Tomlinson
8d75533f8d bug 1210280 use nullptr for silent channels in UpMixDownMixChunk r=padenot
so that AccumulateInputChunk can optimize for silent channels.

--HG--
extra : rebase_source : 43228733d8586f16bab00737ffb381fbd8127fd3
2015-09-05 11:01:54 +12:00
Bob Owen
6a955b17bc Bug 1254990 - Remove strict content sandbox skip-ifs from tests. r=RyanVM 2016-03-09 16:42:40 +00:00
Carsten "Tomcat" Book
096c3d0073 Backed out changeset 8708392d9af3 (bug 1254992) for landing with wrong bug number 2016-03-10 11:02:44 +01:00
Bob Owen
b422e4c9a2 Bug 1254992: Remove strict content sandbox skip-ifs from tests. r=RyanVM 2016-03-10 08:58:01 +00:00
Paul Adenot
5467473807 Bug 1209904 - Optimize OscillatorNode when its frequency is not changin and it's using ::ComputeCustom. r=karlt 2015-10-01 10:52:28 +02:00
Nigel Babu
906147b670 Backed out changeset 04430cc26dba (bug 1180940) for Mulet Gij(4) bustage again.
--HG--
extra : amend_source : 3a0164d64d841349526acd11223cd88501a996f5
2015-10-01 13:53:14 +05:30
sajitk
43d9468d87 Bug 1180940 - Changed return type of AudioDestinationNode::CreateAudioChannelAgent method to return errors, if any methods that it calls fail. Added code to handle the return value in AudioContext::Init(), and its callers. r=baku 2015-09-30 17:51:00 +02:00
JW Wang
fd23a5e794 Bug 1208933 - Remove AbstractMediaDecoder::NotifyWaitingForResourcesStatusChanged(). r=jya. 2015-09-27 21:02:18 +08:00
JW Wang
0bb44154c7 Bug 1208932 - Remove ReadMetadataFailureReason::WAITING_FOR_RESOURCES. r=jya. 2015-09-27 20:48:09 +08:00
Andreas Pehrson
937747498a Bug 1170958 - Refactor DOMMediaStream to contain a 3-stage track chain. r=roc
This lets us separate tracks by ownership like so:
* Input    - Owned by the producer of the DOMMediaStream (gUM etc.)
* Owned    - Contains Input tracks (per above) or tracks cloned tracks
             if this DOMMediaStream is a clone.
* Playback - Contains Owned tracks plus tracks addTrack()ed to this
             DOMMediaStream minus tracks removeTrack()ed from this
             DOMMediaStream.

--HG--
extra : commitid : GPSNwBVyD4j
extra : rebase_source : fba22e96c6c65a74e012509f3da67a4d7df7a244
2015-09-30 09:31:54 +08:00
Andreas Pehrson
53a6c38d0d Bug 1170958 - Allow MediaInputPort to lock to a specific input track. r=roc
Locking to specific tracks lets us dynamically remove and add single
tracks to a ProcessedMediaStream.

--HG--
extra : commitid : GPSNwBVyD4j
extra : rebase_source : 0b1b79077f95bbefc8c71de551c5e3483a7d6ac0
2015-09-30 09:31:53 +08:00
Karl Tomlinson
23b10a8cba bug 1205558 remove DelayNodeEngine::mSource r=padenot
--HG--
extra : rebase_source : 2bc303e258a0d00ff3cf03ac3cb649046c05c0fb
2015-09-29 14:39:28 +13:00
Karl Tomlinson
cc26ca0fff bug 1205558 remove unnecessary ScriptProcessorNodeEngine::mSource r=padenot
--HG--
extra : rebase_source : 11eb2a10320e4e8028266730f3208f2b8cbc314f
2015-09-29 14:30:40 +13:00
Karl Tomlinson
56758d35f3 bug 1205558 remove unused AudioNodeStream* aSource parameter r=padenot
--HG--
extra : rebase_source : 23fb5cfaa0fa3bc117183bb122bbdf032957637b
2015-09-22 17:11:52 +12:00
Karl Tomlinson
24b8c43a95 bug 1205558 use destination stream for audio node engine time r=padenot
--HG--
extra : rebase_source : 19fa80f48fac673c13345002cd8e01d1b7a5ed3d
2015-09-22 16:34:45 +12:00
Karl Tomlinson
884c5a6d1f bug 1209286 remove now unnecessary StreamTimeToDOMTime and DOMTimeToStreamTime r=padenot
--HG--
extra : rebase_source : 7da869260707220259ef804f4b3cc6237a3d5843
2015-09-29 10:46:43 +13:00
Karl Tomlinson
22f0305b78 bug 1208318 ensure that currentTime has advanced sufficiently to easily detect failure r=padenot
--HG--
extra : rebase_source : 7ebf94ac10edb5b4ebd8b76e98e8a3821578ce04
2015-09-29 13:39:24 +13:00
Karl Tomlinson
5b32edea6d bug 1208318 modify test to avoid assuming different clocks are synchronized r=padenot
--HG--
extra : rebase_source : 31ecead7358bdb7b511d5efd802f479af46aef42
2015-09-25 13:05:03 +12:00
Kaustabh Datta Choudhury
5270e212b7 Bug 1162003 - Enable run-by-dir mode on Fx desktop mac debug platform and re-enable a few tests. r=jmaher 2015-09-28 10:54:22 -04:00
Karl Tomlinson
e8c9471dea bug 1208327 make enum AudioContextOperation strongly typed and forward declare instead of including AudioContext.h r=roc
AudioContext.h is now exported only under mozilla.dom.

--HG--
extra : rebase_source : 7fc0a25a6bb8efe497a0e779dca2df5d7e3397b1
2015-09-25 08:49:03 +12:00
Karl Tomlinson
dc7019feef bug 864171 move "extra" time accounting for AudioContext with no nodes to destination stream r=padenot
--HG--
extra : rebase_source : 28cb7a858721e80d68603c4adeaea55eb17f13ba
2015-09-23 19:05:46 +12:00
Karl Tomlinson
504ac09b2d bug 1053011 align "extra" time on AudioContext with processing block size r=padenot
--HG--
extra : rebase_source : efaf55d88a5c25e01d56a701a0f88205d67424f8
2015-09-23 19:52:26 +12:00
Wes Kocher
03a1803261 Backed out 9 changesets (bug 1170958) for frequent test_getUserMedia_addTrackRemoveTrack.html failures
Backed out changeset 277c1f8098d1 (bug 1170958)
Backed out changeset aa86bb9eea95 (bug 1170958)
Backed out changeset 8af8b85a4b26 (bug 1170958)
Backed out changeset ec1bf225e9cb (bug 1170958)
Backed out changeset 4a04ddca2b6b (bug 1170958)
Backed out changeset e85c9977a311 (bug 1170958)
Backed out changeset 16b40ff04e8f (bug 1170958)
Backed out changeset ad206925c84a (bug 1170958)
Backed out changeset 2106eccec79b (bug 1170958)
2015-09-25 13:08:55 -07:00
Paul Adenot
cb424cc5a1 Bug 1200579 - Stop copying AudioParam timelines. r=karlt
--HG--
extra : rebase_source : 3acc85754acb096843c45d5ad12e8e3f7954ecdc
2015-09-25 15:57:55 +02:00
Andreas Pehrson
eacfc2cf0e Bug 1170958 - Refactor DOMMediaStream to contain a 3-stage track chain. r=roc
This lets us separate tracks by ownership like so:
* Input    - Owned by the producer of the DOMMediaStream (gUM etc.)
* Owned    - Contains Input tracks (per above) or tracks cloned tracks
             if this DOMMediaStream is a clone.
* Playback - Contains Owned tracks plus tracks addTrack()ed to this
             DOMMediaStream minus tracks removeTrack()ed from this
             DOMMediaStream.

--HG--
extra : commitid : Kvj9RrN9MgP
2015-09-25 23:23:18 +08:00
Andreas Pehrson
cbd58a2839 Bug 1170958 - Allow MediaInputPort to lock to a specific input track. r=roc
Locking to specific tracks lets us dynamically remove and add single
tracks to a ProcessedMediaStream.

--HG--
extra : commitid : Kvj9RrN9MgP
2015-09-25 23:23:18 +08:00
Nigel Babu
c0f6363af9 Backed out changeset 49847eb6c1ce (bug 1180940) for Mulet Gij(4) bustage on CLOSED TREE 2015-09-24 12:37:52 +05:30
sajitk
33f44061ca Bug 1180940 - Changed return type of AudioDestinationNode::CreateAudioChannelAgent method to return errors, if any methods that it calls fail. Added code to handle the return value in AudioContext::Init(), and its callers. r=baku 2015-09-22 18:16:00 +02:00
Karl Tomlinson
cbf602ece7 bug 1207003 only create track for external AudioNodeStreams r=padenot
IsFinishedOnGraphThread() was unnecessary due to the !mFinished test.

--HG--
extra : rebase_source : 6dd493c1b87e0f2f16b897f537990f1ac7abba31
2015-09-18 17:07:40 +12:00
Karl Tomlinson
7fe490cca6 bug 1207003 add GraphTime parameter to ProcessBlock() and remove GetCurrentPosition() r=padenot
This is immediately useful for making the track unnecessary, but will also be
required when switching to the destination node stream for tracking time (bug
1205558) because using GetCurrentPosition() on the destination node stream
would give different results depending on the stream processing order (when
called during processing of streams not strictly upstream from the destination
node).

--HG--
extra : rebase_source : 7a3432b2e6a20fa3f42be05776c178dfda64d166
2015-09-18 17:05:25 +12:00
Karl Tomlinson
aa9fd09fa4 bug 1207003 remove unused aStream parameter r=padenot
--HG--
extra : rebase_source : b3c453cc2c13ca1a22bdc5946a8aa1c07639cbaa
2015-09-18 14:58:26 +12:00
Karl Tomlinson
5dc1c2c5d6 bug 1207003 fetch stream position once instead of three times r=padenot
--HG--
extra : rebase_source : b76cf41cf5eedae7f1b131703e14303e4f642560
2015-09-18 14:27:03 +12:00
Karl Tomlinson
49d09f7fa2 bug 1207003 coallesce external output chunks when silent r=padenot
AppendAndConsumeChunk() will always append a new chunk, but AppendNullData()
will use an existing null chunk if possible.

--HG--
extra : rebase_source : b00a131433e5548d2d5bb90303cf4d2e9568419b
2015-09-09 20:07:19 +12:00
Karl Tomlinson
1dcbc7744e bug 1207003 remove unnecessary EnsureTrack() call r=padenot
EnsureTrack() will be called in AdvanceOutputSegment(), if not blocked.

--HG--
extra : rebase_source : 1fe290135e2314bc518e8f67b6a98eddc6cf7768
2015-09-09 18:41:50 +12:00
Karl Tomlinson
644913284f bug 1206362 be careful about double -> int conversion r=padenot
--HG--
extra : rebase_source : 66fd40ddd3794ac225c581bbae56445d92362e12
2015-09-21 15:44:10 +12:00
JW Wang
9f60378309 Bug 1206574 - Remove AbstractMediaDecoder::IsShutdown(). r=cpearce. 2015-09-22 10:56:17 +08:00
Karl Tomlinson
026a99369a bug 1205540 account for active inputs and skip processing when streams are inactive r=padenot
--HG--
extra : rebase_source : 20eca7c13b9757fc9c79ee414a7b4c2c8da26be2
2015-09-18 00:03:00 +12:00
Karl Tomlinson
82019c145c bug 1205540 initialize mBufferFormat when constructing silent block r=padenot
This makes an AudioBlock valid for code testing mBufferFormat without IsNull(),
without the need for explicit SetNull().

This is useful so that setting AudioNodeStream::mLastChunks each iteration is
not required for inactive nodes.

--HG--
extra : rebase_source : 171b7339bfe91e15b070f03bd5e0b784b58a217a
2015-09-21 11:37:55 +12:00
Karl Tomlinson
2a0fb73346 bug 1205540 mark BufferSource finished only when producing silent output block r=padenot
This allows simpler processing of the finished state to mark the node as an
inactive input of any downstream nodes.  Otherwise the input could not be
considered inactive until after downstream nodes have finished processing,
but ProcessInput() may not be called again on finished streams.

AudioBufferSourceNode now behaves the same as OscillatorNode and similarly
to nodes that release a playing ref.

--HG--
extra : rebase_source : 1268ca8f561fee2a43ba17f5fe3abc804486a50c
2015-09-18 00:00:17 +12:00
Karl Tomlinson
57f288f403 bug 1205540 provide querying whether engines need to continue processing even without input r=padenot
--HG--
extra : rebase_source : 08dfd9685c49b93a9ca113434f62d92de26f58e7
2015-09-09 08:54:03 +12:00
Karl Tomlinson
7e9bfa19a5 bug 1205540 don't send more null chunks than necessary to AnalyserNode r=padenot
--HG--
extra : rebase_source : c1e6755ee91911f64a95a88abf469276be83f000
2015-09-09 08:52:39 +12:00
Paul Adenot
945decca4e Bug 1203836 - Test that MediaElementAudioSourceNode pipes correct data to an AudioContext. r=karlt
--HG--
extra : rebase_source : a7e55c894e665dcd57f69c730ec8aebc2af9152b
2015-09-21 11:00:12 +02:00
Paul Adenot
ccfa972c4c Bug 1203836 - Properly handle silent chunks in AudioNodeExternalInputStream. r=karlt
--HG--
extra : rebase_source : 272b220adf13ec2a62d048ccaab2f9d70af58987
2015-09-21 10:14:59 +02:00
Carsten "Tomcat" Book
1ae732f5ba Backed out 5 changesets (bug 1205540) for Assertion Failurs in m2-e10s tests on a CLOSED TREE
Backed out changeset e89d8182d588 (bug 1205540)
Backed out changeset abace4cdec06 (bug 1205540)
Backed out changeset b3f6e1db7233 (bug 1205540)
Backed out changeset 0d122cb34921 (bug 1205540)
Backed out changeset 4de5f87180fb (bug 1205540)
2015-09-18 16:36:33 +02:00
Karl Tomlinson
abcc44d6d5 bug 1205540 account for active inputs and skip processing when streams are inactive r=padenot
--HG--
extra : rebase_source : ad55142a54728e7ed2dab8edefbe87547e09d85a
2015-09-18 00:03:00 +12:00
Karl Tomlinson
985811fe37 bug 1205540 mark BufferSource finished only when producing silent output block r=padenot
This allows simpler processing of the finished state to mark the node as an
inactive input of any downstream nodes.  Otherwise the input could not be
considered inactive until after downstream nodes have finished processing,
but ProcessInput() may not be called again on finished streams.

AudioBufferSourceNode now behaves the same as OscillatorNode and similarly
to nodes that release a playing ref.

--HG--
extra : rebase_source : 0b3c7123f916fce36f852785c1e0b2a7c7013600
2015-09-18 00:00:17 +12:00
Karl Tomlinson
ee25bfb081 bug 1205540 provide querying whether engines need to continue processing even without input r=padenot
--HG--
extra : rebase_source : 76545deae4cdc929f1b3ce4d10065f99f21a2ec3
2015-09-09 08:54:03 +12:00
Karl Tomlinson
e182c00028 bug 1205540 don't send more null chunks than necessary to AnalyserNode r=padenot
--HG--
extra : rebase_source : f758d172fbbdba3288c71f690411175a41a822cc
2015-09-09 08:52:39 +12:00
Robert O'Callahan
f8eee03d38 Bug 1189506. Remove invalid assertion. r=karlt
That's nothing stopping someone passing an AudioContext time of (e.g.)
zero to AudioBufferSourceNode::Stop and OscillatorNode::Start/Stop, which
can get turned into a negative time here. Those nodes can handle negative
start/stop times just fine.

--HG--
extra : commitid : I6TtkZTlLRg
extra : rebase_source : 64e73f9ff30572f789cf4887acad97116aba33f3
2015-09-16 16:31:12 +12:00
Robert O'Callahan
cdada24c1f Bug 1189506. Call GraphTimeToStreamTime in AudioNodeExternalInputStream. r=karlt
--HG--
extra : commitid : EDYOTGF2Ade
extra : rebase_source : 9eeebfe7cc23cdeffb6688935ac07fd5f2118d1b
2015-09-08 16:46:10 +12:00
Robert O'Callahan
5e38d30d6f Bug 1189506. Create StreamTimeToGraphTime/GraphTimeToStreamTime that don't take account of blocking, and call them from AudioNodeStream. r=karlt
--HG--
extra : commitid : KZL20bqIcTe
extra : rebase_source : 001476a097968e6fa382949ababbf6bdd5e4f76d
2015-09-16 16:35:16 +12:00
Robert O'Callahan
13179ae295 Bug 1189506. Rename StreamTimeToGraphTime/GraphTimeToStreamTime to ...WithBlocking. r=karlt
--HG--
extra : commitid : 77I6WKoXbJA
extra : rebase_source : b289cbcb99c4bc52d70c78a6195c992bb5ba7ac1
2015-09-08 15:41:00 +12:00
Robert O'Callahan
d745ffaf22 Bug 1189506. Remove unused NotifyConsumptionChanged. r=karlt
--HG--
extra : commitid : 844LybDIKss
extra : rebase_source : 6a514c1ef0926e540e4d27a1e3f9561636c38ddb
2015-09-04 21:39:35 +12:00
Robert O'Callahan
1d3ba86e8a Bug 1189506. Non-SourceMediaStreams in processing can only block by being finished. r=karlt
--HG--
extra : commitid : EYewQUcwAbn
extra : rebase_source : 7531a3d0e33eeb17062988e21ae25938491402af
2015-09-04 17:40:30 +12:00
Robert O'Callahan
53dbc8f50e Bug 1189506. Remove aFlags parameter from AllocateInputPort. r=karlt
--HG--
extra : commitid : GZuYprloPNM
extra : rebase_source : 17ca412dd6232ad5c739918500d959a03895a65c
2015-09-04 16:42:42 +12:00
Robert O'Callahan
86c380603b Bug 1189506. Convert ChangeExplicitBlockerCount to MediaStream::Suspend/Resume. r=padenot
--HG--
extra : commitid : EAfe35GbRPL
extra : rebase_source : f6da37f3a9e8eefbdcf3e6787ec7edcc99e53859
2015-09-11 01:45:36 +12:00
Robert O'Callahan
65cc97b0f3 Bug 1189506. Make AudioContext responsible for tracking all nodes which need to be suspended and resumed. r=padenot
This simplifies MediaStreamGraph by removing the need for it to be aware
of which AudioContext a stream belongs to.

This also makes it easier to reuse stream suspending for purposes other than
AudioContext suspend/resume.

--HG--
extra : commitid : 9EmNxlrjVFO
extra : rebase_source : fee4b35d09c8f5dec76e41840d81423cde619886
2015-09-16 16:15:21 +12:00
Robert O'Callahan
a320393b12 Bug 1189506. Pass AudioContext to AudioNodeStream::Create. r=karlt
--HG--
extra : commitid : 2WtlMxxGnj1
extra : rebase_source : 31d3c936c139df1348249df1f34e5206d38647db
2015-09-09 01:22:16 +12:00
Robert O'Callahan
ee7597f8a2 Bug 1189506. Put AudioContext::State inline. r=karl
--HG--
extra : commitid : 1Jw8qDiXfVw
extra : rebase_source : 77055dabe9ae3b5dbcd2d4dfe02f9af927cb5b1c
2015-09-03 17:35:19 +12:00
Robert O'Callahan
edc3706647 Bug 1189506. Give AudioContext non-owning pointers to all its AudioNodes. r=karl
--HG--
extra : commitid : 8qGgR45qFgU
extra : rebase_source : 95285c6403f8578736826a908f1010093e09e59d
2015-09-03 17:12:25 +12:00
Andrew McCreight
5446225d17 Bug 1201271 - Warn about unused results for more methods of nsTArray. r=froydnj
This leaves alone the AppendElement methods.
2015-09-15 15:30:44 -07:00
Nicholas Nethercote
5db37503fb Bug 1204195 - Fix two warnings in dom/media/webaudio/blink/. r=rillian.
They were both "truncation from 'double' to 'float'" warnings.

This also allows the COMPILER_ALLOW_WARNINGS=True flag to be removed.

--HG--
extra : rebase_source : 4b57cba0d994671d5218be94d8f838582496ac1c
2015-09-14 18:09:14 -07:00
Karl Tomlinson
99e730c642 bug 1203380 add custom AudioBlock copy constructor and make AudioChunk conversion constructor explicit r=padenot
Making the conversion constructor explicit means that it will be obvious if
a temporary is created to pass an AudioChunk as an AudioBlock parameter.

--HG--
extra : rebase_source : 54bf8acdb42499a0e0d66cfc138ff6fb6f1ef4da
2015-09-10 09:29:34 +12:00
Karl Tomlinson
965591c713 bug 1203380 add custom assignment operator to AudioBlock r=padenot
--HG--
extra : rebase_source : 620bcfe8e7841ab1b19790abbf4df87a3e083c35
2015-09-10 08:39:12 +12:00
Karl Tomlinson
99d66c32cb bug 1203380 tighten not-sharing assertion in ChannelFloatsForWrite() r=padenot
--HG--
extra : rebase_source : 5206ae1ae59bade7f2b40400e0f851bf26df5d9c
2015-09-10 09:01:55 +12:00
Karl Tomlinson
4935533d54 bug 1203380 destroy AudioBlocks on AudioNodeStream on graph thread r=padenot
--HG--
extra : rebase_source : b2e560fa1c6da233de42667207946d2732727701
2015-09-10 15:13:45 +12:00
Karl Tomlinson
bae5d8a742 bug 1203380 ClearDownstreamMark() before returning AsMutableChunk() r=padenot
--HG--
extra : rebase_source : ddc5b3f2ec5238688bc13ed7d4c007fe91f42b85
2015-09-10 14:47:31 +12:00
James Cheng
6930bc717c Bug 1203047 - Make MediaDecoderReader know less about AudioData/VideoData by using MediaData instead. r=jya
--HG--
extra : rebase_source : 928721bb5a8669445725cab86e43be002f38c88a
2015-09-10 03:06:00 +02:00
Kaustabh Datta Choudhury
2a080acfd0 Bug 1162003 - Enable run-by-dir mode on Fx desktop debug & ASAN builds. r=jmaher 2015-09-10 09:52:00 +02:00
Karl Tomlinson
bc7c1ee7ee bug 1198656 delay AudioBuffer allocation until required r=padenot
This saves an allocation and zeroing for buffers generated by AudioNodes and
avoids allocation altogether for empty buffers.

Incidentally, RestoreJSChannelData() now avoids unnecessary recreation of
Float32Arrays if they already exist after a previous call failed.

--HG--
extra : transplant_source : %DAn7%D1J%C3%04%23%2B%A1%15%9F%95%E2%21%18%21%D2W%1F
2015-08-24 19:30:36 +12:00
Karl Tomlinson
393ecf041a bug 1198656 clear references in mJSChannels on successful content acquire r=padenot
The array buffers are no longer available and mJSChannels will be overwritten
in RestoreJSChannelData() before it is used again.  This is consistent with
"Attach ArrayBuffers containing copies of the data to the AudioBuffer, to be
returned by the next call to getChannelData."

--HG--
extra : transplant_source : x%C9%7C%D0%D9%08%CD%17%3F%D6o%BE3%BD%DCQE%DD%E5%9E
2015-08-24 15:06:43 +12:00
Karl Tomlinson
1acf06d43d bug 1198656 refactor acquiring the content into an object method r=padenot
This makes it clearer that the algorithm is intentionally aborted when any of
the buffers have been neutered and that the stolen data has the correct
length.

It also makes mJSChannels available for clearing in a subsequent changeset.

--HG--
extra : transplant_source : %9A%AA%D2Rs5%C9%BA%F9%26%9E%3C%9C%2C%40%D3%EA%23%BE%CA
2015-08-25 08:51:55 +12:00
Karl Tomlinson
ea0e72c924 bug 1198656 interpret null ConvolverNode mBuffer as a buffer of zeros r=padenot
Zero output even when normalize is set is consistent with
http://webaudio.github.io/web-audio-api/#widl-ConvolverNode-normalize
due to the specified isinf() test.

--HG--
extra : transplant_source : %17%BA%82%80%7DK%0EZOGg%7B%C0%0D%BF%93%D2%82%A0%E8
2015-08-21 17:14:14 +12:00
Karl Tomlinson
a56361388e bug 1198656 remove unnecessary reinterpret_casts r=padenot
JS_StealArrayBufferContents() returns void*.

--HG--
extra : transplant_source : %99%D0%DB%BC%EA%F5%D4%DB%01%88M%B9%E8%00%F1%3C%A0%B9%3D%FB
2015-08-21 16:44:04 +12:00
Wes Kocher
ba9de6a2f7 Backed out changeset f5b2a11c64c9 (bug 1201271) for bustage 2015-09-09 15:56:21 -07:00
Andrew McCreight
3e590f4e78 Bug 1201271 - Warn about unused results for more methods of nsTArray. r=froydnj
This leaves alone the AppendElement methods.
2015-09-09 15:39:10 -07:00
Joel Maher
af2cf10bce backout 06bb0c1766f1 for more frequent bc failures 2015-09-09 07:55:37 -04:00
Karl Tomlinson
4852256c3a bug 1197028 add MOZ_IMPLICIT for AudioBlock constructor from base AudioChunk on CLOSED TREE 2015-09-09 23:04:02 +12:00
Karl Tomlinson
46752d8354 bug 1201855 send ended event even when the buffer has no channel data r=padenot
The ThreadSharedFloatArrayBufferList may be null even when there is a buffer
if one of its arrays has been neutered.

SAMPLE_RATE is used instead of BUFFEREND to detect whether start() and buffer
have been received because buffers can have zero length when acquiring the
contents returns "zero-length channel data buffers", although this zero-length
is not yet implemented.

LOOP and BUFFEREND are reset when the buffer is set to null to end playback.

--HG--
extra : rebase_source : f247ca61e045ff548180da5c8c6e521e944620be
2015-09-05 00:15:52 +12:00
Karl Tomlinson
f0c5e3a312 bug 1201855 use unsigned integers for buffer positions so that negative buffer positions are impossible r=padenot
I think the limits on sample rates already ensure that mBufferPosition will
not overflow, but this makes sure that there are no out of bounds reads.

The node checks the parameters are > 0 before sending to the engine.

--HG--
extra : rebase_source : 3547c7a6ed8bd1e30a34c8c402a1c339ecb89ac2
2015-08-25 13:01:15 +12:00
Karl Tomlinson
129da4defa bug 1201855 keep track of buffer position even when there are no channels r=padenot
--HG--
extra : rebase_source : 38eb547011207d8f21970402204cac5613adb07b
2015-09-05 00:50:35 +12:00
Karl Tomlinson
153f9a5413 bug 1201855 rearrange CopyFromBuffer to separate code using numFrames r=padenot
--HG--
extra : rebase_source : ad70b02ae650410c6f7b86230ddfac3cda5d0aa9
2015-09-04 23:06:50 +12:00
Karl Tomlinson
2fba565b9f bug 1201854 handle stop time precisely even when resampling r=padenot
--HG--
extra : rebase_source : f2a8c0b28ff614e85d184e3f7c1bb8b0622caea9
2015-09-04 22:05:49 +12:00
Karl Tomlinson
e74d20e2da bug 1197028 use AudioBlock for web audio processing to reuse buffers shared downstream r=padenot
--HG--
extra : rebase_source : d2e403ae64a314177cba4d596ea235eb351ad3bc
2015-09-03 19:01:50 +12:00
Karl Tomlinson
c5c6b3c71f bug 1197028 introduce AudioBlock to keep track of downstream references to AudioBlockBuffer r=padenot
--HG--
extra : rebase_source : 18b55c10869e58cda0b3c9e99e4c97bd76f26359
2015-09-08 12:04:16 +12:00
Karl Tomlinson
cdffecdf9b bug 1197028 use AudioChunk::GetDuration() r=padenot
--HG--
extra : rebase_source : 48c1a44fd8509fc3a20f96861790be7b09715214
2015-09-03 18:04:41 +12:00
Karl Tomlinson
e32bdd4030 bug 1197028 use AudioChunk::ChannelCount() r=padenot
--HG--
extra : rebase_source : 033220c221f33fb4230f1384427d24e9b0b01213
2015-09-03 17:30:16 +12:00
Karl Tomlinson
0219374858 bug 1197028 introduce AudioBlockBuffer r=padenot
At this point AudioBlockBuffer is just like SharedBuffer but always with float
channels of length 128.

--HG--
extra : rebase_source : 61159da1577fb9607d5a766ba4288db3a7be2aff
2015-09-03 18:45:14 +12:00
Karl Tomlinson
68df460f8c bug 1197028 move AllocateAudioBlock to AudioBlock.h r=padenot
In a subsequent patch, AllocateAudioBlock will become part of an AudioBlock
class derived from AudioChunk and used for AudioNodeStream members.

--HG--
extra : rebase_source : a3bfde8345995865c6f8e46abed24f008c112702
2015-09-03 19:05:02 +12:00
Kaustabh Datta Choudhury
eeaa15095f Bug 1162003 - Enable run-by-dir mode on Fx desktop debug & ASAN builds. r=jmaher 2015-09-09 05:42:04 -04:00
Dragana Damjanovic dd.mozilla@gmail.com
94779891d5 Bug 1202421 - Rename the network.auth.allow-subresource-auth pref. r=michal 2015-09-08 08:21:19 -07:00
Robert O'Callahan
cfb5a21039 Bug 1201393. Remove usage of FLAG_BLOCK_INPUT from AudioParam/AudioNode. r=padenot
We don't need AudioNodes to block each other anymore.

--HG--
extra : commitid : 9rtWh5A3YY2
extra : rebase_source : cdd5c28b11602e53aaee178d3978b3e983ba5195
2015-08-31 16:58:10 +12:00
Robert O'Callahan
07c25fad56 Bug 1201393. Make suspended MediaStreams implicitly always block. r=padenot
To make this work, we have to iterate over suspended MediaStreams in a few
more places. We don't need START_TIME_DELAYED anymore since blocking takes
care of that. I think it's good to allow suspended MediaStreams to notify
the main thread that they're finished; we might need that later when
we have non-AudioNode streams being suspended.

--HG--
extra : commitid : AZKt73Eg3rQ
extra : rebase_source : a662e9c85453212299f30085c1228ec959355440
2015-09-04 17:01:01 +12:00
Robert O'Callahan
49d3b935f2 Bug 1201393. Remove usage of FLAG_BLOCK_INPUT from MediaStreamAudioSourceNode. r=jwwang
There's no reason why WebAudio should block an incoming MediaStream.

--HG--
extra : commitid : IjUoo3OFdq9
extra : rebase_source : 5df1530c9d927e30194931c15f97389b7b74b524
2015-08-31 16:56:33 +12:00
JW Wang
7cab08fca3 Bug 1195158. Part 4 - remove unused code. r=cpearce. 2015-09-07 11:39:16 +08:00
Karl Tomlinson
b02fb63b9a back out 0b4230b29db5,c8d987aeaece from bug 1197028 2015-09-02 23:44:37 +12:00
Karl Tomlinson
72bf6e31a4 bug 1193922 skip SetIsOnlyNodeForContext after shutdown r=padenot
This works around bug 1200514 but also avoids some unnecessary work.

--HG--
extra : rebase_source : 9f442f7eeac65976a711d6cc8e3947276bada756
2015-09-01 18:20:24 +12:00
Paul Adenot
7c49f38e2c Bug 901633 - Part 7 - Update AudioNodeExternalInputStream to use the new AudioChunk methods. r=karlt
--HG--
extra : rebase_source : 29fe9e5df5bb9a3521d65f7f56cfbc17480eeef0
2015-07-29 18:37:18 +02:00
Paul Adenot
aec5b5430b Bug 901633 - Part 6 - Update DelayBuffer to use the new AudioChunk methods. r=karlt
--HG--
extra : rebase_source : cb40d64841ca96562e5988aa37a30f0134194faf
2015-07-30 11:27:26 +02:00