Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Issue 1781043002: media::WebAudioSourceProviderImpl, add support for getting a copy of passing AudioBuses (Closed)

Created:
4 years, 9 months ago by mcasas
Modified:
4 years, 9 months ago
Reviewers:
DaleCurtis, Raymond Toy
CC:
chromium-reviews, feature-media-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

media::WebAudioSourceProviderImpl, add support for getting a copy of passing AudioBuses This is needed for https://crrev.com/1599533003/, which introduces an HtmlAudioCapturerSource to _copy_ the audio being played in a WebMediaPlayerImpl and send it into a MediaStream. On ToT, WASPImpl routes audio buses from |renderer_| to a RestartableAudioRendererSink passed on ctor (this is a "content" audio sink). This routing happens away from WASPImpl, i.e. they |renderer_| and |sink_| talk directly to each other. This CL basically forces all audio to pass via an internal class to WASPImpl so a client can register a callback to get a copy of the data. (The idea of calling such class TeeFilter comes from e.g. [1]) BUG=569976, 575492 TEST= added new unit test entry, and in the mentioned dependent CL [1] https://msdn.microsoft.com/en-us/library/windows/desktop/dd377612(v=vs.85).aspx Committed: https://crrev.com/3c7a35d354e0ecf10fba26822ea833d78d132285 Cr-Commit-Position: refs/heads/master@{#380989}

Patch Set 1 #

Total comments: 8

Patch Set 2 : dalecurtis@ comments. Added inner class for Audio tapping: TeeFilter. #

Total comments: 9

Patch Set 3 : dalecurtis@ comments #

Total comments: 4

Patch Set 4 : last round of comments from dalecurtis@ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+164 lines, -50 lines) Patch
M media/blink/webaudiosourceprovider_impl.h View 1 2 3 2 chunks +30 lines, -17 lines 0 comments Download
M media/blink/webaudiosourceprovider_impl.cc View 1 2 3 5 chunks +100 lines, -32 lines 0 comments Download
M media/blink/webaudiosourceprovider_impl_unittest.cc View 1 2 3 5 chunks +34 lines, -1 line 0 comments Download

Messages

Total messages: 22 (10 generated)
mcasas
dalecurtis@ please fwd appropriately or PTAL.
4 years, 9 months ago (2016-03-10 19:02:50 UTC) #2
mcasas
rtoy@ PTAL as well
4 years, 9 months ago (2016-03-10 23:21:09 UTC) #5
DaleCurtis
https://codereview.chromium.org/1781043002/diff/1/media/blink/webaudiosourceprovider_impl.cc File media/blink/webaudiosourceprovider_impl.cc (right): https://codereview.chromium.org/1781043002/diff/1/media/blink/webaudiosourceprovider_impl.cc#newcode118 media/blink/webaudiosourceprovider_impl.cc:118: const int frames = renderer_->Render(bus_wrapper_.get(), 0, 0); What do ...
4 years, 9 months ago (2016-03-11 01:41:43 UTC) #6
mcasas
Dale PTAL. https://codereview.chromium.org/1781043002/diff/1/media/blink/webaudiosourceprovider_impl.cc File media/blink/webaudiosourceprovider_impl.cc (right): https://codereview.chromium.org/1781043002/diff/1/media/blink/webaudiosourceprovider_impl.cc#newcode118 media/blink/webaudiosourceprovider_impl.cc:118: const int frames = renderer_->Render(bus_wrapper_.get(), 0, 0); ...
4 years, 9 months ago (2016-03-11 04:06:24 UTC) #10
DaleCurtis
https://codereview.chromium.org/1781043002/diff/40001/media/blink/webaudiosourceprovider_impl.cc File media/blink/webaudiosourceprovider_impl.cc (right): https://codereview.chromium.org/1781043002/diff/40001/media/blink/webaudiosourceprovider_impl.cc#newcode116 media/blink/webaudiosourceprovider_impl.cc:116: // Note: using always |set_format_cb_| ensures we have the ...
4 years, 9 months ago (2016-03-11 18:45:59 UTC) #11
mcasas
PTAL https://codereview.chromium.org/1781043002/diff/40001/media/blink/webaudiosourceprovider_impl.cc File media/blink/webaudiosourceprovider_impl.cc (right): https://codereview.chromium.org/1781043002/diff/40001/media/blink/webaudiosourceprovider_impl.cc#newcode116 media/blink/webaudiosourceprovider_impl.cc:116: // Note: using always |set_format_cb_| ensures we have ...
4 years, 9 months ago (2016-03-11 19:40:32 UTC) #12
DaleCurtis
https://codereview.chromium.org/1781043002/diff/40001/media/blink/webaudiosourceprovider_impl.h File media/blink/webaudiosourceprovider_impl.h (right): https://codereview.chromium.org/1781043002/diff/40001/media/blink/webaudiosourceprovider_impl.h#newcode47 media/blink/webaudiosourceprovider_impl.h:47: int channels, On 2016/03/11 19:40:32, mcasas wrote: > On ...
4 years, 9 months ago (2016-03-12 03:24:42 UTC) #13
DaleCurtis
lgtm
4 years, 9 months ago (2016-03-12 03:24:49 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1781043002/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1781043002/80001
4 years, 9 months ago (2016-03-14 16:38:17 UTC) #17
commit-bot: I haz the power
Committed patchset #4 (id:80001)
4 years, 9 months ago (2016-03-14 16:42:44 UTC) #19
commit-bot: I haz the power
Patchset 4 (id:??) landed as https://crrev.com/3c7a35d354e0ecf10fba26822ea833d78d132285 Cr-Commit-Position: refs/heads/master@{#380989}
4 years, 9 months ago (2016-03-14 16:44:40 UTC) #21
mcasas
4 years, 9 months ago (2016-03-16 18:50:51 UTC) #22
Message was sent while issue was closed.
old "Done"s.

https://codereview.chromium.org/1781043002/diff/60001/media/blink/webaudiosou...
File media/blink/webaudiosourceprovider_impl.cc (right):

https://codereview.chromium.org/1781043002/diff/60001/media/blink/webaudiosou...
media/blink/webaudiosourceprovider_impl.cc:56:
TeeFilter(AudioRendererSink::RenderCallback* const renderer,
On 2016/03/12 03:24:42, DaleCurtis wrote:
> RenderCallback* const doesn't mean anything as a parameter. I.e drop const.

Done.

https://codereview.chromium.org/1781043002/diff/60001/media/blink/webaudiosou...
File media/blink/webaudiosourceprovider_impl.h (right):

https://codereview.chromium.org/1781043002/diff/60001/media/blink/webaudiosou...
media/blink/webaudiosourceprovider_impl.h:68: void
RegisterCopyAudioCallback(const CopyAudioCB& callback);
On 2016/03/12 03:24:42, DaleCurtis wrote:
> s/Register/Set/ since there can only be one.

Done.

Powered by Google App Engine
This is Rietveld 408576698