mirror of
https://github.com/claunia/cuetools.net.git
synced 2025-12-16 18:14:25 +00:00
Flake/FLACCL cmd line tools were forcing user to specify compression level,
because default comprssion level was not set properly in settings constructor.
This commit is contained in:
@@ -788,12 +788,12 @@ void clQuantizeLPC(
|
|||||||
atomic_or(shared.maxcoef + i, coef ^ (coef >> 31));
|
atomic_or(shared.maxcoef + i, coef ^ (coef >> 31));
|
||||||
barrier(CLK_LOCAL_MEM_FENCE);
|
barrier(CLK_LOCAL_MEM_FENCE);
|
||||||
|
|
||||||
int cbits = min(51 - 2 * clz(shared.task.blocksize), shared.task.abits);
|
int cbits = min(51 - 2 * clz(shared.task.blocksize), shared.task.abits) - minprecision + (i - ((i >> precisions) << precisions));
|
||||||
#if BITS_PER_SAMPLE <= 16
|
#if BITS_PER_SAMPLE <= 16
|
||||||
// Limit cbits so that 32-bit arithmetics will be enough when calculating residual
|
// Limit cbits so that 32-bit arithmetics will be enough when calculating residual
|
||||||
cbits = min(cbits, clz(order) + 1 - shared.task.obits);
|
cbits = min(cbits, clz(order) + 1 - shared.task.obits);
|
||||||
#endif
|
#endif
|
||||||
cbits = clamp(cbits - minprecision + (i - ((i >> precisions) << precisions)), 3, 15);
|
cbits = clamp(cbits, 3, 15);
|
||||||
|
|
||||||
// Calculate shift based on precision and number of leading zeroes in coeffs.
|
// Calculate shift based on precision and number of leading zeroes in coeffs.
|
||||||
// We know that if shifted by 15, coefs require
|
// We know that if shifted by 15, coefs require
|
||||||
|
|||||||
@@ -24,10 +24,17 @@ namespace CUETools.Codecs
|
|||||||
// Iterate through each property and call ResetValue()
|
// Iterate through each property and call ResetValue()
|
||||||
foreach (PropertyDescriptor property in TypeDescriptor.GetProperties(this))
|
foreach (PropertyDescriptor property in TypeDescriptor.GetProperties(this))
|
||||||
property.ResetValue(this);
|
property.ResetValue(this);
|
||||||
this.m_supported_modes = supported_modes;
|
if (default_mode == "")
|
||||||
this.m_default_mode = default_mode;
|
{
|
||||||
//GetSupportedModes(out m_default_mode);
|
GetSupportedModes(out default_mode);
|
||||||
this.EncoderMode = m_default_mode;
|
this.EncoderMode = default_mode;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
this.m_supported_modes = supported_modes;
|
||||||
|
this.m_default_mode = default_mode;
|
||||||
|
this.EncoderMode = m_default_mode;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
protected string m_supported_modes;
|
protected string m_supported_modes;
|
||||||
|
|||||||
@@ -36,7 +36,7 @@
|
|||||||
<DebugSymbols>true</DebugSymbols>
|
<DebugSymbols>true</DebugSymbols>
|
||||||
<DebugType>full</DebugType>
|
<DebugType>full</DebugType>
|
||||||
<Optimize>false</Optimize>
|
<Optimize>false</Optimize>
|
||||||
<OutputPath>..\bin\win32\Debug\</OutputPath>
|
<OutputPath>..\bin\Debug\</OutputPath>
|
||||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
<ErrorReport>prompt</ErrorReport>
|
<ErrorReport>prompt</ErrorReport>
|
||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
|
|||||||
@@ -200,7 +200,7 @@ namespace CUETools.FLACCL.cmd
|
|||||||
}
|
}
|
||||||
if (!quiet)
|
if (!quiet)
|
||||||
{
|
{
|
||||||
Console.WriteLine("{0}, Copyright (C) 2010 Grigory Chudov.", FLACCLWriter.Vendor);
|
Console.WriteLine("{0}, Copyright (C) 2010-2013 Grigory Chudov.", FLACCLWriter.Vendor);
|
||||||
Console.WriteLine("This is free software under the GNU GPLv3+ license; There is NO WARRANTY, to");
|
Console.WriteLine("This is free software under the GNU GPLv3+ license; There is NO WARRANTY, to");
|
||||||
Console.WriteLine("the extent permitted by law. <http://www.gnu.org/licenses/> for details.");
|
Console.WriteLine("the extent permitted by law. <http://www.gnu.org/licenses/> for details.");
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user