OLD | NEW |
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 #ifndef PPAPI_THUNK_AUDIO_INPUT_API_H_ | 5 #ifndef PPAPI_THUNK_AUDIO_INPUT_API_H_ |
6 #define PPAPI_THUNK_AUDIO_INPUT_API_H_ | 6 #define PPAPI_THUNK_AUDIO_INPUT_API_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
11 #include "ppapi/c/dev/ppb_audio_input_dev.h" | 11 #include "ppapi/c/dev/ppb_audio_input_dev.h" |
12 | 12 |
13 namespace ppapi { | 13 namespace ppapi { |
14 | 14 |
15 class TrackedCallback; | 15 class TrackedCallback; |
16 | 16 |
17 namespace thunk { | 17 namespace thunk { |
18 | 18 |
19 class PPB_AudioInput_API { | 19 class PPB_AudioInput_API { |
20 public: | 20 public: |
21 virtual ~PPB_AudioInput_API() {} | 21 virtual ~PPB_AudioInput_API() {} |
22 | 22 |
23 virtual int32_t EnumerateDevices0_2( | |
24 PP_Resource* devices, | |
25 scoped_refptr<TrackedCallback> callback) = 0; | |
26 virtual int32_t EnumerateDevices(const PP_ArrayOutput& output, | 23 virtual int32_t EnumerateDevices(const PP_ArrayOutput& output, |
27 scoped_refptr<TrackedCallback> callback) = 0; | 24 scoped_refptr<TrackedCallback> callback) = 0; |
28 virtual int32_t MonitorDeviceChange(PP_MonitorDeviceChangeCallback callback, | 25 virtual int32_t MonitorDeviceChange(PP_MonitorDeviceChangeCallback callback, |
29 void* user_data) = 0; | 26 void* user_data) = 0; |
30 virtual int32_t Open0_2(PP_Resource device_ref, | 27 virtual int32_t Open0_3(PP_Resource device_ref, |
31 PP_Resource config, | 28 PP_Resource config, |
32 PPB_AudioInput_Callback_0_2 audio_input_callback_0_2, | 29 PPB_AudioInput_Callback_0_3 audio_input_callback_0_3, |
33 void* user_data, | 30 void* user_data, |
34 scoped_refptr<TrackedCallback> callback) = 0; | 31 scoped_refptr<TrackedCallback> callback) = 0; |
35 virtual int32_t Open(PP_Resource device_ref, | 32 virtual int32_t Open(PP_Resource device_ref, |
36 PP_Resource config, | 33 PP_Resource config, |
37 PPB_AudioInput_Callback audio_input_callback, | 34 PPB_AudioInput_Callback audio_input_callback, |
38 void* user_data, | 35 void* user_data, |
39 scoped_refptr<TrackedCallback> callback) = 0; | 36 scoped_refptr<TrackedCallback> callback) = 0; |
40 virtual PP_Resource GetCurrentConfig() = 0; | 37 virtual PP_Resource GetCurrentConfig() = 0; |
41 virtual PP_Bool StartCapture() = 0; | 38 virtual PP_Bool StartCapture() = 0; |
42 virtual PP_Bool StopCapture() = 0; | 39 virtual PP_Bool StopCapture() = 0; |
43 virtual void Close() = 0; | 40 virtual void Close() = 0; |
44 }; | 41 }; |
45 | 42 |
46 } // namespace thunk | 43 } // namespace thunk |
47 } // namespace ppapi | 44 } // namespace ppapi |
48 | 45 |
49 #endif // PPAPI_THUNK_AUDIO_INPUT_API_H_ | 46 #endif // PPAPI_THUNK_AUDIO_INPUT_API_H_ |
OLD | NEW |