chiark / gitweb /
Merge branch 'master' of git.distorted.org.uk:~mdw/publish/public-git/disorder
[disorder] / doc / disorder-playrtp.1.in
... / ...
CommitLineData
1.\"
2.\" Copyright (C) 2007-2009, 2013 Richard Kettlewell
3.\"
4.\" This program is free software: you can redistribute it and/or modify
5.\" it under the terms of the GNU General Public License as published by
6.\" the Free Software Foundation, either version 3 of the License, or
7.\" (at your option) any later version.
8.\"
9.\" This program is distributed in the hope that it will be useful,
10.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
11.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12.\" GNU General Public License for more details.
13.\"
14.\" You should have received a copy of the GNU General Public License
15.\" along with this program. If not, see <http://www.gnu.org/licenses/>.
16.\"
17.TH disorder-playrtp 1
18.SH NAME
19disorder-playrtp \- play DisOrder network broadcasts
20.SH SYNOPSIS
21.B disorder\-playrtp
22.RI [ OPTIONS ]
23.RB [ \-\- ]
24.RI [[ ADDRESS ]
25.IR PORT ]
26.SH DESCRIPTION
27\fBdisorder\-playrtp\fR plays a network broadcast sent from the specified
28address.
29.PP
30If neither an address nor port are specified then the local DisOrder
31configuration is consulted to find the server and the server is asked where the
32RTP stream is.
33.PP
34If just a port is specified then the RTP stream is assumed to be unicast or
35broadcast to that port.
36.PP
37If an address and a port are specified then the RTP stream is assumed to be
38multicast to that group address and port.
39.PP
40Alternatively, the
41.I ADDRESS
42can start with a
43.RB ` \- ',
44in which case
45.B disorder-playrtp
46will request a dedicated unicast stream from the server. The
47.RB ` \- '
48may be followed by an optional port, or address/port pair, which will be the
49local address/port to bind to and announce to the server.
50.SH OPTIONS
51.TP
52.B \-\-api\fR, -\fB-A\fR \fIAPI\fR
53Select the playback API.
54The possibilities are, depending on platform and compilation options:
55.RS 8
56.TP
57.B pulseaudio
58PulseAudio.
59.TP
60.B alsa
61ALSA.
62Linux only.
63.TP
64.B oss
65OSS.
66.TP
67.B coreaudio
68Core Audio.
69OS X only.
70.TP
71.B command
72Pipe audio to a command.
73.RE
74.IP
75The default is the first of the possibilities above that is supported.
76.TP
77.B \-\-device \fIDEVICE\fR, \fB\-D \fIDEVICE\fR
78Specifies the audio device to use.
79See
80.B "DEVICE NAMES"
81below for more information.
82.TP
83.B \-\-command \fICOMMAND\fR, \fB-e \fICOMMAND\fR
84Instead of sending to a physical audio device, invoke \fICOMMAND\fR using the
85shell and write audio samples to its standard input.
86Currently the input will be 44100KHz 16-bit signed stereo samples.
87If \fICOMMAND\fR exits it is re-executed; any samples that had been written to
88the pipe but not processed by the previous instance will be lost.
89.IP
90.B \-\-device
91is redundant with this option, but you might want to set
92.BR \-\-pause\-mode .
93.IP
94As an example,
95.B "-e \(aqcat > dump\(aq"
96would log audio data to a file for later processing.
97You could convert it to another format with, for instance:
98.IP
99.B "sox -c2 -traw -r44100 -s -w dump dump.wav"
100.TP
101.B \-\-pause\-mode \fIMODE\fR, \fB-P \fIMODE
102Set the pause mode for \fB\-\-command\fR to either \fBsilence\fR (the default), in
103which pauses are represented by sending silent samples, or \fBsuspend\fR, in which
104writes to the subprocess are suspended, requiring it to infer a pause from flow
105control.
106.TP
107.B \-\-config \fIPATH\fR, \fB\-C \fIPATH
108Set the system configuration file.
109The default is
110given by the
111.B DISORDER_CONFIG
112environment variable, defaulting to
113.IR pkgconfdir/config .
114.TP
115.B \-\-user-config \fIPATH\fR, \fB\-u \fIPATH
116Set the user configuration file.
117THe default is given by the
118.B DISORDER_USERCONFIG
119environment variable, defaulting to
120.IR $HOME/.disorder/passwd .
121.TP
122.B \-\-socket \fIPATH\fR, \fB\-s \fIPATH
123Set the control socket.
124Normally this would not be used manually.
125.TP
126.B \-\-help\fR, \fB\-h
127Display a usage message.
128.TP
129.B \-\-version\fR, \fB\-V
130Display version number.
131.SS "Buffer Control Options"
132You shouldn't need to use these options.
133Their effects are subject to change between version without warning.
134You should consult the source code for details of their effects.
135.TP
136.B \-\-min \fIFRAMES\fR, \fB\-m \fIFRAMES\fR
137Specifies the buffer low watermark in frames.
138This also acts as the target buffer occupancy.
139The default is taken from the
140.B rtp_minbuffer
141configuration parameter.
142.TP
143.B \-\-max \fIFRAMES\fR, \fB\-x \fIFRAMES\fR
144Specifies the maximum buffer size in frames.
145If there are this many frames in the buffer then reading from the
146network socket will be suspended.
147The default is twice the \fB\-\-min\fR value.
148The default is taken from the
149.B rtp_maxbuffer
150configuration parameter.
151.TP
152.B \-\-rcvbuf \fIBYTES\fR, \fB\-R \fIBYTES\fR
153Specifies socket receive buffer size.
154The default is not to change the buffer size, i.e. you get whatever the
155local operating system chooses.
156The buffer size will not be reduced below the operating system's default.
157The default is taken from the
158.B rtp_rcvbuf
159configuration parameter.
160.TP
161.B \-\-monitor\fR, \fB\-M
162Periodically report how close to the buffer low watermark the buffer is.
163If you have trouble with poor playback quality, enable this option to see if
164the buffer is emptying out (or overfilling, though there are measures to
165prevent that from happening).
166.SS "Deprecated Options"
167These options may be removed in a future version.
168Use \fB\-\-api\fR instead.
169.TP
170.B \-\-alsa\fR, \fB\-a
171Use ALSA to play sound.
172Only available on Linux.
173.TP
174.B \-\-oss\fR, \fB\-o
175Use OSS to play sound.
176Only available on Linux and FreeBSD.
177.TP
178.B \-\-core\-audio\fR, \fB\-c
179Use Core Audio to play sound.
180Only available on Macs.
181.SH "REMOTE CONTROL"
182The
183.B \-\-socket
184option is used by Disobedience to control a background
185.B disorder\-playrtp
186daemon.
187The socket will be created as a UNIX domain stream socket.
188When a connection is received a single line is read from it.
189The following commands are known:
190.TP
191.B stop
192Causes
193.B disorder\-playrtp
194to terminate.
195.TP
196.B query
197Causes the string "running" to be sent back.
198.TP
199.B getvol
200Print the left and right volume levels,
201as two decimal integers between 0 and 100,
202separated by a space.
203.TP
204.BI "setvol " left " " right
205Set the left and right volume levels to the given decimal values,
206which should be between 0 and 100;
207echo back the new values as for
208.B getvol
209above.
210.PP
211Other commands are ignored.
212After the first command the connection is closed.
213Only one connection at a time will be serviced.
214.PP
215This protocol is not guaranteed to be stable.
216.SH "DEVICE NAMES"
217.SS "Core Audio"
218On a Mac, the device name can either be the human-readable name of the desired
219output or its UID.
220To get a list of the human-readable names, visit System Preferences -> Sound;
221the Type column has the name you want.
222.PP
223For example, you might use "Built-in Output" for the built-in speaker
224or "Built-in Line Output" if you have connected external speakers.
225Remember to quote the name.
226.SH "SEE ALSO"
227.BR disobedience (1),
228.BR disorder_config (5),
229.BR disorderd (8)
230.\" Local Variables:
231.\" mode:nroff
232.\" fill-column:79
233.\" End: