PulseAudio  5.0
ext-device-restore.h
Go to the documentation of this file.
1 #ifndef foopulseextdevicerestorehfoo
2 #define foopulseextdevicerestorehfoo
3 
4 /***
5  This file is part of PulseAudio.
6 
7  Copyright 2008 Lennart Poettering
8  Copyright 2011 Colin Guthrie
9 
10  PulseAudio is free software; you can redistribute it and/or modify
11  it under the terms of the GNU Lesser General Public License as published
12  by the Free Software Foundation; either version 2.1 of the License,
13  or (at your option) any later version.
14 
15  PulseAudio is distributed in the hope that it will be useful, but
16  WITHOUT ANY WARRANTY; without even the implied warranty of
17  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18  General Public License for more details.
19 
20  You should have received a copy of the GNU Lesser General Public License
21  along with PulseAudio; if not, write to the Free Software
22  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
23  USA.
24 ***/
25 
26 #include <pulse/context.h>
27 #include <pulse/format.h>
28 #include <pulse/version.h>
29 
35 PA_C_DECL_BEGIN
36 
41  uint32_t index;
42  uint8_t n_formats;
45 
48  pa_context *c,
49  uint32_t version,
50  void *userdata);
51 
54  pa_context *c,
56  void *userdata);
57 
60  pa_context *c,
61  int enable,
63  void *userdata);
64 
67  pa_context *c,
68  pa_device_type_t type,
69  uint32_t idx,
70  void *userdata);
71 
75  pa_context *c,
77  void *userdata);
78 
81  pa_context *c,
82  const pa_ext_device_restore_info *info,
83  int eol,
84  void *userdata);
85 
88  pa_context *c,
90  void *userdata);
91 
94  pa_context *c,
95  pa_device_type_t type,
96  uint32_t idx,
98  void *userdata);
99 
102  pa_context *c,
103  pa_device_type_t type,
104  uint32_t idx,
105  uint8_t n_formats,
106  pa_format_info **formats,
108  void *userdata);
109 
110 PA_C_DECL_END
111 
112 #endif
struct pa_context pa_context
An opaque connection context to a daemon.
Definition: context.h:156
pa_operation * pa_ext_device_restore_save_formats(pa_context *c, pa_device_type_t type, uint32_t idx, uint8_t n_formats, pa_format_info **formats, pa_context_success_cb_t cb, void *userdata)
Read an entry from the device database.
Connection contexts for asynchronous communication with a server.
pa_device_type_t type
Device type sink or source?
Definition: ext-device-restore.h:40
struct pa_operation pa_operation
An asynchronous operation object.
Definition: operation.h:35
Utility functions for handling a stream or sink format.
void(* pa_context_success_cb_t)(pa_context *c, int success, void *userdata)
A generic callback for operation completion.
Definition: context.h:162
pa_operation * pa_ext_device_restore_subscribe(pa_context *c, int enable, pa_context_success_cb_t cb, void *userdata)
Subscribe to changes in the device database.
pa_operation * pa_ext_device_restore_read_formats(pa_context *c, pa_device_type_t type, uint32_t idx, pa_ext_device_restore_read_device_formats_cb_t cb, void *userdata)
Read an entry from the device database.
void pa_ext_device_restore_set_subscribe_cb(pa_context *c, pa_ext_device_restore_subscribe_cb_t cb, void *userdata)
Set the subscription callback that is called when pa_ext_device_restore_subscribe() was called...
void(* pa_ext_device_restore_read_device_formats_cb_t)(pa_context *c, const pa_ext_device_restore_info *info, int eol, void *userdata)
Callback prototype for pa_ext_device_restore_read_formats().
Definition: ext-device-restore.h:80
Stores information about one device in the device database that is maintained by module-device-manage...
Definition: ext-device-restore.h:39
uint32_t index
The device index.
Definition: ext-device-restore.h:41
pa_format_info ** formats
An array of formats (may be NULL if n_formats == 0)
Definition: ext-device-restore.h:43
Define header version.
struct pa_ext_device_restore_info pa_ext_device_restore_info
Stores information about one device in the device database that is maintained by module-device-manage...
uint8_t n_formats
How many formats do we have?
Definition: ext-device-restore.h:42
pa_operation * pa_ext_device_restore_test(pa_context *c, pa_ext_device_restore_test_cb_t cb, void *userdata)
Test if this extension module is available in the server.
pa_operation * pa_ext_device_restore_read_formats_all(pa_context *c, pa_ext_device_restore_read_device_formats_cb_t cb, void *userdata)
Read the formats for all present devices from the device database.
void(* pa_ext_device_restore_test_cb_t)(pa_context *c, uint32_t version, void *userdata)
Callback prototype for pa_ext_device_restore_test().
Definition: ext-device-restore.h:47
Represents the format of data provided in a stream or processed by a sink.
Definition: format.h:87
void(* pa_ext_device_restore_subscribe_cb_t)(pa_context *c, pa_device_type_t type, uint32_t idx, void *userdata)
Callback prototype for pa_ext_device_restore_set_subscribe_cb().
Definition: ext-device-restore.h:66
enum pa_device_type pa_device_type_t
The type of device we are dealing with.