client.m4: Adjust coding style of ggo options.
[paraslash.git] / m4 / gengetopt / audiod.m4
1 args "--no-handle-help --no-handle-version --conf-parser"
2
3 purpose "Connect to para_server, receive, decode and play audio streams"
4
5 include(header.m4)
6 define(CURRENT_PROGRAM,para_audiod)
7 define(DEFAULT_CONFIG_FILE,~/.paraslash/audiod.conf)
8
9 <qu>
10 #########################
11 section "General options"
12 #########################
13 </qu>
14
15 include(loglevel.m4)
16 include(color.m4)
17 include(config_file.m4)
18 include(logfile.m4)
19 include(log_timing.m4)
20 include(daemon.m4)
21 include(user.m4)
22 include(group.m4)
23
24 <qu>
25 ########################
26 section "Audiod options"
27 ########################
28
29 option "force" F
30 #~~~~~~~~~~~~~~~
31 "force startup"
32 flag off
33 details="
34         If this flag is not given, para_audiod refuses to start if the
35         well-known socket file (see the --socket option) already exists
36         because this usually means that para_audiod is already running
37         and listening on that socket. After a crash or if para_audiod
38         received a SIGKILL signal, a stale socket file might remain and
39         you have to use --force once to force startup of para_audiod.
40 "
41
42 option "mode" m
43 #~~~~~~~~~~~~~~
44 "startup mode"
45 string typestr="mode"
46 default="on"
47 optional
48 details="
49         Para_audiod supports three modes of operation: On, off and
50         standby (sb).  This option selects the mode that should be
51         used on startup. If para_audiod operates in \"on\" mode, it
52         will connect to para_server in order to receive its status
53         information. If para_server announces the availability of an
54         audio stream, para_audiod will automatically download, decode
55         and play the audio stream according to the given stream I/O
56         options, see below.
57
58         In \"standby\" mode, para_audiod will only receive the
59         status information from para_server but will not download
60         the audio stream.
61
62         In \"off\" mode, para_audiod does not connect para_server at
63         all, but still listens on the local socket for connections.
64 "
65
66 option "socket" s
67 #~~~~~~~~~~~~~~~~
68 "well-known socket"
69 string typestr="filename"
70 optional
71 details="
72         Para_audiod uses a \"well-known\" socket to listen
73         on for connections from para_audioc. This socket is a
74         special file in the file system; its location defaults to
75         /var/paraslash/audiod_sock.<host_name>.
76
77         para_audioc, the client program used to connect to para_audiod,
78         opens this socket in order to talk to para_audiod.  If the
79         default value for para_audiod is changed, para_audioc must be
80         instructed to use also \"filename\" for connecting para_audiod.
81 "
82
83 option "user-allow" -
84 #~~~~~~~~~~~~~~~~~~~~
85 "allow this user to connect to audiod"
86 string typestr = "username"
87 optional
88 multiple
89 details = "
90         Allow the user identified by username (either a string or
91         a UID) to connect to para_audiod. This option may be given
92         multiple times. If not specified at all, all users are allowed
93         to connect.
94
95         This feature is based on the ability to send unix
96         credentials through local sockets using ancillary data
97         (SCM_CREDENTIALS). Currently it only works on Linux. On
98         other operating systems the option is silently ignored and
99         all local users are allowed to connect.
100 "
101
102 option "clock-diff-count" -
103 #~~~~~~~~~~~~~~~~~~~~~~~~~~
104 "sync clock on startup"
105 int typestr="count"
106 default="0"
107 optional
108 details="
109         Check the clock difference between the host running para_server
110         and the local host running para_audiod that many times before
111         starting any stream I/0. Set this to non-zero for non-local
112         setups if the clocks of these two hosts are not synchronized
113         by ntp or similar.
114 "
115
116 #############################
117 section "Stream I/O options"
118 #############################
119
120 option "receiver" r
121 #~~~~~~~~~~~~~~~~~~
122 "select receiver"
123 string typestr="receiver_spec"
124 default="http"
125 optional
126 multiple
127 details="
128         This option may be given multiple times, for each audio format
129         separately. If multiple definitions for an audio format are
130         given, the first one is selected.
131
132         The \"receiver_spec\" consists of an audio format specifier
133         and one or more receiver arguments, separated by a colon.
134
135         The audio format specifier is a regular expression which
136         specifies the set of audio formats for which this option
137         should apply.
138
139         If any receiver options are present, the whole receiver
140         argument must be quoted:
141
142                 -r 'mp3:http -i my.host.org -p 8009'
143
144         Since a single dot '.' matches the name of any audio format,
145         specifying '.' instead of 'mp3' above activates the http
146         receiver for all audio formats.
147
148 "
149
150 option "filter" f
151 #~~~~~~~~~~~~~~~~
152 "Specify the filter configuration."
153 string typestr = "filter_spec"
154 optional
155 multiple
156 details = "
157         This option may be given multiple times. The \"filter_spec\"
158         consists of an audio format specifier (see above), the name
159         of the filter, and any options for that filter. Note that
160         order matters.
161
162         The compiled-in defaults apply to all audio formats for which
163         no --filter option was given. These defaults depend on the
164         receiver being used.
165
166         For HTTP streams, only the decoder for the current audio
167         format is activated. UDP and DCCP streams, on the other
168         hand, are sent FEC-encoded by para_server. In order to play
169         such streams, the receiver output must be FEC-decoded first,
170         i.e. fed to the fecdec filter. Therefore the default for UDP
171         and DCCP streams is to activate the fecdec filter, followed
172         by the decoding filter for the audio format.
173
174         Examples:
175
176                 --filter 'mp3:mp3dec'
177
178                 --filter 'mp3|aac:compress --inertia 5 --damp 2'
179
180                 --filter '.:fecdec'
181
182 "
183
184 option "writer" w
185 #~~~~~~~~~~~~~~~~
186 "Specify stream writer."
187 string typestr="writer_spec"
188 optional
189 multiple
190 details="
191         May be given multiple times, even multiple times for the same
192         audio format.  Default value is \"alsa\" for all supported
193         audio formats. Example:
194
195                 --writer 'aac|wma:oss'
196
197 "
198
199 option "stream-delay" -
200 #~~~~~~~~~~~~~~~~~~~~~~
201 "time for client sync"
202 int typestr="milliseconds"
203 default="200"
204 optional
205 details="
206         Add the given amount of milliseconds to the stream start time
207         announced by para_server and do not send data to the writer
208         before that time (modulo clock difference).
209
210         This is useful mainly for synchronizing the audio output of
211         different clients.
212 "
213 </qu>