]> git.tuebingen.mpg.de Git - paraslash.git/commitdiff
audiod: Document new regular expression syntax.
authorAndre Noll <maan@systemlinux.org>
Tue, 19 Apr 2011 23:28:10 +0000 (01:28 +0200)
committerAndre Noll <maan@systemlinux.org>
Fri, 3 Jun 2011 06:39:20 +0000 (08:39 +0200)
This changes the man page and the manual. The
usage of regular expressions for receiver, filter
and writers are explained and some examples are
provided.

ggo/audiod.m4
web/manual.m4

index 1b5008540af26a18166e38dfaec6b3eca839171d..628188d559bcc2ed718d9ac963adadc3e6ad7d12 100644 (file)
@@ -120,16 +120,26 @@ default="http"
 optional
 multiple
 details="
 optional
 multiple
 details="
-       This option may be given multiple times, once for each
-       supported audio format. The \"receiver_spec\" consists of
-       an audio format and the receiver name, separated by a colon,
-       and any options for that receiver, seperated by whitespace.
-       If any receiver options are present, the whole receiver
-       argument must be quoted.
+       This option may be given multiple times, for each audio format
+       separately. If multiple definitions for an audio format are
+       given, the first one is selected.
+
+       The \"receiver_spec\" consists of an audio format specifier
+       and one or more receiver arguments, separated by a colon.
 
 
-       Example:
+       The audio format specifier is a regular expression which
+       specifies the set of audio formats for which this option
+       should apply.
+
+       If any receiver options are present, the whole receiver
+       argument must be quoted:
 
                -r 'mp3:http -i my.host.org -p 8009'
 
                -r 'mp3:http -i my.host.org -p 8009'
+
+       Since a single dot '.' matches the name of any audio format,
+       specifying '.' instead of 'mp3' above activates the http
+       receiver for all audio formats.
+
 "
 
 option "no_default_filters" D
 "
 
 option "no_default_filters" D
@@ -164,14 +174,17 @@ multiple
 dependon="no_default_filters"
 details="
        This option may be given multiple times. The \"filter_spec\"
 dependon="no_default_filters"
 details="
        This option may be given multiple times. The \"filter_spec\"
-       consists of an audio format, the name of the filter, and any
-       options for that filter. Note that order matters.
+       consists of an audio format specifier (see above), the name
+       of the filter, and any options for that filter. Note that
+       order matters.
 
        Examples:
 
                --filter 'mp3:mp3dec'
 
 
        Examples:
 
                --filter 'mp3:mp3dec'
 
-               --filter 'mp3:compress --inertia 5 --damp 2'
+               --filter 'mp3|aac:compress --inertia 5 --damp 2'
+
+               --filter '.:fecdec'
 
 "
 
 
 "
 
@@ -186,7 +199,7 @@ details="
        audio format.  Default value is \"alsa\" for all supported
        audio formats. Example:
 
        audio format.  Default value is \"alsa\" for all supported
        audio formats. Example:
 
-               --writer 'aac:osx'
+               --writer 'aac|wma:oss'
 
 "
 
 
 "
 
index 46a2cd62f58e4c25eada652b10a855a60be60f1e..2af59f5376b4ecfadc6ce12a38b5781698b276ce 100644 (file)
@@ -415,9 +415,9 @@ as bar@client_host
 
 
 We will also have to tell para_audiod that it should receive the
 
 
 We will also have to tell para_audiod that it should receive the
-audio stream from server_host:
+audio stream from server_host via http:
 
 
-       para_audiod -l info -r 'mp3:http -i server_host'
+       para_audiod -l info -r '.:http -i server_host'
 
 You should now be able to listen to the audio stream once para_server
 starts streaming. To activate streaming, execute
 
 You should now be able to listen to the audio stream once para_server
 starts streaming. To activate streaming, execute
@@ -1431,8 +1431,7 @@ from being interpreted by para_recv.
 -> Create a minimal config for para_audiod for HTTP streams:
 
        c=$HOME/.paraslash/audiod.conf.min; s=server.foo.com
 -> Create a minimal config for para_audiod for HTTP streams:
 
        c=$HOME/.paraslash/audiod.conf.min; s=server.foo.com
-       formats="mp3 ogg aac wma" # remove what you do not have
-       for f in $formats; do echo receiver \"$f:http -i $s\"; done > $c
+       echo receiver \".:http -i $s\" > $c
        para_audiod --config $c
 
 -------
        para_audiod --config $c
 
 -------
@@ -1470,11 +1469,23 @@ the driving application (para_audiod or para_filter). Example:
        para_filter -f 'mp3dec --ignore-crc' -f 'compress --damp 1'
 
 For para_audiod, each audio format has its own set of filters. The
        para_filter -f 'mp3dec --ignore-crc' -f 'compress --damp 1'
 
 For para_audiod, each audio format has its own set of filters. The
-name of the audio format for which the filter should be applied is
-used as the prefix for the filter option. Example:
+name of the audio format for which the filter should be applied can
+be used as the prefix for the filter option. Example:
 
        para_audiod -f 'mp3:prebuffer --duration 300'
 
 
        para_audiod -f 'mp3:prebuffer --duration 300'
 
+The "mp3" prefix above is actually interpreted as a POSIX extended
+regular expression. Therefore
+
+       para_audiod -f '.:prebuffer --duration 300'
+
+activates the prebuffer filter for all supported audio formats (because
+"." matches all audio formats) while
+
+       para_audiod -f 'wma|ogg:prebuffer --duration 300'
+
+activates it only for wma and ogg streams.
+
 Decoders
 ~~~~~~~~
 
 Decoders
 ~~~~~~~~