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

Unified Diff: chrome/renderer/media/audio_renderer_impl.cc

Issue 357004: SetVolume and GetVolume take one volume instead of separate left and right vo... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/media/audio_renderer_impl.h ('k') | media/audio/audio_output.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/media/audio_renderer_impl.cc
===================================================================
--- chrome/renderer/media/audio_renderer_impl.cc (revision 30948)
+++ chrome/renderer/media/audio_renderer_impl.cc (working copy)
@@ -147,10 +147,9 @@
AutoLock auto_lock(lock_);
if (stopped_)
return;
- // TODO(hclam): change this to multichannel if possible.
io_loop_->PostTask(FROM_HERE,
NewRunnableMethod(
- this, &AudioRendererImpl::OnSetVolume, volume, volume));
+ this, &AudioRendererImpl::OnSetVolume, volume));
}
void AudioRendererImpl::OnCreated(base::SharedMemoryHandle handle,
@@ -211,7 +210,7 @@
}
}
-void AudioRendererImpl::OnVolume(double left, double right) {
+void AudioRendererImpl::OnVolume(double volume) {
// TODO(hclam): decide whether we need to report the current volume to
// pipeline.
}
@@ -259,13 +258,13 @@
filter_->Send(new ViewHostMsg_CloseAudioStream(0, stream_id_));
}
-void AudioRendererImpl::OnSetVolume(double left, double right) {
+void AudioRendererImpl::OnSetVolume(double volume) {
DCHECK(MessageLoop::current() == io_loop_);
AutoLock auto_lock(lock_);
if (stopped_)
return;
- filter_->Send(new ViewHostMsg_SetAudioVolume(0, stream_id_, left, right));
+ filter_->Send(new ViewHostMsg_SetAudioVolume(0, stream_id_, volume));
}
void AudioRendererImpl::OnNotifyPacketReady() {
« no previous file with comments | « chrome/renderer/media/audio_renderer_impl.h ('k') | media/audio/audio_output.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698