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

Side by Side Diff: ppapi/c/trusted/ppb_audio_input_trusted_dev.h

Issue 8138008: Implementation of ppapi audio. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 9 years, 1 month 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
OLDNEW
(Empty)
1 /* Copyright (c) 2011 The Chromium Authors. All rights reserved.
viettrungluu 2011/11/08 00:41:54 "
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 /* From trusted/ppb_audio_trusted.idl modified Sat Jul 16 16:51:03 2011. */
7
8 #ifndef PPAPI_C_TRUSTED_PPB_AUDIO_INPUT_TRUSTED_DEV_H_
9 #define PPAPI_C_TRUSTED_PPB_AUDIO_INPUT_TRUSTED_DEV_H_
10
11 #include "ppapi/c/pp_completion_callback.h"
12 #include "ppapi/c/pp_instance.h"
13 #include "ppapi/c/pp_macros.h"
14 #include "ppapi/c/pp_resource.h"
15 #include "ppapi/c/pp_stdint.h"
16
17 #define PPB_AUDIO_INPUT_TRUSTED_DEV_INTERFACE_0_1 "PPB_AudioInputTrusted(Dev);0. 1"
18 #define PPB_AUDIO_INPUT_TRUSTED_DEV_INTERFACE PPB_AUDIO_INPUT_TRUSTED_DEV_INTERF ACE_0_1
19
20 /**
21 * @file
22 * This file defines the trusted audio input interface.
23 */
24
25
26 /**
27 * @addtogroup Interfaces
28 * @{
29 */
30 /**
31 * This interface is to be used by proxy implementations. All
32 * functions should be called from the main thread only. The
33 * resource returned is an Audio input esource; most of the PPB_Audio
34 * interface is also usable on this resource.
35 */
36 struct PPB_AudioInputTrusted_Dev {
37 /** Returns an audio input resource. */
38 PP_Resource (*CreateTrusted)(PP_Instance instance);
39 /**
40 * Opens a paused audio interface, used by trusted side of proxy.
41 * Returns PP_ERROR_WOULD_BLOCK on success, and invokes
42 * the |create_callback| asynchronously to complete.
43 * As this function should always be invoked from the main thread,
44 * do not use the blocking variant of PP_CompletionCallback.
45 */
46 int32_t (*Open)(PP_Resource audio,
47 PP_Resource config,
48 struct PP_CompletionCallback create_callback);
49 /**
50 * Get the sync socket. Use once Open has completed.
51 * Returns PP_OK on success.
52 */
53 int32_t (*GetSyncSocket)(PP_Resource audio, int* sync_socket);
54 /**
55 * Get the shared memory interface. Use once Open has completed.
56 * Returns PP_OK on success.
57 */
58 int32_t (*GetSharedMemory)(PP_Resource audio,
59 int* shm_handle,
60 uint32_t* shm_size);
61 };
62 /**
63 * @}
64 */
65
66 #endif /* PPAPI_C_TRUSTED_PPB_AUDIO_INPUT_TRUSTED_DEV_H_*/
67
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698