1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
|
/**
* SPDX license identifier: MPL-2.0
*
* Copyright (C) 2011-2014, Wind River Systems
* Copyright (C) 2014, GENIVI Alliance
*
* This file is part of Pulse Audio Interface Routing Plugin.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License (MPL), v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* For further information see http://www.genivi.org/.
*
* List of changes:
*
* 21.08.2014, Adrian Scarlat, First version of the code;
* Porting code from AM ver1.x to AM ver3.0;
* Added Copyright and License information;
*/
#ifndef ROUTINGSENDERMAINLOPPPULSE_H_
#define ROUTINGSENDERMAINLOPPPULSE_H_
/* Defines */
/* In PulseAudio the volume value range from 0 (silence) to 0x10000U=65536 ("maximum" sensible volume). */
#define MAX_PULSE_VOLUME (0x10000U)
bool routing_sender_create_mainloop(void *thiz);
void * routing_sender_start_mainloop(void *thiz);
void routing_sender_get_sink_info_callback(
pa_context *c,
const pa_sink_info *i,
int is_last, void *thiz);
void routing_sender_context_state_callback(pa_context *c, void *thiz);
bool routing_sender_get_source_info(pa_context *c, void *thiz);
void routing_sender_pa_event_callback(
pa_context *c,
pa_subscription_event_type_t t,
uint32_t idx, void *thiz);
void routing_sender_get_sink_input_info_callback(
pa_context *c,
const pa_sink_input_info *i,
int eol,
void *thiz);
void routing_sender_get_source_output_info_callback(
pa_context *c,
const pa_source_output_info *i,
int eol,
void *userdata);
bool routing_sender_move_sink_input(
pa_context *c,
uint32_t sink_input_index,
uint32_t sink_index,
void *thiz);
bool routing_sender_move_source_output(
pa_context *c,
uint32_t source_output_index,
uint32_t source_index,
void *thiz);
bool routing_sender_sink_input_volume_ramp(
pa_context *c,
uint32_t sink_input_index,
uint32_t crt_volume,
uint32_t volume,
uint16_t ramp_time,
void *thiz);
bool routing_sender_sink_input_volume(
pa_context *c,
uint32_t sink_input_index,
uint32_t volume,
void *thiz);
bool routing_sender_sink_input_mute(
pa_context *c,
uint32_t sink_input_index,
bool mute,
void *thiz);
bool routing_sender_sink_volume(
pa_context *c,
uint32_t sink_index,
uint32_t volume,
void *thiz);
#endif
|