| 1 |
.Dd November 2, 2014 |
| 2 |
.Dt SNDFILE-CONVERT 1 |
| 3 |
.Os |
| 4 |
.Sh NAME |
| 5 |
.Nm sndfile-convert |
| 6 |
.Nd convert sound files from one format to another |
| 7 |
.Sh SYNOPSIS |
| 8 |
.Nm sndfile-convert |
| 9 |
.Op Fl override-sample-rate Ns = Ns Ar rate |
| 10 |
.Op Fl endian Ns = Ns Cm little | big | cpu |
| 11 |
.Op Fl normalize |
| 12 |
.Op Ar encoding |
| 13 |
.Ar input |
| 14 |
.Ar output |
| 15 |
.Sh DESCRIPTION |
| 16 |
.Nm |
| 17 |
converts sound files from one audio format to another. |
| 18 |
The output file is overwritten it it already exists. |
| 19 |
.Ss Formats |
| 20 |
The format of the output file is determined by the filename extension. |
| 21 |
The following file formats are currently recognized: |
| 22 |
.Pp |
| 23 |
.Bl -tag -compact -width ircam |
| 24 |
.It wav |
| 25 |
WAV (Microsoft) |
| 26 |
.It aif |
| 27 |
AIFF (Apple/SGI) |
| 28 |
.It au |
| 29 |
AU (Sun/NeXT) |
| 30 |
.It snd |
| 31 |
AU (Sun/NeXT) |
| 32 |
.It raw |
| 33 |
RAW (header-less) |
| 34 |
.It gsm |
| 35 |
RAW (header-less) |
| 36 |
.It vox |
| 37 |
RAW (header-less) |
| 38 |
.It paf |
| 39 |
PAF (Ensoniq PARIS, big-endian) |
| 40 |
.It fap |
| 41 |
PAF (Ensoniq PARIS, little-endian) |
| 42 |
.It svx |
| 43 |
IFF (Amiga IFF/SVX8/SV16) |
| 44 |
.It nist |
| 45 |
SPHERE (NIST SPeech HEader Resources) |
| 46 |
.It sph |
| 47 |
SPHERE (NIST SPeech HEader Resources) |
| 48 |
.It voc |
| 49 |
VOC (Creative Labs) |
| 50 |
.It ircam |
| 51 |
SF (Berkeley/IRCAM/CARL) |
| 52 |
.It sf |
| 53 |
SF (Berkeley/IRCAM/CARL) |
| 54 |
.It w64 |
| 55 |
W64 (SoundFoundry WAVE 64) |
| 56 |
.It mat |
| 57 |
MAT4 (GNU Octave 2.0 / Matlab 4.2) |
| 58 |
.It mat4 |
| 59 |
MAT4 (GNU Octave 2.0 / Matlab 4.2) |
| 60 |
.It mat5 |
| 61 |
MAT5 (GNU Octave 2.1 / Matlab 5.0) |
| 62 |
.It pvf |
| 63 |
PVF (Portable Voice Format) |
| 64 |
.It xi |
| 65 |
XI (FastTracker 2) |
| 66 |
.It htk |
| 67 |
HTK (HMM Tool Kit) |
| 68 |
.It sds |
| 69 |
SDS (Midi Sample Dump Standard) |
| 70 |
.It avr |
| 71 |
AVR (Audio Visual Research) |
| 72 |
.It wavex |
| 73 |
WAVEX (MS WAVE with WAVEFORMATEX) |
| 74 |
.It sd2 |
| 75 |
SD2 (Sound Designer II) |
| 76 |
.It flac |
| 77 |
FLAC (FLAC Lossless Audio Codec) |
| 78 |
.It caf |
| 79 |
CAF (Apple Core Audio File) |
| 80 |
.It wve |
| 81 |
WVE (Psion Series 3) |
| 82 |
.It prc |
| 83 |
WVE (Psion Series 3) |
| 84 |
.It ogg |
| 85 |
OGG (OGG Container format) |
| 86 |
.It oga |
| 87 |
OGG (OGG Container format) |
| 88 |
.It mpc |
| 89 |
MPC (Akai MPC 2k) |
| 90 |
.It rf64 |
| 91 |
RF64 (RIFF 64) |
| 92 |
.El |
| 93 |
.Ss Options |
| 94 |
The following options are recoginzed: |
| 95 |
.Pp |
| 96 |
.Bl -tag -compact -width "override-sample-rate=XXXXX" |
| 97 |
.It Fl override-sample-rate Ns = Ns Ar rate |
| 98 |
Make the input use sample rate of |
| 99 |
.Ar rate |
| 100 |
Hz. |
| 101 |
.It Fl endian Ns = Ns Cm little |
| 102 |
Make the output file use little endian data. |
| 103 |
.It Fl endian Ns = Ns Cm big |
| 104 |
Make the output file use big endian data. |
| 105 |
.It Fl endian Ns = Ns Cm cpu |
| 106 |
Make the output file use CPU endianness. |
| 107 |
.It Fl normalize |
| 108 |
Normalize the audio data in the output file. |
| 109 |
.El |
| 110 |
.Ss Encodings |
| 111 |
The optional |
| 112 |
.Ar encoding |
| 113 |
parameter allows setting of the data encoding for the output file. |
| 114 |
The following encodings are currently supported: |
| 115 |
.Pp |
| 116 |
.Bl -tag -compact -width ima-adpcmXX |
| 117 |
.It Fl pcms8 |
| 118 |
signed 8 bit pcm |
| 119 |
.It Fl pcmu8 |
| 120 |
unsigned 8 bit pcm |
| 121 |
.It Fl pcm16 |
| 122 |
16 bit pcm |
| 123 |
.It Fl pcm24 |
| 124 |
24 bit pcm |
| 125 |
.It Fl pcm32 |
| 126 |
32 bit pcm |
| 127 |
.It Fl float32 |
| 128 |
32 bit floating point |
| 129 |
.It Fl ulaw |
| 130 |
ULAW |
| 131 |
.It Fl alaw |
| 132 |
ALAW |
| 133 |
.It Fl ima-adpcm |
| 134 |
IMA ADPCM (WAV only) |
| 135 |
.It Fl ms-adpcm |
| 136 |
MS ADPCM (WAV only) |
| 137 |
.It Fl gsm610 |
| 138 |
GSM6.10 (WAV only) |
| 139 |
.It Fl dwvw12 |
| 140 |
12 bit DWVW (AIFF only) |
| 141 |
.It Fl dwvw16 |
| 142 |
16 bit DWVW (AIFF only) |
| 143 |
.It Fl dwvw24 |
| 144 |
24 bit DWVW (AIFF only) |
| 145 |
.It Fl vorbis |
| 146 |
Vorbis (OGG only) |
| 147 |
.El |
| 148 |
.Pp |
| 149 |
If no encoding is specified for the output file, |
| 150 |
.Nm |
| 151 |
will try to use the encoding of the input file. |
| 152 |
This will not always work as most container formats |
| 153 |
(e.g. WAV, AIFF etc) only support a small subset of encodings |
| 154 |
(e.g. 16 bit PCM, a-law, Vorbis etc). |
| 155 |
.Sh EXIT STATUS |
| 156 |
.Ex -std |
| 157 |
.Sh SEE ALSO |
| 158 |
.Lk http://libsndfile.github.io/libsndfile/ |
| 159 |
.Sh AUTHORS |
| 160 |
.An Erik de Castro Lopo Aq Mt [email protected] . |