[Back to overview]
cptoshm --help
cptoshm (version 0.9.dev of frankl's stereo utilities)
USAGE:
cptoshm --shmname=/<name> [options]
This program copies the content of a file (or of stdin) into a shared
memory area.
USAGE HINTS
The converse is done by 'shmcat'. This can be used for audio playback
by copying music files from hard disc to memory before playing them.
This approach causes less operating system overhead compared to copying
music files to a ramdisk.
OPTIONS
--file=name, -i name
the name of the input file. If this is not given input is taken
from stdin (and in this case you have to specify --max-input).
--shmname=string, -o string
the name of the shared memory area to which the input is written.
By convention this name should start with a slash (/).
--buffer-size=intval, -b intval
the internal buffer size in bytes. The default is about 4 MB.
--max-input=intval, -m intval
this is the maximal number of bytes read from the input file.
If input is a file the default is the length of that file.
If input is stdin then this option must be given but may be
larger than the actual input.
--number-copies=intnum, -R intnum
before writing data they are copied the specfied number of
times to a cleaned temporary buffer in RAM and then back to the
cleaned original buffer. The default is 0.
--verbose, -v
print some information during startup and operation.
--version, -V
print information about the version of the program and abort.
--help, -h
print this help page and abort.
EXAMPLES
Copy a flac file to memory before playing and copy it into a playback
pipe.
cptoshm --file=mymusic.flac --shmname=/play.flac
shmcat --shmname=/play.flac | ...