Encoding: flac [-s] [--skip #] [-V] [<I><A HREF="#format_options"><format-options></A></I>] [<I><A HREF="#encoding_options"><encoding options></A></I>] [inputfile [...]]
</LI>
<LI>
- Decoding: flac -d [-s] [--skip #] [<I><A HREF="#format_options"><format-options></A></I>] [inputfile [...]]
+ Decoding: flac -d [-s] [--skip #] [-F] [<I><A HREF="#format_options"><format-options></A></I>] [inputfile [...]]
</LI>
<LI>
Testing: flac -t [-s] [inputfile [...]]
<TABLE WIDTH="100%" BORDER="1" BGCOLOR="#EEEED4">
<TR>
<TD COLSPAN="2" BGCOLOR="#D3D4C5">
+ <A NAME="decoding_options"><FONT SIZE="+1"><B>Decoding Options</B></FONT></A>
+ </TD>
+ </TR>
+ <TR>
+ <TD NOWRAP ALIGN="RIGHT" VALIGN="TOP" BGCOLOR="#F4F4CC">
+ <TT>-F</TT>
+ </TD>
+ <TD>
+ By default <B><TT>flac</TT></B> stops decoding with an error and removes the partially decoded file if it encounters a bitstream error. With <TT>-F</TT>, errors are still printed but <B><TT>flac</TT></B> will continue decoding to completion. Note that errors may cause the decoded audio to be missing some samples or have silent sections.
+ </TD>
+ </TR>
+ </TABLE>
+ </TD></TR></TABLE>
+ </P>
+ <P>
+ <TABLE WIDTH="100%" BORDER="0" CELLSPACING="0" CELLPADDING="0" BGCOLOR="#EEEED4"><TR><TD>
+ <TABLE WIDTH="100%" BORDER="1" BGCOLOR="#EEEED4">
+ <TR>
+ <TD COLSPAN="2" BGCOLOR="#D3D4C5">
<A NAME="encoding_options"><FONT SIZE="+1"><B>Encoding Options</B></FONT></A>
</TD>
</TR>
</TR>
<TR>
<TD NOWRAP ALIGN="RIGHT" VALIGN="TOP" BGCOLOR="#F4F4CC">
- <TT>-R #</TT>
- </TD>
- <TD>
- Set the Rice parameter search distance. Defaults to 0. The residual coder will search for the best Rice parameter +/- this number for each residual partition. This option is expensive (run time for -R n will typically be (2n)*30% over that of -R 0) and doesn't give much of a gain. As a matter of fact, none of the -0..-8 options currently use it since -R > 1 is not consistently better like it should be.
- </TD>
- </TR>
- <TR>
- <TD NOWRAP ALIGN="RIGHT" VALIGN="TOP" BGCOLOR="#F4F4CC">
<TT>-V</TT>
</TD>
<TD>
<TD NOWRAP ALIGN="RIGHT" VALIGN="TOP" BGCOLOR="#F4F4CC">
</TD>
<TD>
- <TT>-S-</TT>, <TT>-P-</TT>, <TT>-m-</TT>, <TT>-e-</TT>, <TT>-E-</TT>, <TT>-p-</TT>, <TT>-V-</TT>, <TT>--delete-input-file-</TT>, <TT>--lax-</TT>, <TT>--sector-align-</TT> can all be used to turn off a particular option.
+ <TT>-F-</TT>, <TT>-S-</TT>, <TT>-P-</TT>, <TT>-m-</TT>, <TT>-e-</TT>, <TT>-E-</TT>, <TT>-p-</TT>, <TT>-V-</TT>, <TT>--delete-input-file-</TT>, <TT>--lax-</TT>, <TT>--sector-align-</TT> can all be used to turn off a particular option.
</TD>
</TR>
</TABLE>
<!ENTITY dhfirstname "<firstname>Matt</firstname>">
<!ENTITY dhsurname "<surname>Zimmerman</surname>">
<!-- Please adjust the date whenever revising the manpage. -->
- <!ENTITY dhdate "<date>May 16, 2002</date>">
+ <!ENTITY dhdate "<date>June 04, 2002</date>">
<!-- SECTION should be 1-8, maybe w/ subsection other parameters are
allowed: see man(7), man(1). -->
<!ENTITY dhsection "<manvolnum>1</manvolnum>">
</refsect2>
<refsect2>
+ <title>Decoding Options</title>
+
+ <variablelist>
+ <varlistentry>
+ <term><option>-F</option>
+ </term>
+ <listitem>
+ <para>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.</para>
+ </listitem>
+ </varlistentry>
+
+ </variablelist>
+ </refsect2>
+
+ <refsect2>
<title>Encoding Options</title>
<variablelist>
</varlistentry>
<varlistentry>
- <term><option>-R</option> <replaceable>#</replaceable></term>
-
- <listitem>
- <para>Set the Rice parameter search distance.
- Default is 0.</para>
- </listitem>
- </varlistentry>
-
- <varlistentry>
<term><option>-V</option></term>
<listitem>
</varlistentry>
<varlistentry>
- <term><option>-S-</option> <option>-P-</option> <option>-m-</option> <option>-M-</option> <option>-e-</option> <option>-E-</option> <option>-p-</option> <option>-V-</option> <option>--delete-input-file-</option> <option>--lax-</option> <option>--ogg-</option>
+ <term><option>-F-</option> <option>-S-</option> <option>-P-</option> <option>-m-</option> <option>-M-</option> <option>-e-</option> <option>-E-</option> <option>-p-</option> <option>-V-</option> <option>--delete-input-file-</option> <option>--lax-</option> <option>--ogg-</option>
</term>
<listitem>
static int encode_file(const char *infilename, const char *forced_outfilename, FLAC__bool is_last_file);
static int decode_file(const char *infilename, const char *forced_outfilename);
-FLAC__bool verify = false, verbose = true, lax = false, test_only = false, analyze = false, use_ogg = false;
+FLAC__bool verify = false, verbose = true, continue_through_decode_errors = false, lax = false, test_only = false, analyze = false, use_ogg = false;
FLAC__bool do_mid_side = true, loose_mid_side = false, do_exhaustive_model_search = false, do_escape_coding = false, do_qlp_coeff_prec_search = false;
FLAC__bool force_to_stdout = false, force_raw_format = false, delete_input = false, sector_align = false;
const char *cmdline_forced_outfilename = 0, *output_prefix = 0;
}
else if(0 == strcmp(argv[i], "-c"))
force_to_stdout = true;
+ else if(0 == strcmp(argv[i], "-F"))
+ continue_through_decode_errors = true;
+ else if(0 == strcmp(argv[i], "-F-"))
+ continue_through_decode_errors = false;
else if(0 == strcmp(argv[i], "-s"))
verbose = false;
else if(0 == strcmp(argv[i], "-s-"))
max_residual_partition_order = atoi(++p);
}
}
- else if(0 == strcmp(argv[i], "-R")) {
+ else if(0 == strcmp(argv[i], "--old-unworking-do-not-use-R")) {
if(++i >= argc)
return long_usage("ERROR: must specify a value with -R\n");
rice_parameter_search_dist = atoi(argv[i]);
fprintf(out, "analyze options:\n");
fprintf(out, " --a-rtext : include residual signal in text output\n");
fprintf(out, " --a-rgp : generate gnuplot files of residual distribution of each subframe\n");
+ fprintf(out, "decoding options:\n");
+ fprintf(out, " -F : force decoder to continue decoding through stream errors\n");
fprintf(out, "encoding options:\n");
#ifdef FLAC__HAS_OGG
fprintf(out, " --ogg : output Ogg-FLAC stream instead of native FLAC\n");
fprintf(out, " 0 => let encoder decide (min is %u, default is -q 0)\n", FLAC__MIN_QLP_COEFF_PRECISION);
fprintf(out, " -r [#,]# : [min,]max residual partition order (# is 0..16; min defaults to 0;\n");
fprintf(out, " default is -r 0; above 4 doesn't usually help much)\n");
+#if 0
+@@@ removed because it doesnt work yet and is too dangerous for users
fprintf(out, " -R # : Rice parameter search distance (# is 0..32; above 2 doesn't help much)\n");
+#endif
fprintf(out, " -V : verify a correct encoding by decoding the output in parallel and\n");
fprintf(out, " comparing to the original\n");
fprintf(out, " -S-, -P-, -m-, -M-, -e-, -E-, -p-, -V-, --delete-input-file-,%s --lax-,\n",
#endif
common_options.verbose = verbose;
+ common_options.continue_through_decode_errors = continue_through_decode_errors;
#ifdef FLAC__HAS_OGG
common_options.is_ogg = treat_as_ogg;
#endif