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

Unified Diff: ppapi/proxy/ppb_audio_proxy.cc

Issue 22320004: Add a new parameter |latency| to PPB_Audio. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ppapi/proxy/ppb_audio_proxy.h ('k') | ppapi/proxy/resource_creation_proxy.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/ppb_audio_proxy.cc
diff --git a/ppapi/proxy/ppb_audio_proxy.cc b/ppapi/proxy/ppb_audio_proxy.cc
index aae9a5de198e927bdba291d6b7292c40be4de794..49ed0afb2d2e255757645b0347d42e0567e79680 100644
--- a/ppapi/proxy/ppb_audio_proxy.cc
+++ b/ppapi/proxy/ppb_audio_proxy.cc
@@ -37,7 +37,7 @@ class Audio : public Resource, public PPB_Audio_Shared {
public:
Audio(const HostResource& audio_id,
PP_Resource config_id,
- PPB_Audio_Callback callback,
+ const AudioCallbackCombined& callback,
void* user_data);
virtual ~Audio();
@@ -64,7 +64,7 @@ class Audio : public Resource, public PPB_Audio_Shared {
Audio::Audio(const HostResource& audio_id,
PP_Resource config_id,
- PPB_Audio_Callback callback,
+ const AudioCallbackCombined& callback,
void* user_data)
: Resource(OBJECT_IS_PROXY, audio_id),
config_(config_id) {
@@ -138,7 +138,7 @@ PPB_Audio_Proxy::~PPB_Audio_Proxy() {
PP_Resource PPB_Audio_Proxy::CreateProxyResource(
PP_Instance instance_id,
PP_Resource config_id,
- PPB_Audio_Callback audio_callback,
+ const AudioCallbackCombined& audio_callback,
void* user_data) {
PluginDispatcher* dispatcher = PluginDispatcher::GetForInstance(instance_id);
if (!dispatcher)
@@ -148,7 +148,7 @@ PP_Resource PPB_Audio_Proxy::CreateProxyResource(
if (config.failed())
return 0;
- if (!audio_callback)
+ if (!audio_callback.IsValid())
return 0;
HostResource result;
@@ -341,6 +341,7 @@ void PPB_Audio_Proxy::OnMsgNotifyAudioStreamCreated(
enter.resource()->pp_instance(), handle.shmem(),
media::PacketSizeInBytes(handle.size()),
IPC::PlatformFileForTransitToPlatformFile(socket_handle.descriptor()),
+ config.object()->GetSampleRate(),
config.object()->GetSampleFrameCount());
}
}
« no previous file with comments | « ppapi/proxy/ppb_audio_proxy.h ('k') | ppapi/proxy/resource_creation_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698