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

Unified Diff: ppapi/thunk/ppb_audio_thunk.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/thunk/interfaces_ppb_public_stable.h ('k') | ppapi/thunk/resource_creation_api.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/thunk/ppb_audio_thunk.cc
diff --git a/ppapi/thunk/ppb_audio_thunk.cc b/ppapi/thunk/ppb_audio_thunk.cc
index 5dddb891784757b4b5dc1c83d76b68ad48a49b9b..646ae6b4c4444a75b63abba3beb9291562974cc2 100644
--- a/ppapi/thunk/ppb_audio_thunk.cc
+++ b/ppapi/thunk/ppb_audio_thunk.cc
@@ -2,8 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// From ppb_audio.idl modified Thu Dec 20 13:10:26 2012.
-
#include "ppapi/c/pp_errors.h"
#include "ppapi/c/ppb_audio.h"
#include "ppapi/shared_impl/tracked_callback.h"
@@ -18,6 +16,20 @@ namespace thunk {
namespace {
+PP_Resource Create_1_0(PP_Instance instance,
+ PP_Resource config,
+ PPB_Audio_Callback_1_0 audio_callback,
+ void* user_data) {
+ VLOG(4) << "PPB_Audio::Create()";
+ EnterResourceCreation enter(instance);
+ if (enter.failed())
+ return 0;
+ return enter.functions()->CreateAudio1_0(instance,
+ config,
+ audio_callback,
+ user_data);
+}
+
PP_Resource Create(PP_Instance instance,
PP_Resource config,
PPB_Audio_Callback audio_callback,
@@ -63,6 +75,14 @@ PP_Bool StopPlayback(PP_Resource audio) {
}
const PPB_Audio_1_0 g_ppb_audio_thunk_1_0 = {
+ &Create_1_0,
+ &IsAudio,
+ &GetCurrentConfig,
+ &StartPlayback,
+ &StopPlayback
+};
+
+const PPB_Audio_1_1 g_ppb_audio_thunk_1_1 = {
&Create,
&IsAudio,
&GetCurrentConfig,
@@ -76,5 +96,9 @@ const PPB_Audio_1_0* GetPPB_Audio_1_0_Thunk() {
return &g_ppb_audio_thunk_1_0;
}
+const PPB_Audio_1_1* GetPPB_Audio_1_1_Thunk() {
+ return &g_ppb_audio_thunk_1_1;
+}
+
} // namespace thunk
} // namespace ppapi
« no previous file with comments | « ppapi/thunk/interfaces_ppb_public_stable.h ('k') | ppapi/thunk/resource_creation_api.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698