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_CPP_DEV_AUDIO_INPUT_DEV_H_ | 5 #ifndef PPAPI_CPP_DEV_AUDIO_INPUT_DEV_H_ |
6 #define PPAPI_CPP_DEV_AUDIO_INPUT_DEV_H_ | 6 #define PPAPI_CPP_DEV_AUDIO_INPUT_DEV_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ppapi/c/dev/ppb_audio_input_dev.h" | 10 #include "ppapi/c/dev/ppb_audio_input_dev.h" |
(...skipping 19 matching lines...) Expand all Loading... |
30 /// Static function for determining whether the browser supports the required | 30 /// Static function for determining whether the browser supports the required |
31 /// AudioInput interface. | 31 /// AudioInput interface. |
32 /// | 32 /// |
33 /// @return true if the interface is available, false otherwise. | 33 /// @return true if the interface is available, false otherwise. |
34 static bool IsAvailable(); | 34 static bool IsAvailable(); |
35 | 35 |
36 int32_t EnumerateDevices( | 36 int32_t EnumerateDevices( |
37 const CompletionCallbackWithOutput<std::vector<DeviceRef_Dev> >& | 37 const CompletionCallbackWithOutput<std::vector<DeviceRef_Dev> >& |
38 callback); | 38 callback); |
39 | 39 |
| 40 int32_t MonitorDeviceChange(PP_MonitorDeviceChangeCallback callback, |
| 41 void* user_data); |
| 42 |
40 /// If |device_ref| is null (i.e., is_null() returns true), the default device | 43 /// If |device_ref| is null (i.e., is_null() returns true), the default device |
41 /// will be used. | 44 /// will be used. |
42 int32_t Open(const DeviceRef_Dev& device_ref, | 45 int32_t Open(const DeviceRef_Dev& device_ref, |
43 const AudioConfig& config, | 46 const AudioConfig& config, |
44 PPB_AudioInput_Callback audio_input_callback, | 47 PPB_AudioInput_Callback audio_input_callback, |
45 void* user_data, | 48 void* user_data, |
46 const CompletionCallback& callback); | 49 const CompletionCallback& callback); |
47 | 50 |
48 bool StartCapture(); | 51 bool StartCapture(); |
49 bool StopCapture(); | 52 bool StopCapture(); |
50 void Close(); | 53 void Close(); |
51 }; | 54 }; |
52 | 55 |
53 } // namespace pp | 56 } // namespace pp |
54 | 57 |
55 #endif // PPAPI_CPP_DEV_AUDIO_INPUT_DEV_H_ | 58 #endif // PPAPI_CPP_DEV_AUDIO_INPUT_DEV_H_ |
OLD | NEW |