PROPHET/OS
NAME
play: plays an audio file on an output through the audio graph
SYNOPSIS
play [-o sink] [-w way] <file> | play --list
DESCRIPTION
Plays an audio file on an output through the audio graph. The format is found by the file's bytes; the formats are the library media (lib/codec/decode/, one folder each).
play song.wav on the default output play -o dx3 song.wav on the output whose name holds "dx3" play -w fixed song.mp3 the decoder's fixed way instead of its default play --list the formats, their ways and the outputs (on green, off grey)
A decoder may compute in more than one way: mp3 has float (the default where the machine has an FP unit) and fixed (integers in Q26, every machine). Both give the same sound.
Space pauses, q stops. At the end play says the frames it wrote and the frames the provider pulled of its ring, and returns 1 when fewer were pulled (audio_playtest proves it).
EXAMPLE
$ play --help play [-o sink] [-w way] <file> | play --list plays an audio file on the default output, or the sink whose name holds `sink`; -w picks the decoder's way (float, fixed); space pauses, q stops; --list names the formats, their ways and the outputs