blob: 196a386d223bfe97a8b0eb3f174bff8191c70283 [file] [log] [blame]
[email protected]eed24562012-03-07 07:48:481// Copyright (c) 2012 The Chromium Authors. All rights reserved.
[email protected]1f8a0892011-11-18 00:14:242// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef PPAPI_THUNK_AUDIO_INPUT_API_H_
6#define PPAPI_THUNK_AUDIO_INPUT_API_H_
7
avie029c4132015-12-23 06:45:228#include <stdint.h>
9
[email protected]eed24562012-03-07 07:48:4810#include <string>
[email protected]eed24562012-03-07 07:48:4811
[email protected]aed96532012-06-23 14:27:4212#include "base/memory/ref_counted.h"
[email protected]1f8a0892011-11-18 00:14:2413#include "ppapi/c/dev/ppb_audio_input_dev.h"
[email protected]1f8a0892011-11-18 00:14:2414
15namespace ppapi {
[email protected]eed24562012-03-07 07:48:4816
[email protected]aed96532012-06-23 14:27:4217class TrackedCallback;
[email protected]eed24562012-03-07 07:48:4818
[email protected]1f8a0892011-11-18 00:14:2419namespace thunk {
20
[email protected]77b55502012-11-08 22:20:2021class PPB_AudioInput_API {
[email protected]1f8a0892011-11-18 00:14:2422 public:
23 virtual ~PPB_AudioInput_API() {}
24
[email protected]4f01c762012-12-05 02:44:1825 virtual int32_t EnumerateDevices(const PP_ArrayOutput& output,
[email protected]aed96532012-06-23 14:27:4226 scoped_refptr<TrackedCallback> callback) = 0;
[email protected]4f01c762012-12-05 02:44:1827 virtual int32_t MonitorDeviceChange(PP_MonitorDeviceChangeCallback callback,
28 void* user_data) = 0;
[email protected]a23089d02014-01-06 23:51:4029 virtual int32_t Open0_3(PP_Resource device_ref,
[email protected]c90ffec72013-07-03 11:57:4530 PP_Resource config,
[email protected]a23089d02014-01-06 23:51:4031 PPB_AudioInput_Callback_0_3 audio_input_callback_0_3,
[email protected]c90ffec72013-07-03 11:57:4532 void* user_data,
33 scoped_refptr<TrackedCallback> callback) = 0;
[email protected]8917a672013-02-25 17:18:0434 virtual int32_t Open(PP_Resource device_ref,
[email protected]eed24562012-03-07 07:48:4835 PP_Resource config,
36 PPB_AudioInput_Callback audio_input_callback,
37 void* user_data,
[email protected]aed96532012-06-23 14:27:4238 scoped_refptr<TrackedCallback> callback) = 0;
[email protected]1f8a0892011-11-18 00:14:2439 virtual PP_Resource GetCurrentConfig() = 0;
40 virtual PP_Bool StartCapture() = 0;
41 virtual PP_Bool StopCapture() = 0;
[email protected]eed24562012-03-07 07:48:4842 virtual void Close() = 0;
[email protected]1f8a0892011-11-18 00:14:2443};
44
45} // namespace thunk
46} // namespace ppapi
47
48#endif // PPAPI_THUNK_AUDIO_INPUT_API_H_