mirror of
https://github.com/claunia/cuetools.net.git
synced 2025-12-16 18:14:25 +00:00
This commit is contained in:
@@ -27,6 +27,28 @@
|
|||||||
<ErrorReport>prompt</ErrorReport>
|
<ErrorReport>prompt</ErrorReport>
|
||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<OutputPath>..\bin\win32\Debug\</OutputPath>
|
||||||
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<PlatformTarget>x86</PlatformTarget>
|
||||||
|
<CodeAnalysisRuleAssemblies>C:\Program Files (x86)\Microsoft Visual Studio 8\Team Tools\Static Analysis Tools\FxCop\\rules</CodeAnalysisRuleAssemblies>
|
||||||
|
<CodeAnalysisUseTypeNameInSuppression>true</CodeAnalysisUseTypeNameInSuppression>
|
||||||
|
<CodeAnalysisModuleSuppressionsFile>GlobalSuppressions.cs</CodeAnalysisModuleSuppressionsFile>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
|
||||||
|
<OutputPath>..\bin\win32\Release\</OutputPath>
|
||||||
|
<DefineConstants>TRACE</DefineConstants>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<PlatformTarget>x86</PlatformTarget>
|
||||||
|
<CodeAnalysisRuleAssemblies>C:\Program Files (x86)\Microsoft Visual Studio 8\Team Tools\Static Analysis Tools\FxCop\\rules</CodeAnalysisRuleAssemblies>
|
||||||
|
<CodeAnalysisUseTypeNameInSuppression>true</CodeAnalysisUseTypeNameInSuppression>
|
||||||
|
<CodeAnalysisModuleSuppressionsFile>GlobalSuppressions.cs</CodeAnalysisModuleSuppressionsFile>
|
||||||
|
<ErrorReport>prompt</ErrorReport>
|
||||||
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Data" />
|
<Reference Include="System.Data" />
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ namespace CUETools.FlakeExe
|
|||||||
Console.WriteLine("Options:");
|
Console.WriteLine("Options:");
|
||||||
Console.WriteLine();
|
Console.WriteLine();
|
||||||
Console.WriteLine(" -0 .. -11 Compression level, default 5.");
|
Console.WriteLine(" -0 .. -11 Compression level, default 5.");
|
||||||
Console.WriteLine(" -o <file> Output filename, or \"-\" for stdout.");
|
Console.WriteLine(" -o <file> Output filename, or \"-\" for stdout, or nul.");
|
||||||
Console.WriteLine(" -p # Padding bytes.");
|
Console.WriteLine(" -p # Padding bytes.");
|
||||||
Console.WriteLine(" -q --quiet Quiet mode.");
|
Console.WriteLine(" -q --quiet Quiet mode.");
|
||||||
Console.WriteLine(" --verify Verify during encoding.");
|
Console.WriteLine(" --verify Verify during encoding.");
|
||||||
@@ -26,7 +26,7 @@ namespace CUETools.FlakeExe
|
|||||||
Console.WriteLine("Advanced Options:");
|
Console.WriteLine("Advanced Options:");
|
||||||
Console.WriteLine();
|
Console.WriteLine();
|
||||||
Console.WriteLine(" -b # Block size.");
|
Console.WriteLine(" -b # Block size.");
|
||||||
Console.WriteLine(" -v # VBR mode.");
|
Console.WriteLine(" -v # Variable block size mode (0,4).");
|
||||||
Console.WriteLine(" -t <type> Prediction type (fixed,levinson,search).");
|
Console.WriteLine(" -t <type> Prediction type (fixed,levinson,search).");
|
||||||
Console.WriteLine(" -s <method> Stereo decorrelation (independent,estimate,evaluate,search).");
|
Console.WriteLine(" -s <method> Stereo decorrelation (independent,estimate,evaluate,search).");
|
||||||
Console.WriteLine(" -r #[,#] Rice partition order {max} or {min},{max} (0..8).");
|
Console.WriteLine(" -r #[,#] Rice partition order {max} or {min},{max} (0..8).");
|
||||||
@@ -112,8 +112,8 @@ namespace CUETools.FlakeExe
|
|||||||
}
|
}
|
||||||
else if (args[arg] == "--max-precision" && ++arg < args.Length)
|
else if (args[arg] == "--max-precision" && ++arg < args.Length)
|
||||||
ok = int.TryParse(args[arg], out max_precision);
|
ok = int.TryParse(args[arg], out max_precision);
|
||||||
else if ((args[arg] == "-v" || args[arg] == "--vbr") && ++arg < args.Length)
|
else if ((args[arg] == "-v" || args[arg] == "--vbr"))
|
||||||
ok = int.TryParse(args[arg], out vbr_mode);
|
ok = (++arg < args.Length) && int.TryParse(args[arg], out vbr_mode);
|
||||||
else if ((args[arg] == "-b" || args[arg] == "--blocksize") && ++arg < args.Length)
|
else if ((args[arg] == "-b" || args[arg] == "--blocksize") && ++arg < args.Length)
|
||||||
ok = int.TryParse(args[arg], out blocksize);
|
ok = int.TryParse(args[arg], out blocksize);
|
||||||
else if ((args[arg] == "-p" || args[arg] == "--padding") && ++arg < args.Length)
|
else if ((args[arg] == "-p" || args[arg] == "--padding") && ++arg < args.Length)
|
||||||
@@ -166,39 +166,49 @@ namespace CUETools.FlakeExe
|
|||||||
IAudioDest audioDest = new BufferedWriter(flake, 512 * 1024);
|
IAudioDest audioDest = new BufferedWriter(flake, 512 * 1024);
|
||||||
int[,] buff = new int[0x10000, audioSource.ChannelCount];
|
int[,] buff = new int[0x10000, audioSource.ChannelCount];
|
||||||
|
|
||||||
if (level >= 0)
|
try
|
||||||
flake.CompressionLevel = level;
|
{
|
||||||
if (prediction_type != null)
|
if (level >= 0)
|
||||||
flake.PredictionType = Flake.LookupPredictionType(prediction_type);
|
flake.CompressionLevel = level;
|
||||||
if (stereo_method != null)
|
if (prediction_type != null)
|
||||||
flake.StereoMethod = Flake.LookupStereoMethod(stereo_method);
|
flake.PredictionType = Flake.LookupPredictionType(prediction_type);
|
||||||
if (order_method != null)
|
if (stereo_method != null)
|
||||||
flake.OrderMethod = Flake.LookupOrderMethod(order_method);
|
flake.StereoMethod = Flake.LookupStereoMethod(stereo_method);
|
||||||
if (window_function != null)
|
if (order_method != null)
|
||||||
flake.WindowFunction = Flake.LookupWindowFunction(window_function);
|
flake.OrderMethod = Flake.LookupOrderMethod(order_method);
|
||||||
if (min_partition_order >= 0)
|
if (window_function != null)
|
||||||
flake.MinPartitionOrder = min_partition_order;
|
flake.WindowFunction = Flake.LookupWindowFunction(window_function);
|
||||||
if (max_partition_order >= 0)
|
if (min_partition_order >= 0)
|
||||||
flake.MaxPartitionOrder = max_partition_order;
|
flake.MinPartitionOrder = min_partition_order;
|
||||||
if (min_lpc_order >= 0)
|
if (max_partition_order >= 0)
|
||||||
flake.MinLPCOrder = min_lpc_order;
|
flake.MaxPartitionOrder = max_partition_order;
|
||||||
if (max_lpc_order >= 0)
|
if (min_lpc_order >= 0)
|
||||||
flake.MaxLPCOrder = max_lpc_order;
|
flake.MinLPCOrder = min_lpc_order;
|
||||||
if (min_fixed_order >= 0)
|
if (max_lpc_order >= 0)
|
||||||
flake.MinFixedOrder = min_fixed_order;
|
flake.MaxLPCOrder = max_lpc_order;
|
||||||
if (max_fixed_order >= 0)
|
if (min_fixed_order >= 0)
|
||||||
flake.MaxFixedOrder = max_fixed_order;
|
flake.MinFixedOrder = min_fixed_order;
|
||||||
if (max_precision >= 0)
|
if (max_fixed_order >= 0)
|
||||||
flake.MaxPrecisionSearch = max_precision;
|
flake.MaxFixedOrder = max_fixed_order;
|
||||||
if (blocksize >= 0)
|
if (max_precision >= 0)
|
||||||
flake.BlockSize = blocksize;
|
flake.MaxPrecisionSearch = max_precision;
|
||||||
if (padding >= 0)
|
if (blocksize >= 0)
|
||||||
flake.PaddingLength = padding;
|
flake.BlockSize = blocksize;
|
||||||
if (vbr_mode >= 0)
|
if (padding >= 0)
|
||||||
flake.VBRMode = vbr_mode;
|
flake.PaddingLength = padding;
|
||||||
flake.DoMD5 = do_md5;
|
if (vbr_mode >= 0)
|
||||||
flake.DoSeekTable = do_seektable;
|
flake.VBRMode = vbr_mode;
|
||||||
flake.DoVerify = do_verify;
|
flake.DoMD5 = do_md5;
|
||||||
|
flake.DoSeekTable = do_seektable;
|
||||||
|
flake.DoVerify = do_verify;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
Usage();
|
||||||
|
Console.WriteLine("");
|
||||||
|
Console.WriteLine("Error: {0}.", ex.Message);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (!quiet)
|
if (!quiet)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user