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

Issue 7631033: Very early implementation for HTMLMediaElement / Web Audio API integration (Closed)

Created:
9 years, 4 months ago by Chris Rogers
Modified:
9 years ago
CC:
chromium-reviews, hclam+watch_chromium.org, ddorwin+watch_chromium.org, fischman+watch_chromium.org, jam, acolwell+watch_chromium.org, annacc+watch_chromium.org, joi+watch-content_chromium.org, darin-cc_chromium.org, ajwong+watch_chromium.org, vrk (LEFT CHROMIUM), scherkus (not reviewing)
Visibility:
Public.

Description

Very early implementation for HTMLMediaElement / Web Audio API integration This is for early high-level comments and later will be split up into separate, more modular patches.

Patch Set 1 #

Total comments: 12

Patch Set 2 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+307 lines, -372 lines) Patch
M content/content_renderer.gypi View 1 1 chunk +2 lines, -0 lines 0 comments Download
M content/renderer/media/audio_device.h View 1 2 chunks +5 lines, -12 lines 0 comments Download
M content/renderer/media/audio_renderer_impl.h View 1 6 chunks +16 lines, -60 lines 0 comments Download
M content/renderer/media/audio_renderer_impl.cc View 1 11 chunks +99 lines, -298 lines 0 comments Download
A content/renderer/render_audiosourceprovider.h View 1 1 chunk +47 lines, -0 lines 0 comments Download
A content/renderer/render_audiosourceprovider.cc View 1 1 chunk +58 lines, -0 lines 0 comments Download
M content/renderer/render_view.cc View 1 3 chunks +5 lines, -1 line 0 comments Download
A media/filters/audio_renderer_sink.h View 1 1 chunk +48 lines, -0 lines 0 comments Download
M webkit/glue/webmediaplayer_impl.h View 1 3 chunks +8 lines, -0 lines 0 comments Download
M webkit/glue/webmediaplayer_impl.cc View 1 4 chunks +19 lines, -1 line 0 comments Download

Messages

Total messages: 3 (0 generated)
Chris Rogers
Early working prototype code. Looking for early review to iron out the rough spots. I'll ...
9 years, 4 months ago (2011-08-17 22:59:02 UTC) #1
scherkus (not reviewing)
didn't take a deep look but spotted a few higher-level things http://codereview.chromium.org/7631033/diff/1/content/renderer/media/audio_device.h File content/renderer/media/audio_device.h (right): ...
9 years, 4 months ago (2011-08-23 15:16:00 UTC) #2
Chris Rogers
9 years, 4 months ago (2011-08-24 00:41:51 UTC) #3
Hi Andrew, I've responded to your initial comments and have uploaded a new patch
trying to get us a little closer :)

http://codereview.chromium.org/7631033/diff/1/content/renderer/media/audio_de...
File content/renderer/media/audio_device.h (right):

http://codereview.chromium.org/7631033/diff/1/content/renderer/media/audio_de...
content/renderer/media/audio_device.h:61: class AudioSink : public
base::RefCountedThreadSafe<AudioSink> {
The idea is that there can be more than one kind of AudioSink:
1) AudioDevice which talks to the browser process
2) RenderAudioSourceProvider which connects into MediaElementAudioSourceNode
inside WebKit
3) ... maybe some other kind of destination for rendered audio stream in the
renderer ...

In this latest patch, I've renamed AudioSink to AudioRendererSink

On 2011/08/23 15:16:01, scherkus wrote:
> what's the reasoning behind using an AudioSink as opposed to passing an
> AudioDevice directly?
> 
> should also get moved to a separate .h file w/ docs

http://codereview.chromium.org/7631033/diff/1/content/renderer/media/audio_de...
content/renderer/media/audio_device.h:98: bool Start();
On 2011/08/23 15:16:01, scherkus wrote:
> Start/Stop/SetVolume() should become virtual and OVERRIDE

Done.

http://codereview.chromium.org/7631033/diff/1/content/renderer/media/audio_re...
File content/renderer/media/audio_renderer_impl.cc (right):

http://codereview.chromium.org/7631033/diff/1/content/renderer/media/audio_re...
content/renderer/media/audio_renderer_impl.cc:74: void
AudioRendererImpl::Render(const std::vector<float*>& audio_data,
Agreed.  Also, we should loop Aaron into the conversation since he's the one who
provided the majority of the code for this file.

On 2011/08/23 15:16:01, scherkus wrote:
> I haven't taken an indepth look at this class but we'll likely have to do some
> manual testing to make sure it works

http://codereview.chromium.org/7631033/diff/1/content/renderer/renderer_webau...
File content/renderer/renderer_webaudiosourceprovider_impl.h (right):

http://codereview.chromium.org/7631033/diff/1/content/renderer/renderer_webau...
content/renderer/renderer_webaudiosourceprovider_impl.h:15: class
RendererWebAudioSourceProviderImpl : public WebKit::WebAudioSourceProvider,
Ok, sounds good.  I've renamed this class to RenderAudioSourceProvider as you
suggest...

On 2011/08/23 15:16:01, scherkus wrote:
> naming nit... similar to how WebViewClient -> RenderView, what about cutting
> down on the Webs and Impls and going with RenderAudioSourceProvider?

http://codereview.chromium.org/7631033/diff/1/content/renderer/renderer_webau...
content/renderer/renderer_webaudiosourceprovider_impl.h:15: class
RendererWebAudioSourceProviderImpl : public WebKit::WebAudioSourceProvider,
I've added some comments here.  I can add more detail as necessary...

On 2011/08/23 15:16:01, scherkus wrote:
> docs for this class

http://codereview.chromium.org/7631033/diff/1/webkit/glue/webmediaplayer_impl.cc
File webkit/glue/webmediaplayer_impl.cc (right):

http://codereview.chromium.org/7631033/diff/1/webkit/glue/webmediaplayer_impl...
webkit/glue/webmediaplayer_impl.cc:12: #include
"content/renderer/media/audio_renderer_impl.h"
I've abstracted this a bit more and now am dealing with:
media::AudioRendererSink::RenderCallback

On 2011/08/23 15:16:01, scherkus wrote:
> src/webkit cannot depend on src/content code
> 
> what we'll likely have to do is declare an intermediate type/interface that
> allows us to create the AudioRendererImpl inside of RenderView but still let
us
> set the audio provider

Powered by Google App Engine
This is Rietveld 408576698