X-Git-Url: http://git.xiph.org/?p=flac.git;a=blobdiff_plain;f=doc%2Fhtml%2Fdocumentation_tools_flac.html;h=8496aca909913af91e62de1f990bcbb5b8e6018e;hp=d5d3bbd4c4a5fcc145585755aa21f080cef073c2;hb=5598543a9663a846a0b7e42f395207bc44381e41;hpb=dc2b03b2416547083b03e08e0bc917f01448da05 diff --git a/doc/html/documentation_tools_flac.html b/doc/html/documentation_tools_flac.html index d5d3bbd4..8496aca9 100644 --- a/doc/html/documentation_tools_flac.html +++ b/doc/html/documentation_tools_flac.html @@ -1,11 +1,12 @@ - + + - + @@ -19,7 +20,7 @@
@@ -27,18 +28,10 @@ - -
-  english  | -  russian  +  more
@@ -52,6 +45,7 @@ Table of Contents General Usage

- flac is the command-line file encoder/decoder. The encoder currently supports as input RIFF WAVE, AIFF, FLAC or Ogg FLAC format, or raw interleaved samples. The decoder currently can output to RIFF WAVE or AIFF format, or raw interleaved samples. flac only supports linear PCM samples (in other words, no A-LAW, uLAW, etc.), and the input must be between 4 and 24 bits per sample. This is not a limitation of the FLAC format, just the reference encoder/decoder.
+ flac is the command-line file encoder/decoder. The encoder currently supports as input RIFF WAVE, Wave64, RF64, AIFF, FLAC or Ogg FLAC format, or raw interleaved samples. The decoder currently can output to RIFF WAVE, Wave64, RF64, or AIFF format, or raw interleaved samples. flac only supports linear PCM samples (in other words, no A-LAW, uLAW, etc.), and the input must be between 4 and 24 bits per sample. This is not a limitation of the FLAC format, just the reference encoder/decoder.

- flac assumes that files ending in ".wav" or that have the RIFF WAVE header present are WAVE files, files ending in ".aif" or ".aiff" or have the AIFF header present are AIFF files, and files ending in ".flac" or have the FLAC header present are FLAC files. This assumption may be overridden with a command-line option. It also assumes that files ending in ".ogg" of have the Ogg FLAC header present are Ogg FLAC files. Other than this, flac makes no assumptions about file extensions, though the convention is that FLAC files have the extension ".flac" (or ".fla" on ancient "8.3" file systems like FAT-16).
+ flac assumes that files ending in ".wav" or that have the RIFF WAVE header present are WAVE files, files ending in ".w64" or have the Wave64 header present are Wave64 files, files ending in ".rf64" or have the RF64 header present are RF64 files, files ending in ".aif" or ".aiff" or have the AIFF header present are AIFF files, and files ending in ".flac" or have the FLAC header present are FLAC files. This assumption may be overridden with a command-line option. It also assumes that files ending in ".oga" or ".ogg" or have the Ogg FLAC header present are Ogg FLAC files. Other than this, flac makes no assumptions about file extensions, though the convention is that FLAC files have the extension ".flac" (or ".fla" on ancient "8.3" file systems like FAT-16).

Before going into the full command-line description, a few other things help to sort it out: 1) flac encodes by default, so you must use -d to decode; 2) the options -0 .. -8 (or --fast and --best) that control the compression level actually are just synonyms for different groups of specific encoding options (described later) and you can get the same effect by using the same options; 3) flac behaves similarly to gzip in the way it handles input and output files.

+ Skip to the tutorial below for examples of some common tasks.
+
flac will be invoked one of four ways, depending on whether you are encoding, decoding, testing, or analyzing: - The encoding options affect the compression ratio and encoding speed. The format options are used to tell flac the arrangement of samples if the input file (or output file when decoding) is a raw file. If it is a RIFF WAVE or AIFF file the format options are not needed since they are read from the AIFF/WAVE header.
+ The encoding options affect the compression ratio and encoding speed. The format options are used to tell flac the arrangement of samples if the input file (or output file when decoding) is a raw file. If it is a RIFF WAVE, Wave64, RF64, or AIFF file the format options are not needed since they are read from the file's header.

In test mode, flac acts just like in decode mode, except no output file is written. Both decode and test modes detect errors in the stream, but they also detect when the MD5 signature of the decoded audio does not match the stored MD5 signature, even when the bitstream is valid.

