OLD | NEW |
---|---|
(Empty) | |
1 /* Copyright (c) 2011 The Chromium Authors. All rights reserved. | |
2 * Use of this source code is governed by a BSD-style license that can be | |
3 * found in the LICENSE file. | |
4 */ | |
5 /** | |
6 * This file defines the trusted audio input interface. | |
7 */ | |
8 | |
9 label Chrome { | |
10 M17 = 0.1 | |
11 }; | |
12 | |
13 /** | |
14 * This interface is to be used by proxy implementations. All | |
15 * functions should be called from the main thread only. The | |
16 * resource returned is an Audio input esource; most of the PPB_Audio | |
dmichael (off chromium)
2011/11/17 04:05:21
nit: esource -> resource
viettrungluu
2011/11/21 21:26:13
Done.
| |
17 * interface is also usable on this resource. | |
18 */ | |
19 [version=0.1, macro="PPB_AUDIO_INPUT_TRUSTED_DEV_INTERFACE"] | |
dmichael (off chromium)
2011/11/17 04:05:21
nit: I don't think you need this line.
| |
20 interface PPB_AudioInputTrusted_Dev { | |
21 /** Returns an audio input resource. */ | |
22 PP_Resource CreateTrusted( | |
23 [in] PP_Instance instance); | |
dmichael (off chromium)
2011/11/17 04:05:21
Why do we need a separate 'Create' function? Can't
viettrungluu
2011/11/21 21:26:13
I'd have to check whether anything special is done
| |
24 | |
25 /** | |
26 * Opens a paused audio interface, used by trusted side of proxy. | |
27 * Returns PP_ERROR_WOULD_BLOCK on success, and invokes | |
28 * the |create_callback| asynchronously to complete. | |
29 * As this function should always be invoked from the main thread, | |
30 * do not use the blocking variant of PP_CompletionCallback. | |
31 */ | |
32 int32_t Open( | |
33 [in] PP_Resource audio_input, | |
34 [in] PP_Resource config, | |
35 [in] PP_CompletionCallback create_callback); | |
dmichael (off chromium)
2011/11/17 04:05:21
nit: it seems like the params could align right af
viettrungluu
2011/11/21 21:26:13
Also currently the style in all the .idl files.
| |
36 | |
37 /** | |
38 * Get the sync socket. Use once Open has completed. | |
39 * Returns PP_OK on success. | |
40 */ | |
41 int32_t GetSyncSocket( | |
42 [in] PP_Resource audio_input, | |
43 [out] handle_t sync_socket); | |
44 | |
45 /** | |
46 * Get the shared memory interface. Use once Open has completed. | |
47 * Returns PP_OK on success. | |
48 */ | |
49 int32_t GetSharedMemory( | |
50 [in] PP_Resource audio_input, | |
51 [out] handle_t shm_handle, | |
52 [out] uint32_t shm_size); | |
53 }; | |
OLD | NEW |