|
Home Resources Products
Developers |
Main • Moh
Music On Hold moduleThis module allows playing arbitrary raw audio streams from an external data source. It is typically used to provide entertainment to people waiting on hold or in a queue. Multiple named sources can be specified, for each only one external process is created and data is distributed internally to all consumers. Sample config file:
[mohs]
; List of pipelines that will be used as sources of music (on hold).
; Each pipeline should write to stdout in 16bit signed linear
; at default rate 8000/s or as specificed in the "rate" parameter.
; From outside (e.g. routing modules) mohs are addressed
; as moh/default, moh/noise etc.
; use mpg123 to play a bunch of mp3 files (shuffled)
default=while true; do mpg123 -q -m -r 8000 -s -Z sounds/*.mp3; done
; just (loud) random noise from our favorite source
noise=cat /dev/urandom
; a relatively new madplay (>=0.15) is the best choice - low CPU usage,
; built-in resampling, plays multiple files (shuffled)
madplay=while true; do madplay -q --no-tty-control -m -R 8000 -o raw:- -z sounds/*.mp3; done
; same madplay but with wideband support
wideband=while true; do madplay -q --no-tty-control -m -R ${rate$8000} -o raw:- -z sounds/*.mp3; done
|
3 May 2010: 8 March 2010: 6-7 February 2010: 2 Nov 2009: 6 Aug 2008: 4 Aug 2008: 10 Jul 2008: Feb 2008: 21 Jan 2008: 3 September: 14 August: 16 April: 25 September: 25 September: 11 July 2006: 10 July 2006: June 1st 2006: |