@@ -122,6 +118,70 @@ flac has been tuned so that the default settings yield a good speed vs. compression tradeoff for many kinds of input. However, if you are looking to maximize the compression rate or speed, or want to use the full power of FLAC's metadata system, see About the FLAC Format.

+ Tutorial
+
+ Some common encoding tasks using flac:
+
+ flac abc.wav
+ Encode abc.wav to abc.flac using the default compression setting. abc.wav is not deleted.
+
+ flac --delete-input-file abc.wav
+ Like above, except abc.wav is deleted if there were no errors.
+
+ flac --delete-input-file -w abc.wav
+ Like above, except abc.wav is deleted if there were no errors or warnings.
+
+ flac --best abc.wav
+ Encode abc.wav to abc.flac using the highest compression setting.
+
+ flac --verify abc.wav
+ Encode abc.wav to abc.flac and internally decode abc.flac to make sure it matches abc.wav.
+
+ flac -o my.flac abc.wav
+ Encode abc.wav to my.flac.
+
+ flac -T "TITLE=Bohemian Rhapsody" -T "ARTIST=Queen" abc.wav
+ Encode abc.wav and add some tags at the same time to abc.flac.
+
+ flac *.wav
+ Encode all .wav files in the current directory. NOTE: Wildcards on Windows
+
+ flac abc.aiff
+ Encode abc.aiff to abc.flac.
+
+ flac abc.rf64
+ Encode abc.rf64 to abc.flac.
+
+ flac abc.w64
+ Encode abc.w64 to abc.flac.
+
+ flac abc.flac --force
+ This one's a little tricky: notice that flac is in encode mode by default (you have to specify -d to decode) so this command actually recompresses abc.flac back to abc.flac. --force is needed to make sure you really want to overwrite abc.flac with a new version. Why would you want to do this? It allows you to recompress an existing FLAC file with (usually) higher compression options or a newer version of FLAC and preserve all the metadata like tags too.
+
+ + Some common decoding tasks using flac:
+
+ flac -d abc.flac
+ Decode abc.flac to abc.wav. abc.flac is not deleted. NOTE: Without -d it means re-encode abc.flac to abc.flac (see above).
+
+ flac -d --force-aiff-format abc.flac
+ flac -d -o abc.aiff abc.flac
+ Two different ways of decoding abc.flac to abc.aiff (AIFF format). abc.flac is not deleted.
+
+ flac -d --force-rf64-format abc.flac
+ flac -d -o abc.rf64 abc.flac
+ Two different ways of decoding abc.flac to abc.rf64 (RF64 format). abc.flac is not deleted.
+
+ flac -d --force-wave64-format abc.flac
+ flac -d -o abc.w64 abc.flac
+ Two different ways of decoding abc.flac to abc.w64 (Wave64 format). abc.flac is not deleted.
+
+ flac -d -F abc.flac
+ Decode abc.flac to abc.wav and don't abort if errors are found (useful for recovering as much as possible from corrupted files).
+
+ flac has many other useful options, described below.
+
+
@@ -212,6 +272,15 @@ + + + + @@ -257,30 +326,64 @@ + + + + + + + + @@ -377,11 +480,10 @@ By default flac stops decoding with an error and removes the partially decoded file if it encounters a bitstream error. With -F, errors are still printed but flac will continue decoding to completion. Note that errors may cause the decoded audio to be missing some samples or have silent sections. -
+ + --no-utf8-convert + + Do not convert tags from local charset to UTF-8. This is useful for scripts, and setting tags in situations where the locale is wrong. This option must appear before any tag options! +
-w, --warnings-as-errors
+ + --preserve-modtime + + Output files have their timestamps/permissions set to match those of their inputs (this is default). Use --no-preserve-modtime to make output files have the current time and default permissions. +
+ + --keep-foreign-metadata + + If encoding, save WAVE, Wave64, RF64, or AIFF non-audio chunks in FLAC metadata. If decoding, restore any saved non-audio chunks from FLAC metadata when writing the decoded file. Foreign metadata cannot be transcoded, e.g. WAVE chunks saved in a FLAC file cannot be restored when decoding to AIFF. Input and output must be regular files (not stdin or stdout).
+ +
- --skip={#|mm:ss.ss} + --skip={#|mm:ss.ss}
--skip={#|mm:ss,ss}
Skip over the first # of samples of the input. This works for both encoding and decoding, but not testing. The alternative form mm:ss.ss can be used to specify minutes, seconds, and fractions of a second.

+ Note that the use of either a dot or a comma depends on the locale used for the system.
+
Examples:

--skip=123 : skip the first 123 samples of the input
- --skip=1:23.45 : skip the first 1 minute and 23.45 seconds of the input + --skip=1:23.45 : skip the first 1 minute and 23.45 seconds of the input, with a locale using the point as decimal separator
+ --skip=1:23,45 : skip the first 1 minute and 23.45 seconds of the input, with a locale using the comma as decimal separator
- --until={#|[+|-]mm:ss.ss} + --until={#|[+|-]mm:ss.ss}
--until={#|[+|-]mm:ss,ss}
Stop at the given sample number for each input file. This works for both encoding and decoding, but not testing. The given sample number is not included in the decoded output. The alternative form mm:ss.ss can be used to specify minutes, seconds, and fractions of a second. If a + sign is at the beginning, the --until point is relative to the --skip point. If a - sign is at the beginning, the --until point is relative to end of the audio.

+ Note that the use of either a dot or a comma depends on the locale used for the system.
+
Examples:

--until=123 : decode only the first 123 samples of the input (samples 0-122, stopping at 123)
--until=1:23.45 : decode only the first 1 minute and 23.45 seconds of the input
+ --until=1:23,45 : decode only the first 1 minute and 23.45 seconds of the input, if your locale setting uses a comma as decimal separator
--skip=1:00 --until=+1:23.45 : decode 1:00.00 to 2:23.45
--until=-1:23.45 : decode everything except the last 1 minute and 23.45 seconds
--until=-0:00 : decode until the end of the input (the same as not specifying --until) @@ -292,9 +395,9 @@ --ogg
- When encoding, generate Ogg FLAC output instead of native FLAC. Ogg FLAC streams are FLAC streams wrapped in an Ogg transport layer. The resulting file should have an '.ogg' extension and will still be decodable by flac.
+ When encoding, generate Ogg FLAC output instead of native FLAC. Ogg FLAC streams are FLAC streams wrapped in an Ogg transport layer. The resulting file should have an '.oga' extension and will still be decodable by flac.

- When decoding, force the input to be treated as Ogg FLAC. This is useful when piping input from stdin or when the filename does not end in '.ogg'.
+ When decoding, force the input to be treated as Ogg FLAC. This is useful when piping input from stdin or when the filename does not end in '.oga' or '.ogg'.

NOTE: Ogg FLAC files created prior to flac 1.1.1 used an ad-hoc mapping and do not support seeking. They should be decoded and re-encoded with flac 1.1.1 or later.
@@ -437,7 +538,7 @@ -V, --verify - Verify the encoding process. With this option, flac will create a parallel decoder that decodes the output of the encoder and compares the result against the original. It will abort immediately with an error if a mismatch occurs. -V increases the total encoding time but is guaranteed to catch any unforseen bug in the encoding process. + Verify the encoding process. With this option, flac will create a parallel decoder that decodes the output of the encoder and compares the result against the original. It will abort immediately with an error if a mismatch occurs. -V increases the total encoding time but is guaranteed to catch any unforeseen bug in the encoding process. @@ -455,7 +556,7 @@ --replay-gain - Calculate ReplayGain values and store them as FLAC tags, similar to VorbisGain. Title gains/peaks will be computed for each input file, and an album gain/peak will be computed for all files. All input files must have the same resolution, sample rate, and number of channels. Only mono and stereo files are allowed, and the sample rate must be one of 8, 11.025, 12, 16, 22.05, 24, 32, 44.1, or 48 kHz. Also note that this option may leave a few extra bytes in a PADDING block as the exact size of the tags is not known until all files are processed.
+ Calculate ReplayGain values and store them as FLAC tags, similar to VorbisGain. Title gains/peaks will be computed for each input file, and an album gain/peak will be computed for all files. All input files must have the same resolution, sample rate, and number of channels. Only mono and stereo files are allowed, and the sample rate must be one of 8, 11.025, 12, 16, 22.05, 24, 32, 44.1, or 48 kHz. Also note that this option may leave a few extra bytes in a PADDING block as the exact size of the tags is not known until all files are processed.

Note that this option cannot be used when encoding to standard output (stdout). @@ -511,7 +612,7 @@
DESCRIPTION is optional; the default is an empty string.

- The next part specfies the resolution and color information. If the MIME-TYPE is image/jpeg, image/png, or image/gif, you can usually leave this empty and they can be detected from the file. Otherwise, you must specify the width in pixels, height in pixels, and color depth in bits-per-pixel. If the image has indexed colors you should also specify the number of colors used. When manually specified, it is not checked against the file for accuracy.
+ The next part specifies the resolution and color information. If the MIME-TYPE is image/jpeg, image/png, or image/gif, you can usually leave this empty and they can be detected from the file. Otherwise, you must specify the width in pixels, height in pixels, and color depth in bits-per-pixel. If the image has indexed colors you should also specify the number of colors used. When manually specified, it is not checked against the file for accuracy.

FILE is the path to the picture file to be imported, or the URL if MIME type is -->

@@ -530,7 +631,21 @@
This option will have no effect if the files are already aligned (as is the normally the case with WAVE files ripped from a CD). flac can only align a set of files given in one invocation of flac.

- WARNING: The ordering of files is important! If you give a command like 'flac --sector-align *.wav' the shell may not expand the wildcard to the order you expect. To be safe you should 'echo *.wav' first to confirm the order, or be explicit like 'flac --sector-align 8.wav 9.wav 10.wav'. + WARNING: The ordering of files is important! If you give a command like 'flac --sector-align *.wav' the shell may not expand the wildcard to the order you expect. To be safe you should 'echo *.wav' first to confirm the order, or be explicit like 'flac --sector-align 8.wav 9.wav 10.wav'.
+
+ NOTE:This option is DEPRECATED and may not exist in future version of flac. shntool provides similar functionality. + + + + + + --ignore-chunk-sizes + + + When encoding to flac, ignore the file size headers in WAV and AIFF files to attempt to work around problems with over-sized or malformed files.
+
+ WAV and AIFF files both have an unsigned 32 bit numbers in the file header which specifes the length of audio data. Since this number is unsigned 32 bits, that limits the size of a valid file to being just over 4 Gigabytes. Files larger than this are mal-formed, but should be read correctly using this option.
+
@@ -683,7 +798,7 @@ -6, --compression-level-6 - Synonymous with -l 8 -b 4096 -m -r 6 + Synonymous with -l 8 -b 4096 -m -r 6 -A tukey(0.5);partial_tukey(2) @@ -692,7 +807,7 @@ -7, --compression-level-7 - Synonymous with -l 8 -b 4096 -m -e -r 6 + Synonymous with -l 12 -b 4096 -m -r 6 -A tukey(0.5);partial_tukey(2) @@ -701,7 +816,7 @@ -8, --compression-level-8 - Synonymous with -l 12 -b 4096 -m -e -r 6 + Synonymous with -l 12 -b 4096 -m -r 6 -A tukey(0.5);partial_tukey(2);punchout_tukey(3) @@ -737,9 +852,11 @@ -A "function", --apodization="function" - Window audio data with given the apodization function. The functions are: bartlett, bartlett_hann, blackman, blackman_harris_4term_92db, connes, flattop, gauss(STDDEV), hamming, hann, kaiser_bessel, nuttall, rectangle, triangle, tukey(P), welch.
+ Window audio data with given the apodization function. The functions are: bartlett, bartlett_hann, blackman, blackman_harris_4term_92db, connes, flattop, gauss(STDDEV), hamming, hann, kaiser_bessel, nuttall, rectangle, triangle, tukey(P), partial_tukey(n[/ov[/P]]), punchout_tukey(n[/ov[/P]]), welch.
For gauss(STDDEV), STDDEV is the standard deviation (0<STDDEV<=0.5).
For tukey(P), P specifies the fraction of the window that is tapered (0<=P<=1; P=0 corresponds to "rectangle" and P=1 corresponds to "hann").
+ For partial_tukey(n) and punchout_tukey(n), n apodization functions are added that span different parts of each block. Values of 2 to 6 seem to yield sane results. If necessary, an overlap can be specified, as can be the taper parameter, for example partial_tukey(2/0.2) or partial_tukey(2/0.2/0.5). ov should be smaller than 1 and can be negative.
+ Please note that P, STDDEV and ov are locale specific, so a comma as decimal separator might be required instead of a dot.
More than one -A option (up to 32) may be used. Any function that is specified erroneously is silently dropped. The encoder chooses suitable defaults in the absence of any -A options; any -A option specified replaces the default(s).
When more than one function is specified, then for every subframe the encoder will try each of them separately and choose the window that results in the smallest compressed subframe. Multiple functions can greatly increase the encoding time.
@@ -779,7 +896,7 @@ Set the [min,]max residual partition order. The min value defaults to 0 if unspecified.

- By default the encoder uses a single Rice parameter for the subframe's entire residual. With this option, the residual is iteratively partitioned into 2^min# .. 2^max# pieces, each with its own Rice parameter. Higher values of max# yield diminishing returns. The most bang for the buck is usually with -r 2,2 (more for higher block sizes). This usually shaves off about 1.5%. The technique tends to peak out about when blocksize/(2^n)=128. Use -r 0,16 to force the highest degree of optimization. + By default the encoder uses a single Rice parameter for the subframe's entire residual. With this option, the residual is iteratively partitioned into 2^min# .. 2^max# pieces, each with its own Rice parameter. Higher values of max# yield diminishing returns. The most bang for the buck is usually with -r 2,2 (more for higher block sizes). This usually shaves off about 1.5%. The technique tends to peak out about when blocksize/(2^n)=128. Use -r 0,15 to force the highest degree of optimization. @@ -845,7 +962,16 @@ --input-size=# - Specify the size of the raw input in bytes. If you are encoding raw samples from stdin, you must set this option in order to be able to use --skip, --until, --cue-sheet, or other options that need to know the size of the input beforehand. If the size given is greater than what is found in the input stream, the encoder will complain about an unexpected end-of-file. If the size given is less, samples will be truncated. + Specify the size of the raw input in bytes. If you are encoding raw samples from stdin, you must set this option in order to be able to use --skip, --until, --cuesheet, or other options that need to know the size of the input beforehand. If the size given is greater than what is found in the input stream, the encoder will complain about an unexpected end-of-file. If the size given is less, samples will be truncated. + + + + +
+ --force-raw-format + + + Treat the input file (or output file if decoding) as a raw file, regardless of the extension. @@ -854,16 +980,25 @@ --force-aiff-format - Force the decoder to output AIFF format. This option is not needed if the output filename (as set by -o) ends with .aiff. Also, this option has no effect when encoding since input AIFF is auto-detected. + Force the decoder to output AIFF format. This option is not needed if the output filename (as set by -o) ends with .aif or .aiff. Also, this option has no effect when encoding since input AIFF is auto-detected. - - --force-raw-format + + --force-rf64-format - Treat the input file (or output file if decoding) as a raw file, regardless of the extension. + Force the decoder to output RF64 format. This option is not needed if the output filename (as set by -o) ends with .rf64. Also, this option has no effect when encoding since input RF64 is auto-detected. + + + + + + --force-wave64-format + + + Force the decoder to output Wave64 format. This option is not needed if the output filename (as set by -o) ends with .w64. Also, this option has no effect when encoding since input Wave64 is auto-detected. @@ -881,15 +1016,18 @@ --no-adaptive-mid-side
+ --no-cued-seekpoints
--no-decode-through-errors
--no-delete-input-file
--no-escape-coding
--no-exhaustive-model-search
+ --no-ignore-chunk-sizes
--no-lax
--no-mid-side
--no-ogg
--no-padding
- --no-qlp-coeff-precision-search
+ --no-preserve-modtime
+ --no-qlp-coeff-prec-search
--no-residual-gnuplot
--no-residual-text
--no-sector-align
@@ -908,120 +1046,126 @@
Option Index

- -0
- -1
- -2
- -3
- -4
- -5
- -6
- -7
- -8
- -A
- -a
- --adaptive-mid-side
- --analyze
- --apodization
- - -b
- --best
- --blocksize
- --bps
- -c
- --channels
- --compression-level-0
- --compression-level-1
- --compression-level-2
- --compression-level-3
- --compression-level-4
- --compression-level-5
- --compression-level-6
- --compression-level-7
- --compression-level-8
- --cue
- --cuesheet
- -d
- --decode
- --decode-through-errors
- --delete-input-file
- -e
- --endian
- --exhaustive-model-search
- --explain
- -F
- -f
- --fast
- --force-aiff-format
- --force-raw-format
- --force
- -H
- -h
- --help
- --input-size
- -l
- --lax
- -M
- -m
- --max-lpc-order
- --mid-side
- --no-adaptive-mid-side
- --no-decode-through-errors
- --no-delete-input-file
- --no-escape-coding
- --no-exhaustive-model-search
- --no-lax
- --no-mid-side
- --no-ogg
- --no-padding
- --no-qlp-coeff-precision-search
- --no-residual-gnuplot
- --no-residual-text
- --no-sector-align
- --no-seektable
- --no-silent
- --no-verify
- --no-warnings-as-errors
- -o
- --ogg
- --output-name
- --output-prefix
- -P
- -p
- --padding
- --picture
- -q
- --qlp-coeff-precision
- --qlp-coeff-precision-search
- -r
- --replay-gain
- --residual-gnuplot
- --residual-text
- --rice-partition-order
- -S
- -s
- --sample-rate
- --sector-align
- --seekpoint
- --serial-number
- --sign
- --silent
- --skip
- --stdout
- -T
- -t
- --tag
- --tag-from-file
- --test
- --totally-silent
- --until
- -V
- -v
- --verify
- -w
- --warnings-as-errors
- --version
+ -0
+ -1
+ -2
+ -3
+ -4
+ -5
+ -6
+ -7
+ -8
+ -A
+ -a
+ --adaptive-mid-side
+ --analyze
+ --apodization
+ --apply-replaygain-which-is-not-lossless
+ -b
+ --best
+ --blocksize
+ --bps
+ -c
+ --channels
+ --compression-level-0
+ --compression-level-1
+ --compression-level-2
+ --compression-level-3
+ --compression-level-4
+ --compression-level-5
+ --compression-level-6
+ --compression-level-7
+ --compression-level-8
+ --cue
+ --cuesheet
+ -d
+ --decode
+ --decode-through-errors
+ --delete-input-file
+ -e
+ --endian
+ --exhaustive-model-search
+ --explain
+ -F
+ -f
+ --fast
+ --force-raw-format
+ --force-aiff-format
+ --force-rf64-format
+ --force-wave64-format
+ --force
+ -H
+ -h
+ --help
+ --ignore-chunk-sizes
+ --input-size
+ --keep-foreign-metadata
+ -l
+ --lax
+ -M
+ -m
+ --max-lpc-order
+ --mid-side
+ --no-adaptive-mid-side
+ --no-cued-seekpoints
+ --no-decode-through-errors
+ --no-delete-input-file
+ --no-escape-coding
+ --no-exhaustive-model-search
+ --no-keep-foreign-metadata
+ --no-lax
+ --no-mid-side
+ --no-ogg
+ --no-padding
+ --no-preserve-modtime
+ --no-qlp-coeff-prec-search
+ --no-residual-gnuplot
+ --no-residual-text
+ --no-sector-align
+ --no-seektable
+ --no-silent
+ --no-verify
+ --no-warnings-as-errors
+ --no-utf8-convert
+ -o
+ --ogg
+ --output-name
+ --output-prefix
+ -P
+ -p
+ --padding
+ --picture
+ -q
+ --qlp-coeff-precision
+ --qlp-coeff-precision-search
+ -r
+ --replay-gain
+ --residual-gnuplot
+ --residual-text
+ --rice-partition-order
+ -S
+ -s
+ --sample-rate
+ --sector-align
+ --seekpoint
+ --serial-number
+ --sign
+ --silent
+ --skip
+ --stdout
+ -T
+ -t
+ --tag
+ --tag-from-file
+ --test
+ --totally-silent
+ --until
+ -V
+ -v
+ --verify
+ -w
+ --warnings-as-errors
+ --version
@@ -1033,16 +1177,9 @@ - - -
- Copyright (c) 2000,2001,2002,2003,2004,2005,2006,2007 Josh Coalson - - SourceForge.net Logo - - CAFE Logo
-
- Valid XHTML 1.0! + Copyright (c) 2000-2009 Josh Coalson +
+ Copyright (c) 2011-2016 Xiph.Org Foundation