Commit | Line | Data |
---|---|---|
460b9539 | 1 | * DisOrder Raw Format Players |
2 | ||
3 | ** Purpose | |
4 | ||
5 | The purpose of raw format players is: | |
6 | ||
7 | * Support pausing of playing tracks, with the audio device closed when not | |
8 | in active use. | |
9 | ||
10 | * Eliminate the inter-track gap. | |
11 | ||
12 | * Perhaps in the future support network play. | |
13 | ||
14 | ** Usage | |
15 | ||
16 | To use raw format, use the execraw module and make the command choose the | |
5930fd1c RK |
17 | "disorder" libao driver. You may need to link the driver from wherever |
18 | DisOrder installs it (e.g. /usr/local/lib/ao/plugins-2) to where libao will | |
19 | look for it (e.g. /usr/lib/ao/plugins-2 or /sw/lib/ao/plugins-2). | |
460b9539 | 20 | |
21 | You should pass the "fragile" option to ogg123. This is because ogg123 ignores | |
22 | write errors! | |
23 | ||
24 | mpg321 does not appear to have this bug. | |
25 | ||
26 | For _non_ raw players it is advisable to use the new --wait-for-device option. | |
27 | This repeatedly tries to open the audio device before starting the player | |
28 | proper. It times out after a couple of seconds. | |
29 | ||
30 | See disorder_config(5) and the example configuration file for further | |
31 | information and examples. | |
32 | ||
33 | ** Low-Level Details | |
34 | ||
35 | Raw format players are started slightly differently to normal ones. Before | |
36 | they are executed a pipe is created and one end passed to a special speaker | |
37 | process, which is spawned by the main server at startup. The file descriptor | |
38 | of the player's end is identified by $DISORDER_RAW_FD. | |
39 | ||
40 | The expected data format is a ao_sample_format structure followed by the raw | |
41 | sample data. However, this may be changed without notice in future versions of | |
42 | DisOrder. If you need a stable interface here for some reason then get in | |
43 | touch. | |
44 | ||
45 | Raw format players may be started before the track is to be played, and (if the | |
46 | track is then removed from the queue before it reaches the head) terminated | |
47 | before the track ever reaches a physical speaker. The point of this is to | |
48 | allow audio data to be ready to play the moment the previous track end, without | |
49 | having to wait for the player to start up. There is no way for a player to | |
50 | tell that this is going on. | |
51 | ||
52 | Local Variables: | |
53 | mode:outline | |
54 | fill-column:79 | |
55 | End: |