SampleWriter
Outputs samples to a file
Syntax
SampleWriter options
Options
- -name
- Optional user-defined name for the transform
- -channels
- number of audio channels
- Type: Integer
- Default: 1
- -format
- Output sample format, one of s8, u8, s16, u16, s32, u32, float, double, ulaw8, ulaw16
- Type: String
- Default: "s16"
Inlets
- onoff
- Turn sample writer on or off
- Type: Boolean
State Variables
- channels
- number of audio channels
- Type: Integer
- Default: 1
- format
- Output sample format, one of s8, u8, s16, u16, s32, u32, float, double, ulaw8, ulaw16
- Type: String
- Default: "s16"
Comments
SampleWriter supports the following audio file formats:
- .wav - Microsoft WAV file
- .aif,.aiff - AIFF Format
- .dat - Text format, 1 channel, textual floating-point numbers
- .sf - IRCAM Sound files
- .au - Sun/Java audio files
- .raw - Raw audio files
SampleWriter supports the following data formats, which can be explicitly set using the -format option:
- s88 bit, signed
- u88 bit, unsigned
- s1616 bit, signed
- u1616 bit, unsigned
- s3232 bit, signed
- u3232 bit, unsigned
- floatsingle-precision floating-point
- doubledouble-precision floating point
- ulaw88 bit, mu-law encoded
- ulaw1616 bit, mu-law encoded
Note that not all data formats are supported by each file format (e.g., ".dat" only supports double and ".au" supports only ulaw formats).