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

Side by Side Diff: ppapi/proxy/resource_creation_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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ppapi/proxy/resource_creation_proxy.h ('k') | ppapi/shared_impl/ppb_audio_config_shared.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "ppapi/proxy/resource_creation_proxy.h" 5 #include "ppapi/proxy/resource_creation_proxy.h"
6 6
7 #include "ppapi/c/pp_errors.h" 7 #include "ppapi/c/pp_errors.h"
8 #include "ppapi/c/pp_size.h" 8 #include "ppapi/c/pp_size.h"
9 #include "ppapi/proxy/audio_input_resource.h" 9 #include "ppapi/proxy/audio_input_resource.h"
10 #include "ppapi/proxy/connection.h" 10 #include "ppapi/proxy/connection.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 #include "ppapi/proxy/url_loader_resource.h" 44 #include "ppapi/proxy/url_loader_resource.h"
45 #include "ppapi/proxy/url_request_info_resource.h" 45 #include "ppapi/proxy/url_request_info_resource.h"
46 #include "ppapi/proxy/url_response_info_resource.h" 46 #include "ppapi/proxy/url_response_info_resource.h"
47 #include "ppapi/proxy/video_capture_resource.h" 47 #include "ppapi/proxy/video_capture_resource.h"
48 #include "ppapi/proxy/video_destination_resource.h" 48 #include "ppapi/proxy/video_destination_resource.h"
49 #include "ppapi/proxy/video_source_resource.h" 49 #include "ppapi/proxy/video_source_resource.h"
50 #include "ppapi/proxy/websocket_resource.h" 50 #include "ppapi/proxy/websocket_resource.h"
51 #include "ppapi/shared_impl/api_id.h" 51 #include "ppapi/shared_impl/api_id.h"
52 #include "ppapi/shared_impl/host_resource.h" 52 #include "ppapi/shared_impl/host_resource.h"
53 #include "ppapi/shared_impl/ppb_audio_config_shared.h" 53 #include "ppapi/shared_impl/ppb_audio_config_shared.h"
54 #include "ppapi/shared_impl/ppb_audio_shared.h"
54 #include "ppapi/shared_impl/ppb_input_event_shared.h" 55 #include "ppapi/shared_impl/ppb_input_event_shared.h"
55 #include "ppapi/shared_impl/ppb_resource_array_shared.h" 56 #include "ppapi/shared_impl/ppb_resource_array_shared.h"
56 #include "ppapi/shared_impl/var.h" 57 #include "ppapi/shared_impl/var.h"
57 #include "ppapi/thunk/enter.h" 58 #include "ppapi/thunk/enter.h"
58 #include "ppapi/thunk/ppb_image_data_api.h" 59 #include "ppapi/thunk/ppb_image_data_api.h"
59 60
60 using ppapi::thunk::ResourceCreationAPI; 61 using ppapi::thunk::ResourceCreationAPI;
61 62
62 namespace ppapi { 63 namespace ppapi {
63 namespace proxy { 64 namespace proxy {
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 PP_TimeTicks time_stamp, 179 PP_TimeTicks time_stamp,
179 uint32_t modifiers, 180 uint32_t modifiers,
180 const PP_FloatPoint* wheel_delta, 181 const PP_FloatPoint* wheel_delta,
181 const PP_FloatPoint* wheel_ticks, 182 const PP_FloatPoint* wheel_ticks,
182 PP_Bool scroll_by_page) { 183 PP_Bool scroll_by_page) {
183 return PPB_InputEvent_Shared::CreateWheelInputEvent( 184 return PPB_InputEvent_Shared::CreateWheelInputEvent(
184 OBJECT_IS_PROXY, instance, time_stamp, modifiers, 185 OBJECT_IS_PROXY, instance, time_stamp, modifiers,
185 wheel_delta, wheel_ticks, scroll_by_page); 186 wheel_delta, wheel_ticks, scroll_by_page);
186 } 187 }
187 188
189 PP_Resource ResourceCreationProxy::CreateAudio1_0(
190 PP_Instance instance,
191 PP_Resource config_id,
192 PPB_Audio_Callback_1_0 audio_callback,
193 void* user_data) {
194 return PPB_Audio_Proxy::CreateProxyResource(
195 instance, config_id, AudioCallbackCombined(audio_callback), user_data);
196 }
197
188 PP_Resource ResourceCreationProxy::CreateAudio( 198 PP_Resource ResourceCreationProxy::CreateAudio(
189 PP_Instance instance, 199 PP_Instance instance,
190 PP_Resource config_id, 200 PP_Resource config_id,
191 PPB_Audio_Callback audio_callback, 201 PPB_Audio_Callback audio_callback,
192 void* user_data) { 202 void* user_data) {
193 return PPB_Audio_Proxy::CreateProxyResource(instance, config_id, 203 return PPB_Audio_Proxy::CreateProxyResource(
194 audio_callback, user_data); 204 instance, config_id, AudioCallbackCombined(audio_callback), user_data);
195 } 205 }
196 206
197 PP_Resource ResourceCreationProxy::CreateAudioTrusted(PP_Instance instance) { 207 PP_Resource ResourceCreationProxy::CreateAudioTrusted(PP_Instance instance) {
198 // Proxied plugins can't create trusted audio devices. 208 // Proxied plugins can't create trusted audio devices.
199 return 0; 209 return 0;
200 } 210 }
201 211
202 PP_Resource ResourceCreationProxy::CreateAudioConfig( 212 PP_Resource ResourceCreationProxy::CreateAudioConfig(
203 PP_Instance instance, 213 PP_Instance instance,
204 PP_AudioSampleRate sample_rate, 214 PP_AudioSampleRate sample_rate,
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 bool ResourceCreationProxy::OnMessageReceived(const IPC::Message& msg) { 454 bool ResourceCreationProxy::OnMessageReceived(const IPC::Message& msg) {
445 return false; 455 return false;
446 } 456 }
447 457
448 Connection ResourceCreationProxy::GetConnection() { 458 Connection ResourceCreationProxy::GetConnection() {
449 return Connection(PluginGlobals::Get()->GetBrowserSender(), dispatcher()); 459 return Connection(PluginGlobals::Get()->GetBrowserSender(), dispatcher());
450 } 460 }
451 461
452 } // namespace proxy 462 } // namespace proxy
453 } // namespace ppapi 463 } // namespace ppapi
OLDNEW
« no previous file with comments | « ppapi/proxy/resource_creation_proxy.h ('k') | ppapi/shared_impl/ppb_audio_config_shared.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698