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

Side by Side Diff: content/renderer/pepper/pepper_plugin_delegate_impl.cc

Issue 9705056: PepperPlatformAudioInputImpl: support audio input device selection. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 9 months 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/pepper/pepper_plugin_delegate_impl.h" 5 #include "content/renderer/pepper/pepper_plugin_delegate_impl.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 #include <cstddef> 8 #include <cstddef>
9 #include <map> 9 #include <map>
10 #include <queue> 10 #include <queue>
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after
575 } 575 }
576 576
577 uint32_t PepperPluginDelegateImpl::GetAudioHardwareOutputBufferSize() { 577 uint32_t PepperPluginDelegateImpl::GetAudioHardwareOutputBufferSize() {
578 return static_cast<uint32_t>(audio_hardware::GetOutputBufferSize()); 578 return static_cast<uint32_t>(audio_hardware::GetOutputBufferSize());
579 } 579 }
580 580
581 webkit::ppapi::PluginDelegate::PlatformAudioOutput* 581 webkit::ppapi::PluginDelegate::PlatformAudioOutput*
582 PepperPluginDelegateImpl::CreateAudioOutput( 582 PepperPluginDelegateImpl::CreateAudioOutput(
583 uint32_t sample_rate, 583 uint32_t sample_rate,
584 uint32_t sample_count, 584 uint32_t sample_count,
585 webkit::ppapi::PluginDelegate::PlatformAudioCommonClient* client) { 585 webkit::ppapi::PluginDelegate::PlatformAudioOutputClient* client) {
586 return PepperPlatformAudioOutputImpl::Create(sample_rate, sample_count, 586 return PepperPlatformAudioOutputImpl::Create(sample_rate, sample_count,
587 client); 587 client);
588 } 588 }
589 589
590 webkit::ppapi::PluginDelegate::PlatformAudioInput* 590 webkit::ppapi::PluginDelegate::PlatformAudioInput*
591 PepperPluginDelegateImpl::CreateAudioInput( 591 PepperPluginDelegateImpl::CreateAudioInput(
592 const std::string& device_id,
592 uint32_t sample_rate, 593 uint32_t sample_rate,
593 uint32_t sample_count, 594 uint32_t sample_count,
594 webkit::ppapi::PluginDelegate::PlatformAudioCommonClient* client) { 595 webkit::ppapi::PluginDelegate::PlatformAudioInputClient* client) {
595 return PepperPlatformAudioInputImpl::Create(sample_rate, sample_count, 596 return PepperPlatformAudioInputImpl::Create(
596 client); 597 AsWeakPtr(), device_id, sample_rate, sample_count, client);
597 } 598 }
598 599
599 // If a broker has not already been created for this plugin, creates one. 600 // If a broker has not already been created for this plugin, creates one.
600 webkit::ppapi::PluginDelegate::Broker* 601 webkit::ppapi::PluginDelegate::Broker*
601 PepperPluginDelegateImpl::ConnectToBroker( 602 PepperPluginDelegateImpl::ConnectToBroker(
602 webkit::ppapi::PPB_Broker_Impl* client) { 603 webkit::ppapi::PPB_Broker_Impl* client) {
603 DCHECK(client); 604 DCHECK(client);
604 605
605 // If a broker needs to be created, this will ensure it does not get deleted 606 // If a broker needs to be created, this will ensure it does not get deleted
606 // before Connect() adds a reference. 607 // before Connect() adds a reference.
(...skipping 1031 matching lines...) Expand 10 before | Expand all | Expand 10 after
1638 render_view_->mouse_lock_dispatcher()->OnLockTargetDestroyed(target); 1639 render_view_->mouse_lock_dispatcher()->OnLockTargetDestroyed(target);
1639 delete target; 1640 delete target;
1640 mouse_lock_instances_.erase(it); 1641 mouse_lock_instances_.erase(it);
1641 } 1642 }
1642 } 1643 }
1643 1644
1644 webkit_glue::ClipboardClient* 1645 webkit_glue::ClipboardClient*
1645 PepperPluginDelegateImpl::CreateClipboardClient() const { 1646 PepperPluginDelegateImpl::CreateClipboardClient() const {
1646 return new RendererClipboardClient; 1647 return new RendererClipboardClient;
1647 } 1648 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698