]> iEval git - fdkaac.git/blob - man/fdkaac.1
add manpage
[fdkaac.git] / man / fdkaac.1
1 .TH fdkaac 1 "November 2013"
2 .\"
3 .\"
4 .SH NAME
5 fdkaac \- command line frontend for libfdk-aac encoder
6 .\"
7 .\"
8 .SH SYNOPSIS
9 .B fdkaac
10 [-h|--help] [-p|--profile <n>] [-b|--bitrate <n>] [-m|--bitrate-mode <n>]
11 [-w|--bandwith <n>] [-a|afterburner <n>] [-L|--lowdelay-sbr <n> ]
12 [-s|--sbr-ratio <n>] [-f|--transport-format <n>] [-C|--adts-crc-check]
13 [-h|--header-period <n>] [-G|--gapless-mode <n>] [--include-sbr-delay]
14 [-I|--ignore-length] [-S|--silent] [--mov-before-mdat]
15 [-R|--raw] [--raw-channels <n>] [--raw-rate <n>] [--raw-format <spec>]
16 [--title <str>] [--artist <str>] [--album <str>] [--genre <str>] [--date <str>]
17 [--composer <str>] [--grouping <str>] [--comment <str>] [--album-artist <str>]
18 [--track <num[/total]>] [--disk <num[/total]>] [--tempo <n>]
19 [--tag <fcc>:<value>] [--tag-from-file <fcc>:<value>]
20 [--long-tag <name>:<value>] [--tag-from-json <filename[?dot_notation]>]
21 [-o FILE] [FILE]
22 .\"
23 .\"
24 .SH DESCRIPTION
25 .B fdkaac
26 reads linear PCM audio in either WAV, raw PCM, or CAF format,
27 and encodes it into either M4A / AAC file.
28 .br
29 If the input file is "-", data is read from stdin.
30 Likewise, if the output file is "-", data is written to stdout if one of
31 streamable AAC transport formats is selected by
32 .B -f.
33 .br
34 When CAF input and M4A output is used, tags in CAF file are copied into
35 the resulting M4A.
36 .\"
37 .\"
38 .SH OPTIONS
39 .\"
40 .IP "-h, --help"
41 Show command help
42 .\"
43 .IP "-o <FILE>"
44 Output filename.
45 .\"
46 .IP "-p, --profile <n>"
47 Target profile (MPEG4 audio object type, AOT)
48 .RS
49 .IP 2
50 MPEG-4 AAC LC (default)
51 .IP 5
52 MPEG-4 HE-AAC (SBR)
53 .IP 29
54 MPEG-4 HE-AAC v2 (SBR+PS)
55 .IP 23
56 MPEG-4 AAC LD
57 .IP 39
58 MPEG-4 AAC ELD
59 .IP 129
60 MPEG-2 AAC LC
61 .IP 132
62 MPEG-2 HE-AAC (SBR)
63 .IP 156
64 MPEG-2 HE-AAC v2 (SBR+PS)
65 .RE
66 .\"
67 .IP "-b, --bitrate <n>"
68 Target bitrate (for CBR)
69 .\"
70 .IP "-m, --bitrate-mode <n>"
71 Bitrate configuration mode.
72 Available VBR quality value depends on other parameters such as
73 profile, sample rate, or number of channels.
74 .RS
75 .IP 0
76 CBR (default)
77 .IP 1-5
78 VBR (higher value -> higher bitrate)
79 .RE
80 .\"
81 .IP "-w, --bandwith <n>"
82 Frequency bandwith (lowpass cut-off frequency) in Hz. Available on AAC LC only.
83 .\"
84 .IP "-a, --afterburner <n>"
85 Configure afterburner mode. When enabled, quality is increased at the expense
86 of additional computational workload.
87 .RS
88 .IP 0
89 Off
90 .IP 1
91 On (default)
92 .RE
93 .\"
94 .IP "-L, --lowdelay-sbr <n>"
95 Configure SBR activity on AAC ELD.
96 .RS
97 .IP -1
98 Use ELD SBR auto configuration
99 .IP 0
100 Disable SBR on ELD (default)
101 .IP 1
102 Enable SBR on ELD
103 .RE
104 .\"
105 .IP "-s, --sbr-ratio <n>"
106 Controls activation of downsampled SBR.
107 .RS
108 .IP 0
109 Use lib default (default)
110 .IP 1
111 Use downsampled SBR (default for ELD+SBR)
112 .IP 2
113 Use dual-rate SBR (default for HE-AAC)
114 .RE
115 .RS
116 .PP
117 Dual-rate SBR is what is normally used for HE-AAC, where AAC is encoded at half the sample rate of SBR, hence "dual rate".
118 On the other hand, downsampled SBR uses same sample rate for both of AAC and SBR (single rate), therefore downsampled SBR typically consumes more bitrate.
119 .PP
120 Downsampled SBR is newly introduced feature in FDK encoder library version 3.4.12.
121 When libfdk-aac in the system doesn't support this, dual-rate SBR will be used.
122 When available, dual-rate SBR is the default for HE-AAC and downsampled SBR is the default for ELD+SBR.
123 .PP
124 Note that downsampled HE-AAC is not so common as dual-rate one.
125 When downsampled HE-AAC is selected,
126 .B fdkaac
127 is forced to choose explicit hierarchical SBR signaling, which (at least) iTunes doesn't accept.
128 .RE
129 .\"
130 .IP "-f, --transport-format <n>"
131 Transport format.
132 Tagging and gapless playback is only available on M4A. Streaming to stdout is
133 only available on others.
134 .RS
135 .IP 0
136 M4A (default)
137 .IP 1
138 ADIF
139 .IP 2
140 ADTS
141 .IP 6
142 LATM MCP=1
143 .IP 7
144 LATM MCP=0
145 .IP 10
146 LOAS/LATM (LATM within LOAS)
147 .RE
148 .\"
149 .IP "-C, --adts-crc-check"
150 Add CRC protection on ADTS header.
151 .\"
152 .IP "-h, --header-period <n>"
153 StreamMuxConfig/PCE repetition period in transport layer.
154 .\"
155 .IP "-G, --gapless-mode <n>"
156 Method to declare amount of encoder delay (and padding) in M4A container.
157 These values are mandatory for proper gapless playback on player side.
158 .RS
159 .IP 0
160 iTunSMPB (default)
161 .IP 1
162 ISO standard (edts and sgpd)
163 .IP 2
164 Both
165 .RE
166 .\"
167 .IP "--include-sbr-delay"
168 When specified, count SBR decoder delay in encoder delay.
169 .br
170 This is not iTunes compatible and will lead to gapless playback issue on
171 LC only decoder, but this is the default behavior of FDK library.
172 .br
173 Whether counting SBR decoder delay in encoder delay or not result in
174 incompatibility in gapless playback. You should pick which one will work for
175 your favorite player.
176 .br
177 However, it's better not to choose SBR at all if you want
178 gapless playback. LC doesn't have such issues.
179 .\"
180 .IP "-I, --ignorelength"
181 Ignore length field of data chunk in input WAV file.
182 .\"
183 .IP "-S, --silent"
184 Don't print progress messages.
185 .\"
186 .IP "--moov-before-mdat"
187 Place moov box before mdat box in M4A container.
188 .br
189 This option might be important for some hardware players, that are known to
190 refuse moov box placed after mdat box.
191 .\"
192 .IP "-R, --raw"
193 Regard input as raw PCM.
194 .\"
195 .IP "--raw-channels <n>"
196 Specify number of channels of raw input (default: 2)
197 .\"
198 .IP "--raw-rate <n>"
199 Specify sample rate of raw input (default: 44100)
200 .\"
201 .IP "--raw-format <spec>"
202 Specify sample format of raw input (default: "S16L").
203 .B Spec
204 is as the following (case insensitive):
205 .RS
206 .IP "1st char -- type of sample"
207 .B S
208 (igned) |
209 .B U
210 (nsigned) |
211 .B F
212 (loat)
213 .IP "2nd part (in digits)"
214 bits per channel
215 .IP "Last char -- endianness (can be ommited)
216 .B L
217 (ittle, default) |
218 .B B
219 (ig)
220 .RE
221 .\"
222 .IP "--title <string>"
223 Set title tag.
224 .\"
225 .IP "--artist <string>"
226 Set artist tag.
227 .\"
228 .IP "--album <string>"
229 Set album tag.
230 .\"
231 .IP "--genre <string>"
232 Set genre tag.
233 .\"
234 .IP "--date <string>"
235 Set date tag.
236 .\"
237 .IP "--composer <string>"
238 Set composer tag.
239 .\"
240 .IP "--grouping <string>"
241 Set grouping tag.
242 .\"
243 .IP "--comment <string>"
244 Set comment tag.
245 .\"
246 .IP "--album-artist <string>"
247 Set album artist tag.
248 .\"
249 .IP "--track <number[/total]>"
250 Set track tag, with or without number of total tracks.
251 .\"
252 .IP "--disk <number[/total]>"
253 Set disk tag, with or without number of total discs.
254 .\"
255 .IP "--tempo <n>"
256 Set tempo (BPM) tag.
257 .\"
258 .IP "--tag <fcc>:<value>"
259 Set iTunes predefined tag with explicit fourcc key and value.
260 .br
261 See
262 .B
263 https://code.google.com/p/mp4v2/wiki/iTunesMetadata
264 for known predefined keys.
265 .br
266 You can omit first char of
267 .B fcc
268 when it is the copyright sign.
269 .\"
270 .IP "--tag-from-file <fcc>:<filename>"
271 Same as --tag, but set content of file as tag value.
272 .\"
273 .IP "--long-tag <name>:<value>"
274 Set arbitrary tag as iTunes custom metadata. Stored in com.apple.iTunes field.
275 .\"
276 .IP "--tag-from-json <filename[?dot_notation]>"
277 Read tags from JSON. By default, tags are assumed to be direct children of the
278 root object in JSON. Optionary you can speficy arbitrary dot notation to locate
279 the object containing tags.
280 .\"
281 .\"
282 .SH EXAMPLES
283 .\"
284 .PP
285 Encode WAV file into a M4A file. MPEG4 AAC LC, VBR quality 3.
286 .RS
287 fdkaac -m3 foo.wav
288 .RE
289 .\"
290 .PP
291 Encode WAV file into a M4A file. MPEG4 HE-AAC, bitrate 64kbps.
292 .RS
293 fdkaac -p5 -b64 foo.wav
294 .RE
295 .\"
296 .PP
297 Piping from
298 .B ffmpeg
299 (you need version supporting CAF output)
300 .RS
301 ffmpeg -i foo.flac -f caf - | fdkaac -b128 - -o foo.m4a
302 .RE
303 .\"
304 .PP
305 Import tag using json generated by
306 .B (ff|av)probe
307 .RS
308 ffprobe -v 0 -of json -show_format foo.flac >foo.json
309 .br
310 flac -dc foo.flac | fdkaac - -o foo.m4a -b128 --import-tag-from-json foo.json?format.tags
311 .RE
312 .\"
313 .\"
314 .SH NOTES
315 .\"
316 .PP
317 Upto 32bit integer or 64bit floating point format is supported as input.
318 However, FDK library is implemented based on fixed point math and only supports 16bit integer PCM. Therefore, be careful of clipping. You might want to
319 dither/noise shape beforehand when your input has higher resolution.
320 .\"
321 .PP
322 Following channel layouts are supported by the encoder.
323 .RS
324 .IP 1ch
325 C
326 .IP 2ch
327 L R
328 .IP 3ch
329 C L R
330 .IP 4ch
331 C L R Cs
332 .IP 5ch
333 C L R Ls Rs
334 .IP 5.1ch
335 C L R Ls Rs LFE
336 .IP 7.1ch
337 C Lc Rc L R Ls Rs LFE (7.1ch front)
338 .br
339 C L R Ls Rs Rls Rrs LFE (7.1ch rear)
340 .RE
341 .\"
342 .SH AUTHORS
343 nu774 <honeycomb77@gmail.com>
This page took 0.066304 seconds and 4 git commands to generate.