1) Fixed crash on source files that contain zero length tags

2) Fixed a glitch in filename corrector - it sometimes didn't replace underscores with spaces.
3) Fixed a bug when a broken cue sheet was created if artist, title or genre contained comma character.
3) Added .zip archive support
4) Added support for cue sheets which start with data track (mixed mode or "playstation type" cds)
This commit is contained in:
chudov
2009-01-28 04:53:13 +00:00
parent 0d86e75067
commit 3d94188f92
34 changed files with 3122 additions and 1567 deletions

View File

@@ -445,7 +445,8 @@ namespace APETagsDotNet
// remove a specific field // remove a specific field
void RemoveField(string pFieldName) void RemoveField(string pFieldName)
{ {
RemoveField(GetTagFieldIndex(pFieldName)); int idx = GetTagFieldIndex(pFieldName);
if (idx >= 0) RemoveField(idx);
} }
void RemoveField(int nIndex) void RemoveField(int nIndex)

View File

@@ -39,7 +39,7 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
<OutputPath>bin\win32\Release\</OutputPath> <OutputPath>..\bin\win32\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants> <DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize> <Optimize>true</Optimize>
<DebugType>pdbonly</DebugType> <DebugType>pdbonly</DebugType>
@@ -61,7 +61,7 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x64' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x64' ">
<OutputPath>bin\x64\Release\</OutputPath> <OutputPath>..\bin\x64\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants> <DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize> <Optimize>true</Optimize>
<DebugType>pdbonly</DebugType> <DebugType>pdbonly</DebugType>

BIN
CUERipper/cddb.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 318 B

BIN
CUERipper/freedb.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

View File

@@ -345,11 +345,24 @@ namespace CUERipper
code = m_freedb.Read(queryResult, out cdEntry); code = m_freedb.Read(queryResult, out cdEntry);
if (code == FreedbHelper.ResponseCodes.CODE_210) if (code == FreedbHelper.ResponseCodes.CODE_210)
{ {
Encoding iso = Encoding.GetEncoding("iso-8859-1");
ReleaseInfo r = CreateCUESheet(audioSource, null, cdEntry); ReleaseInfo r = CreateCUESheet(audioSource, null, cdEntry);
this.BeginInvoke((MethodInvoker)delegate() this.BeginInvoke((MethodInvoker)delegate()
{ {
comboRelease.Items.Add(r); comboRelease.Items.Add(r);
}); });
if (Encoding.Default.GetString(iso.GetBytes(cdEntry.Title)) != cdEntry.Title)
{
cdEntry.Artist = Encoding.Default.GetString(iso.GetBytes(cdEntry.Artist));
cdEntry.Title = Encoding.Default.GetString(iso.GetBytes(cdEntry.Title));
for (int i = 0; i < cdEntry.Tracks.Count; i++)
cdEntry.Tracks[i].Title = Encoding.Default.GetString(iso.GetBytes(cdEntry.Tracks[i].Title));
r = CreateCUESheet(audioSource, null, cdEntry);
this.BeginInvoke((MethodInvoker)delegate()
{
comboRelease.Items.Add(r);
});
}
} }
} }
else else
@@ -478,7 +491,8 @@ namespace CUERipper
if (comboRelease.Items[e.Index] is ReleaseInfo) if (comboRelease.Items[e.Index] is ReleaseInfo)
{ {
Bitmap ImageToDraw = ((ReleaseInfo)comboRelease.Items[e.Index]).bitmap; Bitmap ImageToDraw = ((ReleaseInfo)comboRelease.Items[e.Index]).bitmap;
e.Graphics.DrawImage(ImageToDraw, new Rectangle(e.Bounds.X, e.Bounds.Y, e.Bounds.Height, e.Bounds.Height)); if (ImageToDraw != null)
e.Graphics.DrawImage(ImageToDraw, new Rectangle(e.Bounds.X, e.Bounds.Y, e.Bounds.Height, e.Bounds.Height));
//e.Graphics.DrawImage(ImageToDraw, new Rectangle(e.Bounds.X + e.Bounds.Width - ImageToDraw.Width, e.Bounds.Y, ImageToDraw.Width, e.Bounds.Height)); //e.Graphics.DrawImage(ImageToDraw, new Rectangle(e.Bounds.X + e.Bounds.Width - ImageToDraw.Width, e.Bounds.Y, ImageToDraw.Width, e.Bounds.Height));
} }
e.Graphics.DrawString(text, e.Font, new SolidBrush(e.ForeColor), new RectangleF((float)e.Bounds.X + e.Bounds.Height, (float)e.Bounds.Y, (float)(e.Bounds.Width - e.Bounds.Height), (float)e.Bounds.Height), format); e.Graphics.DrawString(text, e.Font, new SolidBrush(e.ForeColor), new RectangleF((float)e.Bounds.X + e.Bounds.Height, (float)e.Bounds.Y, (float)(e.Bounds.Width - e.Bounds.Height), (float)e.Bounds.Height), format);

View File

@@ -17,6 +17,9 @@ namespace CUETools.AccurateRip
_toc = toc; _toc = toc;
_accDisks = new List<AccDisk>(); _accDisks = new List<AccDisk>();
_crc32 = new Crc32(); _crc32 = new Crc32();
_CRCLOG = new uint[_toc.AudioTracks + 1];
for (int i = 0; i <= _toc.AudioTracks; i++)
_CRCLOG[i] = 0;
Init(); Init();
} }
@@ -131,7 +134,7 @@ namespace CUETools.AccurateRip
{ {
CRCs[i] += baseSum; CRCs[i] += baseSum;
baseSum -= stepSum; baseSum -= stepSum;
//CRC32[i] = _crc32.ComputeChecksum (CRC32[i], samples, count); //_offsetedCRC32[i] = _crc32.ComputeChecksum (CRC32[i], samples, count);
} }
} }
} }
@@ -153,7 +156,22 @@ namespace CUETools.AccurateRip
public uint CRC32(int iTrack) public uint CRC32(int iTrack)
{ {
return _offsetedCRC32[iTrack] ^ 0xffffffff; return _CRC32[iTrack] ^ 0xffffffff;
}
public uint CRCWONULL(int iTrack)
{
return _CRCWONULL[iTrack] ^ 0xffffffff;
}
public uint CRCLOG(int iTrack)
{
return _CRCLOG[iTrack];
}
public void CRCLOG(int iTrack, uint value)
{
_CRCLOG[iTrack] = value;
} }
public uint CRC450(int iTrack, int oi) public uint CRC450(int iTrack, int oi)
@@ -170,11 +188,11 @@ namespace CUETools.AccurateRip
{ {
fixed (int* pSampleBuff = &sampleBuffer[pos, 0]) fixed (int* pSampleBuff = &sampleBuffer[pos, 0])
{ {
if (_currentTrack != 0) if (_currentTrack > 0)
{ {
uint trackLength = _toc[_currentTrack].Length * 588; uint trackLength = _toc[_currentTrack + _toc.FirstAudio - 1].Length * 588;
uint currentOffset = (uint)_sampleCount - _toc[_currentTrack].Start * 588; uint currentOffset = (uint)_sampleCount - _toc[_currentTrack + _toc.FirstAudio - 1].Start * 588;
uint previousOffset = _currentTrack > 1 ? _toc[_currentTrack - 1].Length * 588 : _toc.Pregap * 588; uint previousOffset = _currentTrack > 1 ? _toc[_currentTrack + _toc.FirstAudio - 2].Length * 588 : _toc[_toc.FirstAudio].Pregap * 588;
uint si1 = (uint)Math.Min(copyCount, Math.Max(0, 588 * (_currentTrack == 1 ? 10 : 5) - (int)currentOffset)); uint si1 = (uint)Math.Min(copyCount, Math.Max(0, 588 * (_currentTrack == 1 ? 10 : 5) - (int)currentOffset));
uint si2 = (uint)Math.Min(copyCount, Math.Max(si1, trackLength - (int)currentOffset - 588 * (_currentTrack == _toc.AudioTracks ? 10 : 5))); uint si2 = (uint)Math.Min(copyCount, Math.Max(si1, trackLength - (int)currentOffset - 588 * (_currentTrack == _toc.AudioTracks ? 10 : 5)));
if (_currentTrack == 1) if (_currentTrack == 1)
@@ -188,9 +206,11 @@ namespace CUETools.AccurateRip
else else
CalculateAccurateRipCRCsSemifast(pSampleBuff + si2 * 2, copyCount - si2, _currentTrack - 1, currentOffset + si2, previousOffset, trackLength); CalculateAccurateRipCRCsSemifast(pSampleBuff + si2 * 2, copyCount - si2, _currentTrack - 1, currentOffset + si2, previousOffset, trackLength);
_offsetedCRC32[_currentTrack] = _crc32.ComputeChecksum(_offsetedCRC32[_currentTrack], pSampleBuff, copyCount); _CRC32[_currentTrack] = _crc32.ComputeChecksum(_CRC32[_currentTrack], pSampleBuff, copyCount);
_CRCWONULL[_currentTrack] = _crc32.ComputeChecksumWONULL(_CRCWONULL[_currentTrack], pSampleBuff, copyCount);
} }
_offsetedCRC32[0] = _crc32.ComputeChecksum(_offsetedCRC32[0], pSampleBuff, copyCount); _CRC32[0] = _crc32.ComputeChecksum(_CRC32[0], pSampleBuff, copyCount);
_CRCWONULL[0] = _crc32.ComputeChecksumWONULL(_CRCWONULL[0], pSampleBuff, copyCount);
} }
} }
pos += copyCount; pos += copyCount;
@@ -204,12 +224,16 @@ namespace CUETools.AccurateRip
{ {
_offsetedCRC = new uint[_toc.AudioTracks, 10 * 588]; _offsetedCRC = new uint[_toc.AudioTracks, 10 * 588];
_offsetedFrame450CRC = new uint[_toc.AudioTracks, 10 * 588]; _offsetedFrame450CRC = new uint[_toc.AudioTracks, 10 * 588];
_offsetedCRC32 = new uint[_toc.AudioTracks + 1]; _CRC32 = new uint[_toc.AudioTracks + 1];
_CRCWONULL = new uint[_toc.AudioTracks + 1];
for (int i = 0; i <= _toc.AudioTracks; i++) for (int i = 0; i <= _toc.AudioTracks; i++)
_offsetedCRC32[i] = 0xffffffff; {
_CRC32[i] = 0xffffffff;
_CRCWONULL[i] = 0xffffffff;
}
_currentTrack = 0; _currentTrack = 0;
_sampleCount = 0; _sampleCount = _toc[_toc.FirstAudio][0].Start * 588;
_samplesRemTrack = _toc.Pregap * 588; _samplesRemTrack = _toc[_toc.FirstAudio].Pregap * 588;
CheckPosition(); CheckPosition();
} }
@@ -226,7 +250,7 @@ namespace CUETools.AccurateRip
{ {
if (++_currentTrack > _toc.AudioTracks) if (++_currentTrack > _toc.AudioTracks)
return; return;
_samplesRemTrack = _toc[_currentTrack].Length * 588; _samplesRemTrack = _toc[_currentTrack + _toc.FirstAudio - 1].Length * 588;
} }
} }
@@ -438,10 +462,10 @@ namespace CUETools.AccurateRip
if (CRC32(0) != 0) if (CRC32(0) != 0)
{ {
sw.WriteLine(""); sw.WriteLine("");
sw.WriteLine("Track\t[ CRC32 ]"); sw.WriteLine("Track\t[ CRC32 ]\t[W/O NULL]\t[ LOG ]");
sw.WriteLine(String.Format(" --\t[{0:X8}]", CRC32(0))); sw.WriteLine(String.Format(" --\t[{0:X8}]\t[{1:X8}]\t{2:10}", CRC32(0), CRCWONULL(0), CRCLOG(0) == CRC32(0) ? " CRC32 " : CRCLOG(0) == CRCWONULL(0) ? " W/O NULL " : CRCLOG(0) == 0 ? "" : String.Format("[{0:X8}]", CRCLOG(0))));
for (int iTrack = 1; iTrack <= _toc.AudioTracks; iTrack++) for (int iTrack = 1; iTrack <= _toc.AudioTracks; iTrack++)
sw.WriteLine(String.Format(" {0:00}\t[{1:X8}]", iTrack, CRC32(iTrack))); sw.WriteLine(String.Format(" {0:00}\t[{1:X8}]\t[{2:X8}]\t{3:10}", iTrack, CRC32(iTrack), CRCWONULL(iTrack), CRCLOG(iTrack) == CRC32(iTrack) ? " CRC32 " : CRCLOG(iTrack) == CRCWONULL(iTrack) ? " W/O NULL " : CRCLOG(iTrack) == 0 ? "" : String.Format("[{0:X8}]", CRCLOG(iTrack))));
} }
} }
@@ -544,14 +568,16 @@ namespace CUETools.AccurateRip
// Calculate the three disc ids used by AR // Calculate the three disc ids used by AR
uint discId1 = 0; uint discId1 = 0;
uint discId2 = 0; uint discId2 = 0;
uint num = 0;
for (int iTrack = 1; iTrack <= toc.TrackCount; iTrack++) for (int iTrack = 1; iTrack <= toc.TrackCount; iTrack++)
if (toc[iTrack].IsAudio) if (toc[iTrack].IsAudio)
{ {
discId1 += toc[iTrack].Start; discId1 += toc[iTrack].Start;
discId2 += Math.Max(toc[iTrack].Start, 1) * toc[iTrack].Number; discId2 += Math.Max(toc[iTrack].Start, 1) * (++num);
} }
discId1 += toc.Length; discId1 += toc.Length;
discId2 += Math.Max(toc.Length, 1) * ((uint)toc.AudioTracks + 1); discId2 += Math.Max(toc.Length, 1) * (++num);
discId1 &= 0xFFFFFFFF; discId1 &= 0xFFFFFFFF;
discId2 &= 0xFFFFFFFF; discId2 &= 0xFFFFFFFF;
return string.Format("{0:x8}-{1:x8}-{2}", discId1, discId2, CalculateCDDBId(toc).ToLower()); return string.Format("{0:x8}-{1:x8}-{2}", discId1, discId2, CalculateCDDBId(toc).ToLower());
@@ -590,7 +616,7 @@ namespace CUETools.AccurateRip
private HttpStatusCode _accResult; private HttpStatusCode _accResult;
private uint[,] _offsetedCRC; private uint[,] _offsetedCRC;
private uint[,] _offsetedFrame450CRC; private uint[,] _offsetedFrame450CRC;
private uint[] _offsetedCRC32; private uint[] _CRC32, _CRCWONULL, _CRCLOG;
private uint[] _backupCRC; private uint[] _backupCRC;
Crc32 _crc32; Crc32 _crc32;

View File

@@ -241,6 +241,7 @@ namespace CUETools.CDImage
{ {
_catalog = src._catalog; _catalog = src._catalog;
_audioTracks = src._audioTracks; _audioTracks = src._audioTracks;
_firstAudio = src._firstAudio;
_tracks = new List<CDTrack>(); _tracks = new List<CDTrack>();
for (int i = 0; i < src.TrackCount; i++) for (int i = 0; i < src.TrackCount; i++)
_tracks.Add(new CDTrack(src._tracks[i])); _tracks.Add(new CDTrack(src._tracks[i]));
@@ -287,7 +288,15 @@ namespace CUETools.CDImage
{ {
get get
{ {
return _audioTracks; return (uint) _audioTracks;
}
}
public int FirstAudio
{
get
{
return _firstAudio + 1;
} }
} }
@@ -295,7 +304,7 @@ namespace CUETools.CDImage
{ {
get get
{ {
return AudioTracks > 0 ? _tracks[(int)_audioTracks - 1].End + 1U : 0U; return AudioTracks > 0 ? _tracks[_firstAudio + _audioTracks - 1].End + 1U - _tracks[_firstAudio].Start + _tracks[_firstAudio].Pregap : 0U;
} }
} }
@@ -329,7 +338,11 @@ namespace CUETools.CDImage
{ {
_tracks.Add(track); _tracks.Add(track);
if (track.IsAudio) if (track.IsAudio)
{
_audioTracks++; _audioTracks++;
if (!_tracks[_firstAudio].IsAudio)
_firstAudio = _tracks.Count - 1;
}
} }
public uint IndexLength(int iTrack, int iIndex) public uint IndexLength(int iTrack, int iIndex)
@@ -372,6 +385,7 @@ namespace CUETools.CDImage
string _catalog; string _catalog;
IList<CDTrack> _tracks; IList<CDTrack> _tracks;
uint _audioTracks; int _audioTracks;
int _firstAudio;
} }
} }

View File

@@ -131,6 +131,43 @@ namespace CUETools.Codecs
} }
} }
public static unsafe void BytesToFLACSamples_24(byte[] inSamples, int inByteOffset,
int[,] outSamples, int outSampleOffset, uint sampleCount, int channelCount, int wastedBits)
{
uint loopCount = sampleCount * (uint)channelCount;
if ((inSamples.Length - inByteOffset < loopCount * 3) ||
(outSamples.GetLength(0) - outSampleOffset < sampleCount))
throw new IndexOutOfRangeException();
fixed (byte* pInSamplesFixed = &inSamples[inByteOffset])
{
fixed (int* pOutSamplesFixed = &outSamples[outSampleOffset, 0])
{
byte* pInSamples = (byte*)pInSamplesFixed;
int* pOutSamples = pOutSamplesFixed;
for (int i = 0; i < loopCount; i++)
{
int sample = (int)*(pInSamples++);
sample += (int)*(pInSamples++) << 8;
sample += (int)*(pInSamples++) << 16;
*(pOutSamples++) = (sample << 8) >> (8 + wastedBits);
}
}
}
}
public static unsafe void BytesToFLACSamples(byte[] inSamples, int inByteOffset,
int[,] outSamples, int outSampleOffset, uint sampleCount, int channelCount, int bitsPerSample)
{
if (bitsPerSample == 16)
AudioSamples.BytesToFLACSamples_16(inSamples, inByteOffset, outSamples, outSampleOffset, sampleCount, channelCount);
else if (bitsPerSample > 16 && bitsPerSample <= 24)
AudioSamples.BytesToFLACSamples_24(inSamples, inByteOffset, outSamples, outSampleOffset, sampleCount, channelCount, 24 - bitsPerSample);
else
throw new Exception("Unsupported bitsPerSample value");
}
public static int[,] Read(IAudioSource source, int[,] buff) public static int[,] Read(IAudioSource source, int[,] buff)
{ {
if (source.Remaining == 0) return null; if (source.Remaining == 0) return null;
@@ -527,8 +564,8 @@ namespace CUETools.Codecs
_sampleBuffer = new byte[byteCount]; _sampleBuffer = new byte[byteCount];
if (_IO.Read(_sampleBuffer, 0, (int)byteCount) != byteCount) if (_IO.Read(_sampleBuffer, 0, (int)byteCount) != byteCount)
throw new Exception("Incomplete file read."); throw new Exception("Incomplete file read.");
AudioSamples.BytesToFLACSamples_16(_sampleBuffer, 0, buff, 0, AudioSamples.BytesToFLACSamples(_sampleBuffer, 0, buff, 0,
sampleCount, _channelCount); sampleCount, _channelCount, _bitsPerSample);
_samplePos += sampleCount; _samplePos += sampleCount;
return sampleCount; return sampleCount;
} }
@@ -975,7 +1012,20 @@ namespace CUETools.Codecs
{ {
int s1 = samples[2 * i], s2 = samples[2 * i + 1]; int s1 = samples[2 * i], s2 = samples[2 * i + 1];
crc = ComputeChecksum(ComputeChecksum(ComputeChecksum(ComputeChecksum( crc = ComputeChecksum(ComputeChecksum(ComputeChecksum(ComputeChecksum(
crc, (byte)s1), (byte)(s1 >> 8)), (byte)(s2)), (byte)(s2 >> 8)); crc, (byte)s1), (byte)(s1 >> 8)), (byte)s2), (byte)(s2 >> 8));
}
return crc;
}
public unsafe uint ComputeChecksumWONULL(uint crc, int* samples, uint count)
{
for (uint i = 0; i < count; i++)
{
int s1 = samples[2 * i], s2 = samples[2 * i + 1];
if (s1 != 0)
crc = ComputeChecksum(ComputeChecksum(crc, (byte)s1), (byte)(s1 >> 8));
if (s2 != 0)
crc = ComputeChecksum(ComputeChecksum(crc, (byte)s2), (byte)(s2 >> 8));
} }
return crc; return crc;
} }

View File

@@ -0,0 +1,101 @@
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>8.0.50727</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{115CC5B0-0385-41CD-8A23-6A7EA4C51926}</ProjectGuid>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>CUETools.Converter</RootNamespace>
<AssemblyName>CUETools.Converter</AssemblyName>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\bin\win32\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>..\bin\win32\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</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>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x64' ">
<DebugSymbols>true</DebugSymbols>
<OutputPath>..\bin\x64\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>x64</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|x64' ">
<OutputPath>..\bin\x64\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x64</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>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\CUETools.Codecs\CUETools.Codecs.csproj">
<Project>{6458A13A-30EF-45A9-9D58-E5031B17BEE2}</Project>
<Name>CUETools.Codecs</Name>
</ProjectReference>
<ProjectReference Include="..\CUETools.Processor\CUETools.Processor.csproj">
<Project>{4911BD82-49EF-4858-8B51-5394F86739A4}</Project>
<Name>CUETools.Processor</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -0,0 +1,86 @@
using System;
using System.Collections.Generic;
using System.Text;
using CUETools.Codecs;
using CUETools.Processor;
namespace CUETools.Converter
{
class Program
{
static void Usage()
{
Console.WriteLine("Usage : CUETools.Converter.exe <infile> <outfile>");
Console.WriteLine();
//Console.WriteLine("-N --stdinname <t> pseudo filename to use when input from STDIN.");
//Console.WriteLine(" --stdout write processed WAV output to STDOUT.");
}
static void Main(string[] args)
{
Console.SetOut(Console.Error);
Console.WriteLine("CUETools.Converter, Copyright (C) 2009 Gregory S. Chudov.");
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.");
if (args.Length < 2)
{
Usage();
return;
}
string sourceFile = args[0];
string destFile = args[1];
DateTime start = DateTime.Now;
TimeSpan lastPrint = TimeSpan.FromMilliseconds(0);
CUEConfig config = new CUEConfig();
config.lossyWAVHybrid = false;
#if !DEBUG
try
#endif
{
IAudioSource audioSource = AudioReadWrite.GetAudioSource(sourceFile, null);
IAudioDest audioDest = AudioReadWrite.GetAudioDest(destFile, (long)audioSource.Length, audioSource.BitsPerSample, audioSource.SampleRate, config);
int[,] buff = new int[0x1000, audioSource.ChannelCount];
audioDest.SetTags(audioSource.Tags);
Console.WriteLine("Filename : {0}", sourceFile);
Console.WriteLine("File Info : {0}kHz; {1} channel; {2} bit; {3}", audioSource.SampleRate, audioSource.ChannelCount, audioSource.BitsPerSample, TimeSpan.FromSeconds(audioSource.Length * 1.0 / audioSource.SampleRate));
do
{
uint samplesRead = audioSource.Read(buff, Math.Min((uint)buff.GetLength(0), (uint)audioSource.Remaining));
if (samplesRead == 0) break;
audioDest.Write(buff, samplesRead);
TimeSpan elapsed = DateTime.Now - start;
if ((elapsed - lastPrint).TotalMilliseconds > 60)
{
Console.Error.Write("\rProgress : {0:00}%; {1:0.00}x; {2}/{3}",
100.0 * audioSource.Position / audioSource.Length,
audioSource.Position / elapsed.TotalSeconds / audioSource.SampleRate,
elapsed,
TimeSpan.FromMilliseconds(elapsed.TotalMilliseconds / audioSource.Position * audioSource.Length)
);
lastPrint = elapsed;
}
} while (true);
TimeSpan totalElapsed = DateTime.Now - start;
Console.Error.Write("\r \r");
Console.WriteLine("Results : {0:0.00}x; {1}",
audioSource.Position / totalElapsed.TotalSeconds / audioSource.SampleRate,
totalElapsed
);
audioSource.Close();
audioDest.Close();
}
#if !DEBUG
catch (Exception ex)
{
Console.WriteLine();
Console.WriteLine("Error: {0}", ex.Message);
//Console.WriteLine("{0}", ex.StackTrace);
}
#endif
}
}
}

View File

@@ -0,0 +1,33 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("CUETools.Converter")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("CUETools.Converter")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2009")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("5ad82fad-b0a4-4f7e-b159-2773aaa3f6d3")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@@ -97,22 +97,18 @@ namespace CUETools.Processor
return dest; return dest;
} }
public static IAudioDest GetAudioDest(string path, long finalSampleCount, CUEConfig config) public static IAudioDest GetAudioDest(string path, long finalSampleCount, int bitsPerSample, int sampleRate, CUEConfig config)
{ {
string extension = Path.GetExtension(path).ToLower(); string extension = Path.GetExtension(path).ToLower();
string filename = Path.GetFileNameWithoutExtension(path); string filename = Path.GetFileNameWithoutExtension(path);
if (Path.GetExtension(filename).ToLower() != ".lossy") if (Path.GetExtension(filename).ToLower() != ".lossy")
{ return GetAudioDest(path, bitsPerSample, 2, sampleRate, finalSampleCount, extension, config);
int bitsPerSample = (config.detectHDCD && config.decodeHDCD) ? (config.decodeHDCDto24bit ? 24 : 20) : 16;
return GetAudioDest(path, bitsPerSample, 2, 44100, finalSampleCount, extension, config);
}
string lwcdfPath = Path.Combine(Path.GetDirectoryName(path), Path.GetFileNameWithoutExtension(filename) + ".lwcdf" + extension); string lwcdfPath = Path.Combine(Path.GetDirectoryName(path), Path.GetFileNameWithoutExtension(filename) + ".lwcdf" + extension);
int destBitsPerSample = (config.detectHDCD && config.decodeHDCD) ? ((!config.decodeHDCDtoLW16 && config.decodeHDCDto24bit) ? 24 : 20) : 16;
int lossyBitsPerSample = (config.detectHDCD && config.decodeHDCD && !config.decodeHDCDtoLW16) ? 24 : 16; int lossyBitsPerSample = (config.detectHDCD && config.decodeHDCD && !config.decodeHDCDtoLW16) ? 24 : 16;
IAudioDest lossyDest = GetAudioDest(path, lossyBitsPerSample, 2, 44100, finalSampleCount, extension, config); IAudioDest lossyDest = GetAudioDest(path, lossyBitsPerSample, 2, sampleRate, finalSampleCount, extension, config);
IAudioDest lwcdfDest = config.lossyWAVHybrid ? GetAudioDest(lwcdfPath, destBitsPerSample, 2, 44100, finalSampleCount, extension, config) : null; IAudioDest lwcdfDest = config.lossyWAVHybrid ? GetAudioDest(lwcdfPath, bitsPerSample, 2, sampleRate, finalSampleCount, extension, config) : null;
return new LossyWAVWriter(lossyDest, lwcdfDest, destBitsPerSample, 2, 44100, config.lossyWAVQuality); return new LossyWAVWriter(lossyDest, lwcdfDest, bitsPerSample, 2, sampleRate, config.lossyWAVQuality);
} }
} }
} }

View File

@@ -78,6 +78,10 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="ICSharpCode.SharpZipLib, Version=0.85.5.452, Culture=neutral, PublicKeyToken=1b03e6acf1164f73, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>.\ICSharpCode.SharpZipLib.dll</HintPath>
</Reference>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Data" /> <Reference Include="System.Data" />
<Reference Include="System.Drawing" /> <Reference Include="System.Drawing" />

Binary file not shown.

View File

@@ -42,6 +42,7 @@ using Freedb;
using UnRarDotNet; using UnRarDotNet;
using CUETools.Codecs.FLAC; using CUETools.Codecs.FLAC;
#endif #endif
using ICSharpCode.SharpZipLib.Zip;
namespace CUETools.Processor namespace CUETools.Processor
{ {
@@ -487,6 +488,7 @@ namespace CUETools.Processor
private const int _arOffsetRange = 5 * 588 - 1; private const int _arOffsetRange = 5 * 588 - 1;
private HDCDDotNet.HDCDDotNet hdcdDecoder; private HDCDDotNet.HDCDDotNet hdcdDecoder;
private bool _outputLossyWAV = false; private bool _outputLossyWAV = false;
private OutputAudioFormat _outputFormat = OutputAudioFormat.WAV;
private CUEConfig _config; private CUEConfig _config;
private string _cddbDiscIdTag; private string _cddbDiscIdTag;
private bool _isCD; private bool _isCD;
@@ -574,7 +576,7 @@ namespace CUETools.Processor
//Catalog = release.GetEvents().Count > 0 ? release.GetEvents()[0].Barcode : ""; //Catalog = release.GetEvents().Count > 0 ? release.GetEvents()[0].Barcode : "";
for (int i = 1; i <= _toc.AudioTracks; i++) for (int i = 1; i <= _toc.AudioTracks; i++)
{ {
MusicBrainz.Track track = release.GetTracks()[(int)_toc[i].Number - 1]; MusicBrainz.Track track = release.GetTracks()[(int)_toc[i].Number - 1]; // !!!!!! - _toc.FirstAudio
Tracks[i - 1].Title = track.GetTitle(); Tracks[i - 1].Title = track.GetTitle();
Tracks[i - 1].Artist = track.GetArtist(); Tracks[i - 1].Artist = track.GetArtist();
} }
@@ -693,8 +695,10 @@ namespace CUETools.Processor
TrackInfo trackInfo = null; TrackInfo trackInfo = null;
int timeRelativeToFileStart, absoluteFileStartTime = 0; int timeRelativeToFileStart, absoluteFileStartTime = 0;
int fileTimeLengthSamples = 0, fileTimeLengthFrames = 0, i; int fileTimeLengthSamples = 0, fileTimeLengthFrames = 0, i;
bool fileIsBinary = false;
int trackNumber = 0; int trackNumber = 0;
bool seenFirstFileIndex = false, seenDataTrack = false; bool isAudioTrack = true;
bool seenFirstFileIndex = false;
List<IndexInfo> indexes = new List<IndexInfo>(); List<IndexInfo> indexes = new List<IndexInfo>();
IndexInfo indexInfo; IndexInfo indexInfo;
NameValueCollection _trackTags = null; NameValueCollection _trackTags = null;
@@ -727,23 +731,48 @@ namespace CUETools.Processor
} }
} }
} }
#if !MONO else if (Path.GetExtension(pathIn).ToLower() == ".zip" || Path.GetExtension(pathIn).ToLower() == ".rar")
else if (Path.GetExtension(pathIn).ToLower() == ".rar")
{ {
Unrar _unrar = new Unrar(); _archiveContents = new List<string>();
_unrar.PasswordRequired += new PasswordRequiredHandler(unrar_PasswordRequired); _isArchive = true;
_archivePath = pathIn;
if (Path.GetExtension(pathIn).ToLower() == ".rar")
{
#if !MONO
using (Unrar _unrar = new Unrar())
{
_unrar.PasswordRequired += new PasswordRequiredHandler(unrar_PasswordRequired);
_unrar.Open(pathIn, Unrar.OpenMode.List);
while (_unrar.ReadHeader())
{
if (!_unrar.CurrentFile.IsDirectory)
_archiveContents.Add(_unrar.CurrentFile.FileName);
_unrar.Skip();
}
_unrar.Close();
}
#else
throw new Exception("rar archives not supported on MONO.");
#endif
}
if (Path.GetExtension(pathIn).ToLower() == ".zip")
{
using (ZipFile _unzip = new ZipFile(pathIn))
{
foreach (ZipEntry e in _unzip)
{
if (e.IsFile)
_archiveContents.Add(e.Name);
}
_unzip.Close();
}
}
string cueName = null, cueText = null, logName = null; string cueName = null, cueText = null, logName = null;
List<string> cueNames = new List<string>(); List<string> cueNames = new List<string>();
List<string> logNames = new List<string>(); List<string> logNames = new List<string>();
_unrar.Open(pathIn, Unrar.OpenMode.List);
_archiveContents = new List<string>();
while (_unrar.ReadHeader())
{
if (!_unrar.CurrentFile.IsDirectory)
_archiveContents.Add(_unrar.CurrentFile.FileName);
_unrar.Skip();
}
_unrar.Close();
foreach (string s in _archiveContents) foreach (string s in _archiveContents)
{ {
if (Path.GetExtension(s).ToLower() == ".cue") if (Path.GetExtension(s).ToLower() == ".cue")
@@ -751,7 +780,6 @@ namespace CUETools.Processor
if (Path.GetExtension(s).ToLower() == ".log") if (Path.GetExtension(s).ToLower() == ".log")
logNames.Add(s); logNames.Add(s);
} }
if (cueNames.Count == 0) if (cueNames.Count == 0)
throw new Exception("Input archive doesn't contain a cue sheet."); throw new Exception("Input archive doesn't contain a cue sheet.");
if (cueNames.Count == 1) if (cueNames.Count == 1)
@@ -780,12 +808,11 @@ namespace CUETools.Processor
if (cueName != null) if (cueName != null)
{ {
RarStream rarStream = new RarStream(pathIn, cueName); Stream archiveStream = OpenArchive(cueName, false);
rarStream.PasswordRequired += new PasswordRequiredHandler(unrar_PasswordRequired); StreamReader cueReader = new StreamReader(archiveStream, CUESheet.Encoding);
StreamReader cueReader = new StreamReader(rarStream, CUESheet.Encoding);
cueText = cueReader.ReadToEnd(); cueText = cueReader.ReadToEnd();
cueReader.Close(); cueReader.Close();
rarStream.Close(); archiveStream.Close();
if (cueText == "") if (cueText == "")
throw new Exception("Empty cue sheet."); throw new Exception("Empty cue sheet.");
} }
@@ -793,21 +820,17 @@ namespace CUETools.Processor
throw new Exception("Input archive doesn't contain a cue sheet."); throw new Exception("Input archive doesn't contain a cue sheet.");
if (logName != null) if (logName != null)
{ {
RarStream rarStream = new RarStream(pathIn, logName); Stream archiveStream = OpenArchive(logName, false);
rarStream.PasswordRequired += new PasswordRequiredHandler(unrar_PasswordRequired); StreamReader logReader = new StreamReader(archiveStream, CUESheet.Encoding);
StreamReader logReader = new StreamReader(rarStream, CUESheet.Encoding);
_eacLog = logReader.ReadToEnd(); _eacLog = logReader.ReadToEnd();
logReader.Close(); logReader.Close();
rarStream.Close(); archiveStream.Close();
} }
_archiveCUEpath = Path.GetDirectoryName(cueName); _archiveCUEpath = Path.GetDirectoryName(cueName);
if (_config.autoCorrectFilenames) if (_config.autoCorrectFilenames)
cueText = CorrectAudioFilenames(_archiveCUEpath, cueText, false, _archiveContents); cueText = CorrectAudioFilenames(_archiveCUEpath, cueText, false, _archiveContents);
sr = new StringReader(cueText); sr = new StringReader(cueText);
_isArchive = true;
_archivePath = pathIn;
} }
#endif
else if (Path.GetExtension(pathIn).ToLower() == ".cue") else if (Path.GetExtension(pathIn).ToLower() == ".cue")
{ {
if (_config.autoCorrectFilenames) if (_config.autoCorrectFilenames)
@@ -866,13 +889,11 @@ namespace CUETools.Processor
if (command == "FILE") { if (command == "FILE") {
fileType = line.Params[2].ToUpper(); fileType = line.Params[2].ToUpper();
if ((fileType == "BINARY") || (fileType == "MOTOROLA")) { if ((fileType == "BINARY") || (fileType == "MOTOROLA"))
seenDataTrack = true; fileIsBinary = true;
} else
else if (seenDataTrack) { {
throw new Exception("Audio tracks cannot appear after data tracks."); fileIsBinary = false;
}
else {
if (!_hasEmbeddedCUESheet) if (!_hasEmbeddedCUESheet)
{ {
if (_isArchive) if (_isArchive)
@@ -903,59 +924,66 @@ namespace CUETools.Processor
seenFirstFileIndex = false; seenFirstFileIndex = false;
} }
} }
else if (command == "TRACK") { else if (command == "TRACK")
if (line.Params[2].ToUpper() != "AUDIO") { {
seenDataTrack = true; isAudioTrack = line.Params[2].ToUpper() == "AUDIO";
} trackNumber = int.Parse(line.Params[1]);
else if (seenDataTrack) { if (trackNumber != _toc.TrackCount + 1)
throw new Exception("Audio tracks cannot appear after data tracks."); throw new Exception("Invalid track number.");
} _toc.AddTrack(new CDTrack((uint)trackNumber, 0, 0, isAudioTrack, false));
else { if (isAudioTrack)
trackNumber = int.Parse(line.Params[1]); {
if (trackNumber != _tracks.Count + 1) {
throw new Exception("Invalid track number.");
}
trackInfo = new TrackInfo(); trackInfo = new TrackInfo();
_tracks.Add(trackInfo); _tracks.Add(trackInfo);
_toc.AddTrack(new CDTrack((uint)trackNumber, 0, 0, true, false));
} }
} }
else if (seenDataTrack) { else if (command == "INDEX")
// Ignore lines belonging to data tracks {
}
else if (command == "INDEX") {
timeRelativeToFileStart = CDImageLayout.TimeFromString(line.Params[2]); timeRelativeToFileStart = CDImageLayout.TimeFromString(line.Params[2]);
if (!seenFirstFileIndex) if (!seenFirstFileIndex)
{ {
if (timeRelativeToFileStart != 0) if (timeRelativeToFileStart != 0)
{
throw new Exception("First index must start at file beginning."); throw new Exception("First index must start at file beginning.");
}
if (trackNumber > 0 && _trackTags != null && _trackTags.Count != 0)
_tracks[trackNumber-1]._trackTags = _trackTags;
seenFirstFileIndex = true; seenFirstFileIndex = true;
sourceInfo.Path = pathAudio; if (isAudioTrack)
sourceInfo.Offset = 0;
sourceInfo.Length = (uint)fileTimeLengthSamples;
_sources.Add(sourceInfo);
if ((fileTimeLengthSamples % 588) != 0)
{ {
sourceInfo.Path = null; if (_tracks.Count > 0 && _trackTags != null && _trackTags.Count != 0)
_tracks[_tracks.Count - 1]._trackTags = _trackTags;
sourceInfo.Path = pathAudio;
sourceInfo.Offset = 0; sourceInfo.Offset = 0;
sourceInfo.Length = (uint)((fileTimeLengthFrames * 588) - fileTimeLengthSamples); sourceInfo.Length = (uint)fileTimeLengthSamples;
_sources.Add(sourceInfo); _sources.Add(sourceInfo);
_paddedToFrame = true; if ((fileTimeLengthSamples % 588) != 0)
{
sourceInfo.Path = null;
sourceInfo.Offset = 0;
sourceInfo.Length = (uint)((fileTimeLengthFrames * 588) - fileTimeLengthSamples);
_sources.Add(sourceInfo);
_paddedToFrame = true;
}
} }
} }
else if (fileIsBinary)
{
fileTimeLengthFrames = timeRelativeToFileStart + 150;
sourceInfo.Path = null;
sourceInfo.Offset = 0;
sourceInfo.Length = 150 * 588;
_sources.Add(sourceInfo);
}
indexInfo.Track = trackNumber; indexInfo.Track = trackNumber;
indexInfo.Index = Int32.Parse(line.Params[1]); indexInfo.Index = Int32.Parse(line.Params[1]);
indexInfo.Time = absoluteFileStartTime + timeRelativeToFileStart; indexInfo.Time = absoluteFileStartTime + timeRelativeToFileStart;
indexes.Add(indexInfo); indexes.Add(indexInfo);
} }
else if (command == "PREGAP") { else if (!isAudioTrack)
if (seenFirstFileIndex) { {
// Ignore lines belonging to data tracks
}
else if (command == "PREGAP")
{
if (seenFirstFileIndex)
throw new Exception("Pregap must occur at the beginning of a file."); throw new Exception("Pregap must occur at the beginning of a file.");
}
int pregapLength = CDImageLayout.TimeFromString(line.Params[1]); int pregapLength = CDImageLayout.TimeFromString(line.Params[1]);
indexInfo.Track = trackNumber; indexInfo.Track = trackNumber;
indexInfo.Index = 0; indexInfo.Index = 0;
@@ -1009,6 +1037,24 @@ namespace CUETools.Processor
} }
else else
{ {
if (line.Params.Count > 2 && !line.IsQuoted[1] &&
(line.Params[0].ToUpper() == "TITLE" || line.Params[0].ToUpper() == "ARTIST" ||
(line.Params[0].ToUpper() == "REM" && line.Params[1].ToUpper() == "GENRE" && line.Params.Count > 3 && !line.IsQuoted[2])))
{
CUELine modline = new CUELine();
int nParams = line.Params[0].ToUpper() == "REM" ? 2 : 1;
for (int iParam = 0; iParam < nParams; iParam++)
{
modline.Params.Add(line.Params[iParam]);
modline.IsQuoted.Add(false);
}
string s = line.Params[nParams];
for (int iParam = nParams + 1; iParam < line.Params.Count; iParam++)
s += " " + line.Params[iParam];
modline.Params.Add(s);
modline.IsQuoted.Add(true);
line = modline;
}
_attributes.Add(line); _attributes.Add(line);
} }
} }
@@ -1017,8 +1063,16 @@ namespace CUETools.Processor
sr.Close(); sr.Close();
} }
if (trackNumber == 0) { if (_tracks.Count == 0)
throw new Exception("File must contain at least one audio track."); throw new Exception("File must contain at least one audio track.");
// Add dummy index 01 for data track
if (!_toc[_toc.TrackCount].IsAudio && indexes[indexes.Count - 1].Index == 0)
{
indexInfo.Track = trackNumber;
indexInfo.Index = 1;
indexInfo.Time = absoluteFileStartTime + fileTimeLengthFrames;
indexes.Add(indexInfo);
} }
// Add dummy track for calculation purposes // Add dummy track for calculation purposes
@@ -1041,10 +1095,10 @@ namespace CUETools.Processor
} }
// Calculate the length of each track // Calculate the length of each track
for (int iTrack = 1; iTrack <= TrackCount; iTrack++) for (int iTrack = 1; iTrack <= _toc.TrackCount; iTrack++)
{ {
_toc[iTrack].Start = _toc[iTrack][1].Start; _toc[iTrack].Start = _toc[iTrack][1].Start;
_toc[iTrack].Length = (iTrack == TrackCount ? (uint)indexes[indexes.Count - 1].Time - _toc[iTrack].Start : _toc[iTrack + 1][1].Start - _toc[iTrack].Start); _toc[iTrack].Length = (iTrack == _toc.TrackCount ? (uint)indexes[indexes.Count - 1].Time - _toc[iTrack].Start : _toc[iTrack + 1][1].Start - _toc[iTrack].Start);
} }
// Store the audio filenames, generating generic names if necessary // Store the audio filenames, generating generic names if necessary
@@ -1100,53 +1154,124 @@ namespace CUETools.Processor
if (_accurateRipId == null) if (_accurateRipId == null)
_accurateRipId = GetCommonTag("ACCURATERIPID"); _accurateRipId = GetCommonTag("ACCURATERIPID");
if (_accurateRipId == null && _dataTrackLength == null && _eacLog != null) if (_accurateRipId == null)
{ {
sr = new StringReader(_eacLog); if (_dataTrackLength != null)
bool isEACLog = false;
CDImageLayout tocFromLog = new CDImageLayout();
while ((lineStr = sr.ReadLine()) != null)
{ {
if (isEACLog) // TODO: check if we have a data track of unknown length already, and just change it's length!
{ CDImageLayout toc2 = new CDImageLayout(_toc);
string[] n = lineStr.Split('|'); toc2.AddTrack(new CDTrack((uint)_toc.TrackCount, _toc.Length + 152U * 75U, _dataTrackLength.Value, false, false));
uint trNo, trStart, trEnd; _accurateRipId = AccurateRipVerify.CalculateAccurateRipId(toc2);
if (n.Length == 5 && uint.TryParse(n[0], out trNo) && uint.TryParse(n[3], out trStart) && uint.TryParse(n[4], out trEnd))
tocFromLog.AddTrack(new CDTrack(trNo, trStart, trEnd + 1 - trStart,
tocFromLog.TrackCount < _toc.TrackCount || trStart != tocFromLog[tocFromLog.TrackCount].End + 1U + 152U * 75U, false));
} else
if (lineStr.StartsWith("TOC of the extracted CD")
|| lineStr.StartsWith("Exact Audio Copy")
|| lineStr.StartsWith("CUERipper"))
isEACLog = true;
} }
if (tocFromLog.TrackCount == _toc.TrackCount + 1 && !tocFromLog[tocFromLog.TrackCount].IsAudio) else
_accurateRipId = AccurateRipVerify.CalculateAccurateRipId(tocFromLog);
}
if (_accurateRipId == null && _dataTrackLength != null)
{
CDImageLayout toc2 = new CDImageLayout(_toc);
toc2.AddTrack(new CDTrack((uint)_toc.TrackCount, _toc.Length + 152U * 75U, _dataTrackLength.Value, false, false));
_accurateRipId = AccurateRipVerify.CalculateAccurateRipId(toc2);
}
if (_dataTrackLength == null && _cddbDiscIdTag != null)
{
uint cddbDiscIdNum;
if (uint.TryParse(_cddbDiscIdTag, NumberStyles.HexNumber, CultureInfo.InvariantCulture, out cddbDiscIdNum) && (cddbDiscIdNum & 0xff) == TrackCount + 1)
{ {
uint lengthFromTag = ((cddbDiscIdNum >> 8) & 0xffff); bool dtlFound = false;
_minDataTrackLength = ((lengthFromTag + _toc[1].Start / 75) - 152) * 75 - _toc.Length; if (_eacLog != null)
{
sr = new StringReader(_eacLog);
bool isEACLog = false;
CDImageLayout tocFromLog = new CDImageLayout();
while ((lineStr = sr.ReadLine()) != null)
{
if (isEACLog)
{
string[] n = lineStr.Split('|');
uint trNo, trStart, trEnd;
if (n.Length == 5 && uint.TryParse(n[0], out trNo) && uint.TryParse(n[3], out trStart) && uint.TryParse(n[4], out trEnd) && trNo == tocFromLog.TrackCount + 1)
{
bool isAudio = true;
if (tocFromLog.TrackCount >= _toc.TrackCount &&
trStart == tocFromLog[tocFromLog.TrackCount].End + 1U + 152U * 75U
)
isAudio = false;
if (tocFromLog.TrackCount < _toc.TrackCount &&
!_toc[tocFromLog.TrackCount + 1].IsAudio
)
isAudio = false;
tocFromLog.AddTrack(new CDTrack(trNo, trStart, trEnd + 1 - trStart, isAudio, false));
}
}
else
if (lineStr.StartsWith("TOC of the extracted CD")
|| lineStr.StartsWith("Exact Audio Copy")
|| lineStr.StartsWith("CUERipper"))
isEACLog = true;
}
if (tocFromLog.TrackCount == _toc.TrackCount + 1 && !tocFromLog[tocFromLog.TrackCount].IsAudio)
{
//_accurateRipId = AccurateRipVerify.CalculateAccurateRipId(tocFromLog);
_toc.AddTrack(new CDTrack((uint)tocFromLog.TrackCount, tocFromLog[tocFromLog.TrackCount].Start, tocFromLog[tocFromLog.TrackCount].Length, false, false));
dtlFound = true;
}
else if (tocFromLog.TrackCount == _toc.TrackCount)
{
if (!tocFromLog[1].IsAudio)
{
for (i = 2; i <= _toc.TrackCount; i++)
{
_toc[i].Start += tocFromLog[1].Length - _toc[1].Length;
for (int j = 0; j <= _toc[i].LastIndex; j++)
_toc[i][j].Start += tocFromLog[1].Length - _toc[1].Length;
}
_toc[1].Length = tocFromLog[1].Length;
dtlFound = true;
}
else if (!tocFromLog[tocFromLog.TrackCount].IsAudio)
{
_toc[_toc.TrackCount].Start = tocFromLog[_toc.TrackCount].Start;
_toc[_toc.TrackCount].Length = tocFromLog[_toc.TrackCount].Length;
_toc[_toc.TrackCount][0].Start = tocFromLog[_toc.TrackCount].Start;
_toc[_toc.TrackCount][1].Start = tocFromLog[_toc.TrackCount].Start;
dtlFound = true;
}
}
}
if (!dtlFound && _cddbDiscIdTag != null)
{
uint cddbDiscIdNum;
if (uint.TryParse(_cddbDiscIdTag, NumberStyles.HexNumber, CultureInfo.InvariantCulture, out cddbDiscIdNum) && (cddbDiscIdNum & 0xff) == _toc.TrackCount + 1)
{
uint lengthFromTag = ((cddbDiscIdNum >> 8) & 0xffff);
_minDataTrackLength = ((lengthFromTag + _toc[1].Start / 75) - 152) * 75 - _toc.Length;
}
}
} }
} }
_accurateRipIdActual = AccurateRipVerify.CalculateAccurateRipId(_toc); _accurateRipIdActual = AccurateRipVerify.CalculateAccurateRipId(_toc);
if (_accurateRipId == null) if (_accurateRipId == null)
_accurateRipId = _accurateRipIdActual; _accurateRipId = _accurateRipIdActual;
_arVerify = new AccurateRipVerify(_toc); _arVerify = new AccurateRipVerify(_toc);
if (_eacLog != null)
{
sr = new StringReader(_eacLog);
bool isEACLog = false;
int trNo = 1;
while ((lineStr = sr.ReadLine()) != null)
{
if (isEACLog && trNo <= TrackCount)
{
string[] s = { "Copy CRC ", "CRC <20><><EFBFBD><EFBFBD><EFBFBD>" };
string[] n = lineStr.Split(s, StringSplitOptions.None);
uint crc;
if (n.Length == 2 && uint.TryParse(n[1], NumberStyles.HexNumber, CultureInfo.CurrentCulture, out crc))
_arVerify.CRCLOG(trNo++, crc);
}
else
if (lineStr.StartsWith("Exact Audio Copy"))
isEACLog = true;
}
if (trNo == 2)
{
_arVerify.CRCLOG(0, _arVerify.CRCLOG(1));
if (TrackCount > 1)
_arVerify.CRCLOG(1, 0);
}
}
//if (!_dataTrackLength.HasValue && _cddbDiscIdTag != null) //if (!_dataTrackLength.HasValue && _cddbDiscIdTag != null)
//{ //{
// uint cddbDiscIdNum = UInt32.Parse(_cddbDiscIdTag, NumberStyles.HexNumber); // uint cddbDiscIdNum = UInt32.Parse(_cddbDiscIdTag, NumberStyles.HexNumber);
@@ -1166,6 +1291,37 @@ namespace CUETools.Processor
} }
} }
private Stream OpenArchive(string fileName, bool showProgress)
{
#if !MONO
if (Path.GetExtension(_archivePath).ToLower() == ".rar")
{
RarStream rarStream = new RarStream(_archivePath, fileName);
rarStream.PasswordRequired += new PasswordRequiredHandler(unrar_PasswordRequired);
if (showProgress)
rarStream.ExtractionProgress += new ExtractionProgressHandler(unrar_ExtractionProgress);
return rarStream;
}
#endif
if (Path.GetExtension(_archivePath).ToLower() == ".zip")
{
ZipInputStream zipStream = new ZipInputStream(File.OpenRead(_archivePath));
ZipEntry theEntry = null;
while ((theEntry = zipStream.GetNextEntry()) != null)
if (theEntry.Name == fileName)
break;
if (theEntry == null)
throw new Exception("Archive entry not found.");
if (theEntry.IsCrypted)
{
unrar_PasswordRequired(this, new PasswordRequiredEventArgs());
zipStream.Password = _archivePassword;
}
return zipStream;
}
throw new Exception("Unknown archive type.");
}
private void ShowProgress(string status, double percentTrack, double percentDisk, string input, string output) private void ShowProgress(string status, double percentTrack, double percentDisk, string input, string output)
{ {
if (this.CUEToolsProgress == null) if (this.CUEToolsProgress == null)
@@ -1271,7 +1427,7 @@ namespace CUETools.Processor
private static string LocateFile(string dir, string file, List<string> contents) { private static string LocateFile(string dir, string file, List<string> contents) {
List<string> dirList, fileList; List<string> dirList, fileList;
string altDir, path; string altDir;
dirList = new List<string>(); dirList = new List<string>();
fileList = new List<string>(); fileList = new List<string>();
@@ -1289,9 +1445,12 @@ namespace CUETools.Processor
for (int iDir = 0; iDir < dirList.Count; iDir++) { for (int iDir = 0; iDir < dirList.Count; iDir++) {
for (int iFile = 0; iFile < fileList.Count; iFile++) { for (int iFile = 0; iFile < fileList.Count; iFile++) {
path = Path.Combine(dirList[iDir], fileList[iFile]); string path = Path.Combine(dirList[iDir], fileList[iFile]);
if ( (contents == null && File.Exists(path)) if ( (contents == null && File.Exists(path))
|| (contents != null && contents.Contains (path))) || (contents != null && contents.Contains(path)))
return path;
path = dirList[iDir] + '/' + fileList[iFile];
if (contents != null && contents.Contains(path))
return path; return path;
} }
} }
@@ -1302,6 +1461,7 @@ namespace CUETools.Processor
public void GenerateFilenames(OutputAudioFormat format, bool outputLossyWAV, string outputPath) public void GenerateFilenames(OutputAudioFormat format, bool outputLossyWAV, string outputPath)
{ {
_outputLossyWAV = outputLossyWAV; _outputLossyWAV = outputLossyWAV;
_outputFormat = format;
_cuePath = outputPath; _cuePath = outputPath;
string extension = General.FormatExtension(format); string extension = General.FormatExtension(format);
@@ -1396,15 +1556,9 @@ namespace CUETools.Processor
IAudioSource audioSource; IAudioSource audioSource;
ShowProgress("Analyzing input file...", 0.0, 0.0, path, null); ShowProgress("Analyzing input file...", 0.0, 0.0, path, null);
#if !MONO
if (_isArchive) if (_isArchive)
{ audioSource = AudioReadWrite.GetAudioSource(path, OpenArchive(path, true));
RarStream IO = new RarStream(_archivePath, path); else
IO.PasswordRequired += new PasswordRequiredHandler(unrar_PasswordRequired);
IO.ExtractionProgress += new ExtractionProgressHandler(unrar_ExtractionProgress);
audioSource = AudioReadWrite.GetAudioSource(path, IO);
} else
#endif
audioSource = AudioReadWrite.GetAudioSource(path, null); audioSource = AudioReadWrite.GetAudioSource(path, null);
if ((audioSource.BitsPerSample != 16) || if ((audioSource.BitsPerSample != 16) ||
@@ -1523,8 +1677,8 @@ namespace CUETools.Processor
public string TOCContents() public string TOCContents()
{ {
StringWriter sw = new StringWriter(); StringWriter sw = new StringWriter();
for (int iTrack = 0; iTrack < TrackCount; iTrack++) for (int iTrack = 1; iTrack <= _toc.TrackCount; iTrack++)
sw.WriteLine("\t{0}", _toc[iTrack+1].Start + 150); sw.WriteLine("\t{0}", _toc[iTrack].Start + 150);
sw.Close(); sw.Close();
return sw.ToString(); return sw.ToString();
} }
@@ -1556,7 +1710,7 @@ namespace CUETools.Processor
if ((style == CUEStyle.GapsPrepended) || if ((style == CUEStyle.GapsPrepended) ||
(style == CUEStyle.GapsLeftOut) || (style == CUEStyle.GapsLeftOut) ||
((style == CUEStyle.GapsAppended) && ((style == CUEStyle.GapsAppended) &&
((_toc[iTrack+1].Pregap == 0) || ((iTrack == 0) && !htoaToFile)))) ((_toc[_toc.FirstAudio + iTrack].Pregap == 0) || ((iTrack == 0) && !htoaToFile))))
{ {
WriteLine(sw, 0, String.Format("FILE \"{0}\" WAVE", _trackFilenames[iTrack])); WriteLine(sw, 0, String.Format("FILE \"{0}\" WAVE", _trackFilenames[iTrack]));
timeRelativeToFileStart = 0; timeRelativeToFileStart = 0;
@@ -1566,16 +1720,16 @@ namespace CUETools.Processor
for (i = 0; i < _tracks[iTrack].Attributes.Count; i++) for (i = 0; i < _tracks[iTrack].Attributes.Count; i++)
WriteLine(sw, 2, _tracks[iTrack].Attributes[i]); WriteLine(sw, 2, _tracks[iTrack].Attributes[i]);
if (_toc[iTrack + 1].Pregap != 0) if (_toc[_toc.FirstAudio + iTrack].Pregap != 0)
{ {
if (((style == CUEStyle.GapsLeftOut) || if (((style == CUEStyle.GapsLeftOut) ||
((style == CUEStyle.GapsAppended) && (iTrack == 0) && !htoaToFile) || ((style == CUEStyle.GapsAppended) && (iTrack == 0) && !htoaToFile) ||
((style == CUEStyle.SingleFile || style == CUEStyle.SingleFileWithCUE) && (iTrack == 0) && _usePregapForFirstTrackInSingleFile))) ((style == CUEStyle.SingleFile || style == CUEStyle.SingleFileWithCUE) && (iTrack == 0) && _usePregapForFirstTrackInSingleFile)))
WriteLine(sw, 2, "PREGAP " + CDImageLayout.TimeToString(_toc[iTrack + 1].Pregap)); WriteLine(sw, 2, "PREGAP " + CDImageLayout.TimeToString(_toc[_toc.FirstAudio + iTrack].Pregap));
else else
{ {
WriteLine(sw, 2, String.Format("INDEX 00 {0}", CDImageLayout.TimeToString(timeRelativeToFileStart))); WriteLine(sw, 2, String.Format("INDEX 00 {0}", CDImageLayout.TimeToString(timeRelativeToFileStart)));
timeRelativeToFileStart += _toc[iTrack + 1].Pregap; timeRelativeToFileStart += _toc[_toc.FirstAudio + iTrack].Pregap;
if (style == CUEStyle.GapsAppended) if (style == CUEStyle.GapsAppended)
{ {
WriteLine(sw, 0, String.Format("FILE \"{0}\" WAVE", _trackFilenames[iTrack])); WriteLine(sw, 0, String.Format("FILE \"{0}\" WAVE", _trackFilenames[iTrack]));
@@ -1583,10 +1737,10 @@ namespace CUETools.Processor
} }
} }
} }
for (iIndex = 1; iIndex <= _toc[iTrack+1].LastIndex; iIndex++) for (iIndex = 1; iIndex <= _toc[_toc.FirstAudio + iTrack].LastIndex; iIndex++)
{ {
WriteLine(sw, 2, String.Format( "INDEX {0:00} {1}", iIndex, CDImageLayout.TimeToString(timeRelativeToFileStart))); WriteLine(sw, 2, String.Format( "INDEX {0:00} {1}", iIndex, CDImageLayout.TimeToString(timeRelativeToFileStart)));
timeRelativeToFileStart += _toc.IndexLength(iTrack + 1, iIndex); timeRelativeToFileStart += _toc.IndexLength(_toc.FirstAudio + iTrack, iIndex);
} }
} }
} }
@@ -1779,7 +1933,8 @@ namespace CUETools.Processor
break; break;
} }
ShowProgress((string)"Contacting AccurateRip database...", 0, (dtl - minDTL) / 75.0, null, null); ShowProgress((string)"Contacting AccurateRip database...", 0, (dtl - minDTL) / 75.0, null, null);
lock (this) { lock (this)
{
if (_stop) if (_stop)
throw new StopException(); throw new StopException();
if (_pause) if (_pause)
@@ -1795,61 +1950,60 @@ namespace CUETools.Processor
{ {
_accurateRipId = _accurateRipIdActual; _accurateRipId = _accurateRipIdActual;
} }
} else }
else
_arVerify.ContactAccurateRip(_accurateRipId); _arVerify.ContactAccurateRip(_accurateRipId);
if (_arVerify.AccResult != HttpStatusCode.OK) if (_accurateRipMode == AccurateRipMode.VerifyThenConvert)
{ {
if (_accurateRipMode == AccurateRipMode.Verify || _config.noUnverifiedOutput) if (_arVerify.AccResult != HttpStatusCode.OK && !_isCD)
{ {
if ((_accurateRipMode != AccurateRipMode.Verify && _config.writeArLogOnConvert) || if (_config.noUnverifiedOutput)
(_accurateRipMode == AccurateRipMode.Verify && _config.writeArLogOnVerify))
{ {
if (!Directory.Exists(dir)) if (_config.writeArLogOnConvert)
Directory.CreateDirectory(dir); {
StreamWriter sw = new StreamWriter(Path.ChangeExtension(_cuePath, ".accurip"), if (!Directory.Exists(dir))
false, CUESheet.Encoding); Directory.CreateDirectory(dir);
GenerateAccurateRipLog(sw); StreamWriter sw = new StreamWriter(Path.ChangeExtension(_cuePath, ".accurip"),
sw.Close(); false, CUESheet.Encoding);
GenerateAccurateRipLog(sw);
sw.Close();
}
if (_config.createTOC)
{
if (!Directory.Exists(dir))
Directory.CreateDirectory(dir);
WriteText(Path.ChangeExtension(_cuePath, ".toc"), TOCContents());
}
return;
} }
if (_config.createTOC)
{
if (!Directory.Exists(dir))
Directory.CreateDirectory(dir);
WriteText(Path.ChangeExtension(_cuePath, ".toc"), TOCContents());
}
return;
} }
if (_accurateRipMode == AccurateRipMode.VerifyThenConvert && _isCD) else
{ {
_writeOffset = 0; _writeOffset = 0;
WriteAudioFilesPass(dir, style, destPaths, destLengths, htoaToFile, true); WriteAudioFilesPass(dir, style, destPaths, destLengths, htoaToFile, true);
if (!_isCD)
{
uint tracksMatch;
int bestOffset;
if (_config.noUnverifiedOutput)
{
FindBestOffset(_config.encodeWhenConfidence, false, out tracksMatch, out bestOffset);
if (tracksMatch * 100 < _config.encodeWhenPercent * TrackCount || (_config.encodeWhenZeroOffset && bestOffset != 0))
SkipOutput = true;
}
if (!SkipOutput && _config.fixOffset)
{
FindBestOffset(_config.fixWhenConfidence, false, out tracksMatch, out bestOffset);
if (tracksMatch * 100 >= _config.fixWhenPercent * TrackCount)
_writeOffset = bestOffset;
}
}
_arVerify.CreateBackup(_writeOffset); _arVerify.CreateBackup(_writeOffset);
} }
} }
else if (_accurateRipMode == AccurateRipMode.VerifyThenConvert)
{
_writeOffset = 0;
WriteAudioFilesPass(dir, style, destPaths, destLengths, htoaToFile, true);
uint tracksMatch;
int bestOffset;
if (_config.noUnverifiedOutput)
{
FindBestOffset(_config.encodeWhenConfidence, false, out tracksMatch, out bestOffset);
if (tracksMatch * 100 < _config.encodeWhenPercent * TrackCount || (_config.encodeWhenZeroOffset && bestOffset != 0))
SkipOutput = true;
}
if (!SkipOutput && _config.fixOffset)
{
FindBestOffset(_config.fixWhenConfidence, false, out tracksMatch, out bestOffset);
if (tracksMatch * 100 >= _config.fixWhenPercent * TrackCount)
_writeOffset = bestOffset;
}
_arVerify.CreateBackup(_writeOffset);
}
} }
if (!SkipOutput) if (!SkipOutput)
@@ -1861,7 +2015,8 @@ namespace CUETools.Processor
} }
if (_isCD) if (_isCD)
destLengths = CalculateAudioFileLengths(style); // need to recalc, might have changed after scanning the CD destLengths = CalculateAudioFileLengths(style); // need to recalc, might have changed after scanning the CD
WriteAudioFilesPass(dir, style, destPaths, destLengths, htoaToFile, _accurateRipMode == AccurateRipMode.Verify); if (_outputFormat != OutputAudioFormat.NoAudio || _accurateRipMode == AccurateRipMode.Verify)
WriteAudioFilesPass(dir, style, destPaths, destLengths, htoaToFile, _accurateRipMode == AccurateRipMode.Verify);
if (_accurateRipMode != AccurateRipMode.Verify) if (_accurateRipMode != AccurateRipMode.Verify)
{ {
string logContents = LOGContents(); string logContents = LOGContents();
@@ -1928,7 +2083,8 @@ namespace CUETools.Processor
} }
} }
if (_accurateRipMode != AccurateRipMode.None) if (_accurateRipMode == AccurateRipMode.Verify ||
(_accurateRipMode != AccurateRipMode.None && _outputFormat != OutputAudioFormat.NoAudio))
{ {
ShowProgress((string)"Generating AccurateRip report...", 0, 0, null, null); ShowProgress((string)"Generating AccurateRip report...", 0, 0, null, null);
if (_accurateRipMode == AccurateRipMode.Verify && _config.writeArTagsOnVerify && _writeOffset == 0 && !_isArchive && !_isCD) if (_accurateRipMode == AccurateRipMode.Verify && _config.writeArTagsOnVerify && _writeOffset == 0 && !_isArchive && !_isCD)
@@ -2184,14 +2340,14 @@ namespace CUETools.Processor
if (style == CUEStyle.SingleFile || style == CUEStyle.SingleFileWithCUE) if (style == CUEStyle.SingleFile || style == CUEStyle.SingleFileWithCUE)
{ {
iDest++; iDest++;
audioDest = GetAudioDest(destPaths[iDest], destLengths[iDest], noOutput); audioDest = GetAudioDest(destPaths[iDest], destLengths[iDest], hdcdDecoder != null && hdcdDecoder.Decoding ? hdcdDecoder.BitsPerSample : 16, noOutput);
if (!noOutput) if (!noOutput)
SetAlbumTags(audioDest, bestOffset, style == CUEStyle.SingleFileWithCUE); SetAlbumTags(audioDest, bestOffset, style == CUEStyle.SingleFileWithCUE);
} }
uint currentOffset = 0, previousOffset = 0; uint currentOffset = 0, previousOffset = 0;
uint trackLength = _toc.Pregap * 588; uint trackLength = _toc.Pregap * 588;
uint diskLength = 588 * (_toc[_toc.TrackCount].IsAudio ? _toc[_toc.TrackCount].End + 1 : _toc[_toc.TrackCount - 1].End + 1); uint diskLength = 588 * _toc.AudioLength;
uint diskOffset = 0; uint diskOffset = 0;
if (_accurateRipMode != AccurateRipMode.None) if (_accurateRipMode != AccurateRipMode.None)
@@ -2199,7 +2355,9 @@ namespace CUETools.Processor
ShowProgress(String.Format("{2} track {0:00} ({1:00}%)...", 0, 0, noOutput ? "Verifying" : "Writing"), 0, 0.0, null, null); ShowProgress(String.Format("{2} track {0:00} ({1:00}%)...", 0, 0, noOutput ? "Verifying" : "Writing"), 0, 0.0, null, null);
#if !DEBUG
try try
#endif
{ {
for (iTrack = 0; iTrack < TrackCount; iTrack++) for (iTrack = 0; iTrack < TrackCount; iTrack++)
{ {
@@ -2212,20 +2370,20 @@ namespace CUETools.Processor
hdcdDecoder.AudioDest = null; hdcdDecoder.AudioDest = null;
if (audioDest != null) if (audioDest != null)
audioDest.Close(); audioDest.Close();
audioDest = GetAudioDest(destPaths[iDest], destLengths[iDest], noOutput); audioDest = GetAudioDest(destPaths[iDest], destLengths[iDest], hdcdDecoder != null && hdcdDecoder.Decoding ? hdcdDecoder.BitsPerSample : 16, noOutput);
if (!noOutput) if (!noOutput)
SetTrackTags(audioDest, iTrack, bestOffset); SetTrackTags(audioDest, iTrack, bestOffset);
} }
for (iIndex = 0; iIndex <= _toc[iTrack + 1].LastIndex; iIndex++) for (iIndex = 0; iIndex <= _toc[_toc.FirstAudio + iTrack].LastIndex; iIndex++)
{ {
uint samplesRemIndex = _toc.IndexLength(iTrack + 1, iIndex) * 588; uint samplesRemIndex = _toc.IndexLength(_toc.FirstAudio + iTrack, iIndex) * 588;
if (iIndex == 1) if (iIndex == 1)
{ {
previousOffset = currentOffset; previousOffset = currentOffset;
currentOffset = 0; currentOffset = 0;
trackLength = _toc[iTrack + 1].Length * 588; trackLength = _toc[_toc.FirstAudio + iTrack].Length * 588;
} }
if ((style == CUEStyle.GapsAppended) && (iIndex == 1)) if ((style == CUEStyle.GapsAppended) && (iIndex == 1))
@@ -2235,7 +2393,7 @@ namespace CUETools.Processor
if (audioDest != null) if (audioDest != null)
audioDest.Close(); audioDest.Close();
iDest++; iDest++;
audioDest = GetAudioDest(destPaths[iDest], destLengths[iDest], noOutput); audioDest = GetAudioDest(destPaths[iDest], destLengths[iDest], hdcdDecoder != null && hdcdDecoder.Decoding ? hdcdDecoder.BitsPerSample : 16, noOutput);
if (!noOutput) if (!noOutput)
SetTrackTags(audioDest, iTrack, bestOffset); SetTrackTags(audioDest, iTrack, bestOffset);
} }
@@ -2246,7 +2404,7 @@ namespace CUETools.Processor
if (htoaToFile) if (htoaToFile)
{ {
iDest++; iDest++;
audioDest = GetAudioDest(destPaths[iDest], destLengths[iDest], noOutput); audioDest = GetAudioDest(destPaths[iDest], destLengths[iDest], hdcdDecoder != null && hdcdDecoder.Decoding ? hdcdDecoder.BitsPerSample : 16, noOutput);
} }
} }
else if ((style == CUEStyle.GapsLeftOut) && (iIndex == 0)) else if ((style == CUEStyle.GapsLeftOut) && (iIndex == 0))
@@ -2331,6 +2489,7 @@ namespace CUETools.Processor
} }
} }
} }
#if !DEBUG
catch (Exception ex) catch (Exception ex)
{ {
if (hdcdDecoder != null) if (hdcdDecoder != null)
@@ -2344,6 +2503,7 @@ namespace CUETools.Processor
audioDest = null; audioDest = null;
throw ex; throw ex;
} }
#endif
#if !MONO #if !MONO
//if (_isCD && audioSource != null && audioSource is CDDriveReader) //if (_isCD && audioSource != null && audioSource is CDDriveReader)
@@ -2353,17 +2513,16 @@ namespace CUETools.Processor
_toc = (CDImageLayout)_ripper.TOC.Clone(); _toc = (CDImageLayout)_ripper.TOC.Clone();
if (_toc.Catalog != null) if (_toc.Catalog != null)
Catalog = _toc.Catalog; Catalog = _toc.Catalog;
for (iTrack = 1; iTrack <= _toc.TrackCount; iTrack++) for (iTrack = 0; iTrack < _toc.AudioTracks; iTrack++)
if (_toc[iTrack].IsAudio)
{ {
if (_toc[iTrack].ISRC != null) if (_toc[_toc.FirstAudio + iTrack].ISRC != null)
General.SetCUELine(_tracks[iTrack - 1].Attributes, "ISRC", _toc[iTrack].ISRC, false); General.SetCUELine(_tracks[iTrack].Attributes, "ISRC", _toc[_toc.FirstAudio + iTrack].ISRC, false);
//if (_toc[iTrack].DCP || _toc[iTrack].PreEmphasis) //if (_toc[_toc.FirstAudio + iTrack].DCP || _toc[_toc.FirstAudio + iTrack].PreEmphasis)
//cueWriter.WriteLine(" FLAGS{0}{1}", audioSource.TOC[track].PreEmphasis ? " PRE" : "", audioSource.TOC[track].DCP ? " DCP" : ""); //cueWriter.WriteLine(" FLAGS{0}{1}", audioSource.TOC[track].PreEmphasis ? " PRE" : "", audioSource.TOC[track].DCP ? " DCP" : "");
if (_toc[iTrack].DCP) if (_toc[_toc.FirstAudio + iTrack].DCP)
General.SetCUELine(_tracks[iTrack - 1].Attributes, "FLAGS", "DCP", false); General.SetCUELine(_tracks[iTrack].Attributes, "FLAGS", "DCP", false);
if (_toc[iTrack].PreEmphasis) if (_toc[_toc.FirstAudio + iTrack].PreEmphasis)
General.SetCUELine(_tracks[iTrack - 1].Attributes, "FLAGS", "PRE", false); General.SetCUELine(_tracks[iTrack].Attributes, "FLAGS", "PRE", false);
} }
} }
#endif #endif
@@ -2435,17 +2594,18 @@ namespace CUETools.Processor
foundAll = false; foundAll = false;
for (i = 0; i < audioExts.Length; i++) for (i = 0; i < audioExts.Length; i++)
{ {
foundAll = true;
List<string> newFiles = new List<string>(); List<string> newFiles = new List<string>();
for (int j = 0; j < origFiles.Count; j++) for (int j = 0; j < origFiles.Count; j++)
{ {
string newFilename = Path.ChangeExtension(Path.GetFileName(origFiles[j]), audioExts[i].Substring(1)); string newFilename = Path.ChangeExtension(Path.GetFileName(origFiles[j]), audioExts[i].Substring(1));
foundAll &= LocateFile(dir, newFilename, files) != null; string locatedFilename = LocateFile(dir, newFilename, files);
newFiles.Add (newFilename); if (locatedFilename != null)
newFiles.Add(locatedFilename);
} }
if (foundAll) if (newFiles.Count == origFiles.Count)
{ {
audioFiles = newFiles.ToArray(); audioFiles = newFiles.ToArray();
foundAll = true;
break; break;
} }
} }
@@ -2506,7 +2666,8 @@ namespace CUETools.Processor
if (style == CUEStyle.GapsPrepended || style == CUEStyle.GapsLeftOut) if (style == CUEStyle.GapsPrepended || style == CUEStyle.GapsLeftOut)
iFile++; iFile++;
for (iIndex = 0; iIndex <= _toc[iTrack+1].LastIndex; iIndex++) { for (iIndex = 0; iIndex <= _toc[_toc.FirstAudio + iTrack].LastIndex; iIndex++)
{
if (style == CUEStyle.GapsAppended && (iIndex == 1 || (iIndex == 0 && iTrack == 0 && htoaToFile))) if (style == CUEStyle.GapsAppended && (iIndex == 1 || (iIndex == 0 && iTrack == 0 && htoaToFile)))
iFile++; iFile++;
@@ -2516,7 +2677,7 @@ namespace CUETools.Processor
discardOutput = (style == CUEStyle.GapsLeftOut && iIndex == 0); discardOutput = (style == CUEStyle.GapsLeftOut && iIndex == 0);
if (!discardOutput) if (!discardOutput)
fileLengths[iFile] += (int)_toc.IndexLength(iTrack + 1, iIndex) * 588; fileLengths[iFile] += (int)_toc.IndexLength(_toc.FirstAudio + iTrack, iIndex) * 588;
} }
} }
@@ -2555,11 +2716,11 @@ namespace CUETools.Processor
} }
} }
private IAudioDest GetAudioDest(string path, int finalSampleCount, bool noOutput) private IAudioDest GetAudioDest(string path, int finalSampleCount, int bps, bool noOutput)
{ {
if (noOutput) if (noOutput)
return new DummyWriter(path, (_config.detectHDCD && _config.decodeHDCD) ? 24 : 16, 2, 44100); return new DummyWriter(path, bps, 2, 44100);
return AudioReadWrite.GetAudioDest(path, finalSampleCount, _config); return AudioReadWrite.GetAudioDest(path, finalSampleCount, bps, 44100, _config);
} }
private IAudioSource GetAudioSource(int sourceIndex) { private IAudioSource GetAudioSource(int sourceIndex) {
@@ -2577,14 +2738,10 @@ namespace CUETools.Processor
//audioSource = _ripper; //audioSource = _ripper;
audioSource = new AudioPipe(_ripper, 3); audioSource = new AudioPipe(_ripper, 3);
} else } else
if (_isArchive)
{
RarStream IO = new RarStream(_archivePath, sourceInfo.Path);
IO.PasswordRequired += new PasswordRequiredHandler(unrar_PasswordRequired);
audioSource = AudioReadWrite.GetAudioSource(sourceInfo.Path, IO);
}
else
#endif #endif
if (_isArchive)
audioSource = AudioReadWrite.GetAudioSource(sourceInfo.Path, OpenArchive(sourceInfo.Path, false));
else
audioSource = AudioReadWrite.GetAudioSource(sourceInfo.Path, null); audioSource = AudioReadWrite.GetAudioSource(sourceInfo.Path, null);
} }
@@ -2865,9 +3022,9 @@ namespace CUETools.Processor
int last = _params.Count - 1; int last = _params.Count - 1;
for (int i = 0; i <= last; i++) { for (int i = 0; i <= last; i++) {
if (_quoted[i]) sb.Append('"'); if (_quoted[i] || _params[i].Contains(" ")) sb.Append('"');
sb.Append(_params[i]); sb.Append(_params[i].Replace('"', '\''));
if (_quoted[i]) sb.Append('"'); if (_quoted[i] || _params[i].Contains(" ")) sb.Append('"');
if (i < last) sb.Append(' '); if (i < last) sb.Append(' ');
} }

View File

@@ -0,0 +1,152 @@
namespace CUETools.Processor
{
partial class frmProperties
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(frmProperties));
this.textArtist = new System.Windows.Forms.TextBox();
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.textTitle = new System.Windows.Forms.TextBox();
this.button1 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.label3 = new System.Windows.Forms.Label();
this.textYear = new System.Windows.Forms.TextBox();
this.textGenre = new System.Windows.Forms.TextBox();
this.textCatalog = new System.Windows.Forms.TextBox();
this.label4 = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// textArtist
//
resources.ApplyResources(this.textArtist, "textArtist");
this.textArtist.Name = "textArtist";
//
// label1
//
resources.ApplyResources(this.label1, "label1");
this.label1.Name = "label1";
//
// label2
//
resources.ApplyResources(this.label2, "label2");
this.label2.Name = "label2";
//
// textTitle
//
resources.ApplyResources(this.textTitle, "textTitle");
this.textTitle.Name = "textTitle";
//
// button1
//
this.button1.DialogResult = System.Windows.Forms.DialogResult.OK;
resources.ApplyResources(this.button1, "button1");
this.button1.Name = "button1";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// button2
//
this.button2.DialogResult = System.Windows.Forms.DialogResult.Cancel;
resources.ApplyResources(this.button2, "button2");
this.button2.Name = "button2";
this.button2.UseVisualStyleBackColor = true;
//
// label3
//
resources.ApplyResources(this.label3, "label3");
this.label3.Name = "label3";
//
// textYear
//
resources.ApplyResources(this.textYear, "textYear");
this.textYear.Name = "textYear";
//
// textGenre
//
resources.ApplyResources(this.textGenre, "textGenre");
this.textGenre.Name = "textGenre";
//
// textCatalog
//
resources.ApplyResources(this.textCatalog, "textCatalog");
this.textCatalog.Name = "textCatalog";
//
// label4
//
resources.ApplyResources(this.label4, "label4");
this.label4.Name = "label4";
//
// label5
//
resources.ApplyResources(this.label5, "label5");
this.label5.Name = "label5";
//
// frmProperties
//
this.AcceptButton = this.button1;
resources.ApplyResources(this, "$this");
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.CancelButton = this.button2;
this.Controls.Add(this.label5);
this.Controls.Add(this.label4);
this.Controls.Add(this.textCatalog);
this.Controls.Add(this.textGenre);
this.Controls.Add(this.textYear);
this.Controls.Add(this.label3);
this.Controls.Add(this.button2);
this.Controls.Add(this.button1);
this.Controls.Add(this.label2);
this.Controls.Add(this.textTitle);
this.Controls.Add(this.label1);
this.Controls.Add(this.textArtist);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow;
this.Name = "frmProperties";
this.Load += new System.EventHandler(this.frmProperties_Load);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.TextBox textArtist;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox textTitle;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox textYear;
private System.Windows.Forms.TextBox textGenre;
private System.Windows.Forms.TextBox textCatalog;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Label label5;
}
}

View File

@@ -0,0 +1,51 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using CUETools.Processor;
namespace CUETools.Processor
{
public partial class frmProperties : Form
{
public frmProperties()
{
InitializeComponent();
}
private void frmProperties_Load(object sender, EventArgs e)
{
textArtist.Text = _cueSheet.Artist;
textTitle.Text = _cueSheet.Title;
textYear.Text = _cueSheet.Year;
textGenre.Text = _cueSheet.Genre;
textCatalog.Text = _cueSheet.Catalog;
}
public CUESheet CUE
{
get
{
return _cueSheet;
}
set
{
_cueSheet = value;
}
}
CUESheet _cueSheet;
private void button1_Click(object sender, EventArgs e)
{
_cueSheet.Artist = textArtist.Text;
_cueSheet.Title = textTitle.Text;
_cueSheet.Year = textYear.Text;
_cueSheet.Genre = textGenre.Text;
_cueSheet.Catalog = textCatalog.Text;
}
}
}

View File

@@ -0,0 +1,441 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<data name="textArtist.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
<value>Top, Left, Right</value>
</data>
<assembly alias="System.Drawing" name="System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="textArtist.Location" type="System.Drawing.Point, System.Drawing">
<value>48, 12</value>
</data>
<data name="textArtist.Size" type="System.Drawing.Size, System.Drawing">
<value>374, 20</value>
</data>
<assembly alias="mscorlib" name="mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<data name="textArtist.TabIndex" type="System.Int32, mscorlib">
<value>0</value>
</data>
<data name="&gt;&gt;textArtist.Name" xml:space="preserve">
<value>textArtist</value>
</data>
<data name="&gt;&gt;textArtist.Type" xml:space="preserve">
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;textArtist.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;textArtist.ZOrder" xml:space="preserve">
<value>11</value>
</data>
<data name="label1.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="label1.Location" type="System.Drawing.Point, System.Drawing">
<value>12, 15</value>
</data>
<data name="label1.Size" type="System.Drawing.Size, System.Drawing">
<value>30, 13</value>
</data>
<data name="label1.TabIndex" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="label1.Text" xml:space="preserve">
<value>Artist</value>
</data>
<data name="&gt;&gt;label1.Name" xml:space="preserve">
<value>label1</value>
</data>
<data name="&gt;&gt;label1.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;label1.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;label1.ZOrder" xml:space="preserve">
<value>10</value>
</data>
<data name="label2.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="label2.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="label2.Location" type="System.Drawing.Point, System.Drawing">
<value>12, 41</value>
</data>
<data name="label2.Size" type="System.Drawing.Size, System.Drawing">
<value>27, 13</value>
</data>
<data name="label2.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="label2.Text" xml:space="preserve">
<value>Title</value>
</data>
<data name="&gt;&gt;label2.Name" xml:space="preserve">
<value>label2</value>
</data>
<data name="&gt;&gt;label2.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;label2.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;label2.ZOrder" xml:space="preserve">
<value>8</value>
</data>
<data name="textTitle.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
<value>Top, Left, Right</value>
</data>
<data name="textTitle.Location" type="System.Drawing.Point, System.Drawing">
<value>48, 38</value>
</data>
<data name="textTitle.Size" type="System.Drawing.Size, System.Drawing">
<value>374, 20</value>
</data>
<data name="textTitle.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="&gt;&gt;textTitle.Name" xml:space="preserve">
<value>textTitle</value>
</data>
<data name="&gt;&gt;textTitle.Type" xml:space="preserve">
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;textTitle.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;textTitle.ZOrder" xml:space="preserve">
<value>9</value>
</data>
<data name="button1.Location" type="System.Drawing.Point, System.Drawing">
<value>347, 90</value>
</data>
<data name="button1.Size" type="System.Drawing.Size, System.Drawing">
<value>75, 23</value>
</data>
<data name="button1.TabIndex" type="System.Int32, mscorlib">
<value>14</value>
</data>
<data name="button1.Text" xml:space="preserve">
<value>Ok</value>
</data>
<data name="&gt;&gt;button1.Name" xml:space="preserve">
<value>button1</value>
</data>
<data name="&gt;&gt;button1.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;button1.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;button1.ZOrder" xml:space="preserve">
<value>7</value>
</data>
<data name="button2.Location" type="System.Drawing.Point, System.Drawing">
<value>266, 90</value>
</data>
<data name="button2.Size" type="System.Drawing.Size, System.Drawing">
<value>75, 23</value>
</data>
<data name="button2.TabIndex" type="System.Int32, mscorlib">
<value>15</value>
</data>
<data name="button2.Text" xml:space="preserve">
<value>Cancel</value>
</data>
<data name="&gt;&gt;button2.Name" xml:space="preserve">
<value>button2</value>
</data>
<data name="&gt;&gt;button2.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;button2.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;button2.ZOrder" xml:space="preserve">
<value>6</value>
</data>
<data name="label3.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="label3.Location" type="System.Drawing.Point, System.Drawing">
<value>12, 67</value>
</data>
<data name="label3.Size" type="System.Drawing.Size, System.Drawing">
<value>29, 13</value>
</data>
<data name="label3.TabIndex" type="System.Int32, mscorlib">
<value>6</value>
</data>
<data name="label3.Text" xml:space="preserve">
<value>Year</value>
</data>
<data name="&gt;&gt;label3.Name" xml:space="preserve">
<value>label3</value>
</data>
<data name="&gt;&gt;label3.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;label3.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;label3.ZOrder" xml:space="preserve">
<value>5</value>
</data>
<data name="textYear.Location" type="System.Drawing.Point, System.Drawing">
<value>48, 64</value>
</data>
<data name="textYear.Size" type="System.Drawing.Size, System.Drawing">
<value>67, 20</value>
</data>
<data name="textYear.TabIndex" type="System.Int32, mscorlib">
<value>7</value>
</data>
<data name="&gt;&gt;textYear.Name" xml:space="preserve">
<value>textYear</value>
</data>
<data name="&gt;&gt;textYear.Type" xml:space="preserve">
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;textYear.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;textYear.ZOrder" xml:space="preserve">
<value>4</value>
</data>
<data name="textGenre.Location" type="System.Drawing.Point, System.Drawing">
<value>163, 64</value>
</data>
<data name="textGenre.Size" type="System.Drawing.Size, System.Drawing">
<value>100, 20</value>
</data>
<data name="textGenre.TabIndex" type="System.Int32, mscorlib">
<value>8</value>
</data>
<data name="&gt;&gt;textGenre.Name" xml:space="preserve">
<value>textGenre</value>
</data>
<data name="&gt;&gt;textGenre.Type" xml:space="preserve">
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;textGenre.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;textGenre.ZOrder" xml:space="preserve">
<value>3</value>
</data>
<data name="textCatalog.Location" type="System.Drawing.Point, System.Drawing">
<value>318, 64</value>
</data>
<data name="textCatalog.Size" type="System.Drawing.Size, System.Drawing">
<value>104, 20</value>
</data>
<data name="textCatalog.TabIndex" type="System.Int32, mscorlib">
<value>9</value>
</data>
<data name="&gt;&gt;textCatalog.Name" xml:space="preserve">
<value>textCatalog</value>
</data>
<data name="&gt;&gt;textCatalog.Type" xml:space="preserve">
<value>System.Windows.Forms.TextBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;textCatalog.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;textCatalog.ZOrder" xml:space="preserve">
<value>2</value>
</data>
<data name="label4.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="label4.Location" type="System.Drawing.Point, System.Drawing">
<value>121, 67</value>
</data>
<data name="label4.Size" type="System.Drawing.Size, System.Drawing">
<value>36, 13</value>
</data>
<data name="label4.TabIndex" type="System.Int32, mscorlib">
<value>10</value>
</data>
<data name="label4.Text" xml:space="preserve">
<value>Genre</value>
</data>
<data name="&gt;&gt;label4.Name" xml:space="preserve">
<value>label4</value>
</data>
<data name="&gt;&gt;label4.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;label4.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;label4.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="label5.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="label5.Location" type="System.Drawing.Point, System.Drawing">
<value>269, 67</value>
</data>
<data name="label5.Size" type="System.Drawing.Size, System.Drawing">
<value>43, 13</value>
</data>
<data name="label5.TabIndex" type="System.Int32, mscorlib">
<value>11</value>
</data>
<data name="label5.Text" xml:space="preserve">
<value>Catalog</value>
</data>
<data name="&gt;&gt;label5.Name" xml:space="preserve">
<value>label5</value>
</data>
<data name="&gt;&gt;label5.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;label5.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;label5.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing">
<value>6, 13</value>
</data>
<data name="$this.ClientSize" type="System.Drawing.Size, System.Drawing">
<value>434, 120</value>
</data>
<data name="$this.StartPosition" type="System.Windows.Forms.FormStartPosition, System.Windows.Forms">
<value>CenterParent</value>
</data>
<data name="$this.Text" xml:space="preserve">
<value>Release information</value>
</data>
<data name="&gt;&gt;$this.Name" xml:space="preserve">
<value>frmProperties</value>
</data>
<data name="&gt;&gt;$this.Type" xml:space="preserve">
<value>System.Windows.Forms.Form, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
</root>

View File

@@ -270,10 +270,12 @@ namespace CUETools.Ripper.SCSI
((toc[iTrack + 1].Control < 4 || iTrack + 1 == toc.Count - 1) ? 0U : 152U * 75U), ((toc[iTrack + 1].Control < 4 || iTrack + 1 == toc.Count - 1) ? 0U : 152U * 75U),
toc[iTrack].Control < 4, toc[iTrack].Control < 4,
(toc[iTrack].Control & 1) == 1)); (toc[iTrack].Control & 1) == 1));
if (_toc[1].IsAudio)
_toc[1][0].Start = 0;
if (_toc.AudioLength > 0) if (_toc.AudioLength > 0)
{
if (_toc[1].IsAudio)
_toc[1][0].Start = 0;
Position = 0; Position = 0;
}
return true; return true;
} }
@@ -356,7 +358,7 @@ namespace CUETools.Ripper.SCSI
if (!updateMap) if (!updateMap)
break; break;
int sec = ff + 75 * (ss + 60 * mm) - 150; // sector + iSector; int sec = ff + 75 * (ss + 60 * mm) - 150; // sector + iSector;
if (iTrack > _toc.AudioTracks) if (iTrack >= _toc.FirstAudio + _toc.AudioTracks)
throw new Exception("strange track number encountred"); throw new Exception("strange track number encountred");
if (iTrack != _currentTrack) if (iTrack != _currentTrack)
{ {
@@ -546,13 +548,13 @@ namespace CUETools.Ripper.SCSI
MemSet(data, size, 0xff); MemSet(data, size, 0xff);
} }
if (_readCDCommand == ReadCDCommand.ReadCdBEh) if (_readCDCommand == ReadCDCommand.ReadCdBEh)
st = m_device.ReadCDAndSubChannel(_mainChannelMode, _subChannelMode, _c2ErrorMode, 1, false, (uint)sector, (uint)Sectors2Read, (IntPtr)((void*)data), _timeout); st = m_device.ReadCDAndSubChannel(_mainChannelMode, _subChannelMode, _c2ErrorMode, 1, false, (uint)sector + _toc[_toc.FirstAudio][0].Start, (uint)Sectors2Read, (IntPtr)((void*)data), _timeout);
else else
st = m_device.ReadCDDA(_subChannelMode, (uint)sector, (uint)Sectors2Read, (IntPtr)((void*)data), _timeout); st = m_device.ReadCDDA(_subChannelMode, (uint)sector + _toc[_toc.FirstAudio][0].Start, (uint)Sectors2Read, (IntPtr)((void*)data), _timeout);
} }
if (st == Device.CommandStatus.Success && _subChannelMode == Device.SubChannelMode.None && subchannel) if (st == Device.CommandStatus.Success && _subChannelMode == Device.SubChannelMode.None && subchannel)
st = m_device.ReadSubChannel(2, (uint)sector, (uint)Sectors2Read, ref _subchannelBuffer, _timeout); st = m_device.ReadSubChannel(2, (uint)sector + _toc[_toc.FirstAudio][0].Start, (uint)Sectors2Read, ref _subchannelBuffer, _timeout);
if (st == Device.CommandStatus.Success) if (st == Device.CommandStatus.Success)
{ {

View File

@@ -85,6 +85,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CUETools.Codecs.TTA", "..\C
{B3DF599C-1C8F-451D-91E4-DD766210DA1F} = {B3DF599C-1C8F-451D-91E4-DD766210DA1F} {B3DF599C-1C8F-451D-91E4-DD766210DA1F} = {B3DF599C-1C8F-451D-91E4-DD766210DA1F}
EndProjectSection EndProjectSection
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CUETools.Converter", "..\CUETools.Converter\CUETools.Converter.csproj", "{115CC5B0-0385-41CD-8A23-6A7EA4C51926}"
EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU Debug|Any CPU = Debug|Any CPU
@@ -411,6 +413,18 @@ Global
{1D1E99BC-6D22-41C0-BD94-FF4DD5EC725B}.Release|x64.Build.0 = Release|x64 {1D1E99BC-6D22-41C0-BD94-FF4DD5EC725B}.Release|x64.Build.0 = Release|x64
{1D1E99BC-6D22-41C0-BD94-FF4DD5EC725B}.Release|x86.ActiveCfg = Release|Win32 {1D1E99BC-6D22-41C0-BD94-FF4DD5EC725B}.Release|x86.ActiveCfg = Release|Win32
{1D1E99BC-6D22-41C0-BD94-FF4DD5EC725B}.Release|x86.Build.0 = Release|Win32 {1D1E99BC-6D22-41C0-BD94-FF4DD5EC725B}.Release|x86.Build.0 = Release|Win32
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Debug|Any CPU.Build.0 = Debug|Any CPU
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Debug|x64.ActiveCfg = Debug|x64
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Debug|x64.Build.0 = Debug|x64
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Debug|x86.ActiveCfg = Debug|x86
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Debug|x86.Build.0 = Debug|x86
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Release|Any CPU.ActiveCfg = Release|Any CPU
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Release|Any CPU.Build.0 = Release|Any CPU
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Release|x64.ActiveCfg = Release|x64
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Release|x64.Build.0 = Release|x64
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Release|x86.ActiveCfg = Release|x86
{115CC5B0-0385-41CD-8A23-6A7EA4C51926}.Release|x86.Build.0 = Release|x86
EndGlobalSection EndGlobalSection
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE
@@ -429,6 +443,7 @@ Global
{A574F3B1-E38B-4EE4-9394-49D6E2DF52EA} = {4B59E09C-A51F-4B80-91BE-987904DCEF7D} {A574F3B1-E38B-4EE4-9394-49D6E2DF52EA} = {4B59E09C-A51F-4B80-91BE-987904DCEF7D}
{9253A314-1821-42BF-B02F-2BF986B1765D} = {4B59E09C-A51F-4B80-91BE-987904DCEF7D} {9253A314-1821-42BF-B02F-2BF986B1765D} = {4B59E09C-A51F-4B80-91BE-987904DCEF7D}
{A5A8D8FA-9E32-4010-8AAF-AE580C5AF728} = {4B59E09C-A51F-4B80-91BE-987904DCEF7D} {A5A8D8FA-9E32-4010-8AAF-AE580C5AF728} = {4B59E09C-A51F-4B80-91BE-987904DCEF7D}
{115CC5B0-0385-41CD-8A23-6A7EA4C51926} = {4B59E09C-A51F-4B80-91BE-987904DCEF7D}
{B75FA7AD-968E-4990-B342-1B4B17C850DF} = {B36BE134-D85A-437E-AB61-2DA1CCDE06C1} {B75FA7AD-968E-4990-B342-1B4B17C850DF} = {B36BE134-D85A-437E-AB61-2DA1CCDE06C1}
{F2DFEB00-BB35-4665-85EA-CB8C7729A6B7} = {B36BE134-D85A-437E-AB61-2DA1CCDE06C1} {F2DFEB00-BB35-4665-85EA-CB8C7729A6B7} = {B36BE134-D85A-437E-AB61-2DA1CCDE06C1}
{A05B6AA6-0EC3-495D-BCC4-ECE1210071A8} = {B36BE134-D85A-437E-AB61-2DA1CCDE06C1} {A05B6AA6-0EC3-495D-BCC4-ECE1210071A8} = {B36BE134-D85A-437E-AB61-2DA1CCDE06C1}

View File

@@ -76,9 +76,9 @@ namespace JDP {
this.btnPause = new System.Windows.Forms.Button(); this.btnPause = new System.Windows.Forms.Button();
this.btnResume = new System.Windows.Forms.Button(); this.btnResume = new System.Windows.Forms.Button();
this.groupBox1 = new System.Windows.Forms.GroupBox(); this.groupBox1 = new System.Windows.Forms.GroupBox();
this.rbFreedbNever = new System.Windows.Forms.RadioButton();
this.rbFreedbIf = new System.Windows.Forms.RadioButton();
this.rbFreedbAlways = new System.Windows.Forms.RadioButton(); this.rbFreedbAlways = new System.Windows.Forms.RadioButton();
this.rbFreedbIf = new System.Windows.Forms.RadioButton();
this.rbFreedbNever = new System.Windows.Forms.RadioButton();
this.grpCUEPaths.SuspendLayout(); this.grpCUEPaths.SuspendLayout();
this.grpOutputStyle.SuspendLayout(); this.grpOutputStyle.SuspendLayout();
this.grpOutputPathGeneration.SuspendLayout(); this.grpOutputPathGeneration.SuspendLayout();
@@ -90,78 +90,125 @@ namespace JDP {
// //
// btnConvert // btnConvert
// //
this.btnConvert.AccessibleDescription = null;
this.btnConvert.AccessibleName = null;
resources.ApplyResources(this.btnConvert, "btnConvert"); resources.ApplyResources(this.btnConvert, "btnConvert");
this.btnConvert.BackgroundImage = null;
this.btnConvert.Font = null;
this.btnConvert.Name = "btnConvert"; this.btnConvert.Name = "btnConvert";
this.toolTip1.SetToolTip(this.btnConvert, resources.GetString("btnConvert.ToolTip"));
this.btnConvert.UseVisualStyleBackColor = true; this.btnConvert.UseVisualStyleBackColor = true;
this.btnConvert.Click += new System.EventHandler(this.btnConvert_Click); this.btnConvert.Click += new System.EventHandler(this.btnConvert_Click);
// //
// grpCUEPaths // grpCUEPaths
// //
this.grpCUEPaths.AccessibleDescription = null;
this.grpCUEPaths.AccessibleName = null;
resources.ApplyResources(this.grpCUEPaths, "grpCUEPaths");
this.grpCUEPaths.BackgroundImage = null;
this.grpCUEPaths.Controls.Add(this.btnBrowseOutput); this.grpCUEPaths.Controls.Add(this.btnBrowseOutput);
this.grpCUEPaths.Controls.Add(this.btnBrowseInput); this.grpCUEPaths.Controls.Add(this.btnBrowseInput);
this.grpCUEPaths.Controls.Add(this.lblOutput); this.grpCUEPaths.Controls.Add(this.lblOutput);
this.grpCUEPaths.Controls.Add(this.lblInput); this.grpCUEPaths.Controls.Add(this.lblInput);
this.grpCUEPaths.Controls.Add(this.txtOutputPath); this.grpCUEPaths.Controls.Add(this.txtOutputPath);
this.grpCUEPaths.Controls.Add(this.txtInputPath); this.grpCUEPaths.Controls.Add(this.txtInputPath);
resources.ApplyResources(this.grpCUEPaths, "grpCUEPaths"); this.grpCUEPaths.Font = null;
this.grpCUEPaths.Name = "grpCUEPaths"; this.grpCUEPaths.Name = "grpCUEPaths";
this.grpCUEPaths.TabStop = false; this.grpCUEPaths.TabStop = false;
this.toolTip1.SetToolTip(this.grpCUEPaths, resources.GetString("grpCUEPaths.ToolTip"));
// //
// btnBrowseOutput // btnBrowseOutput
// //
this.btnBrowseOutput.AccessibleDescription = null;
this.btnBrowseOutput.AccessibleName = null;
resources.ApplyResources(this.btnBrowseOutput, "btnBrowseOutput"); resources.ApplyResources(this.btnBrowseOutput, "btnBrowseOutput");
this.btnBrowseOutput.BackgroundImage = null;
this.btnBrowseOutput.Font = null;
this.btnBrowseOutput.Name = "btnBrowseOutput"; this.btnBrowseOutput.Name = "btnBrowseOutput";
this.toolTip1.SetToolTip(this.btnBrowseOutput, resources.GetString("btnBrowseOutput.ToolTip"));
this.btnBrowseOutput.UseVisualStyleBackColor = true; this.btnBrowseOutput.UseVisualStyleBackColor = true;
this.btnBrowseOutput.Click += new System.EventHandler(this.btnBrowseOutput_Click); this.btnBrowseOutput.Click += new System.EventHandler(this.btnBrowseOutput_Click);
// //
// btnBrowseInput // btnBrowseInput
// //
this.btnBrowseInput.AccessibleDescription = null;
this.btnBrowseInput.AccessibleName = null;
resources.ApplyResources(this.btnBrowseInput, "btnBrowseInput"); resources.ApplyResources(this.btnBrowseInput, "btnBrowseInput");
this.btnBrowseInput.BackgroundImage = null;
this.btnBrowseInput.Font = null;
this.btnBrowseInput.Name = "btnBrowseInput"; this.btnBrowseInput.Name = "btnBrowseInput";
this.toolTip1.SetToolTip(this.btnBrowseInput, resources.GetString("btnBrowseInput.ToolTip"));
this.btnBrowseInput.UseVisualStyleBackColor = true; this.btnBrowseInput.UseVisualStyleBackColor = true;
this.btnBrowseInput.Click += new System.EventHandler(this.btnBrowseInput_Click); this.btnBrowseInput.Click += new System.EventHandler(this.btnBrowseInput_Click);
// //
// lblOutput // lblOutput
// //
this.lblOutput.AccessibleDescription = null;
this.lblOutput.AccessibleName = null;
resources.ApplyResources(this.lblOutput, "lblOutput"); resources.ApplyResources(this.lblOutput, "lblOutput");
this.lblOutput.Font = null;
this.lblOutput.Name = "lblOutput"; this.lblOutput.Name = "lblOutput";
this.toolTip1.SetToolTip(this.lblOutput, resources.GetString("lblOutput.ToolTip"));
// //
// lblInput // lblInput
// //
this.lblInput.AccessibleDescription = null;
this.lblInput.AccessibleName = null;
resources.ApplyResources(this.lblInput, "lblInput"); resources.ApplyResources(this.lblInput, "lblInput");
this.lblInput.Font = null;
this.lblInput.Name = "lblInput"; this.lblInput.Name = "lblInput";
this.toolTip1.SetToolTip(this.lblInput, resources.GetString("lblInput.ToolTip"));
// //
// txtOutputPath // txtOutputPath
// //
this.txtOutputPath.AccessibleDescription = null;
this.txtOutputPath.AccessibleName = null;
this.txtOutputPath.AllowDrop = true; this.txtOutputPath.AllowDrop = true;
resources.ApplyResources(this.txtOutputPath, "txtOutputPath"); resources.ApplyResources(this.txtOutputPath, "txtOutputPath");
this.txtOutputPath.BackgroundImage = null;
this.txtOutputPath.Font = null;
this.txtOutputPath.Name = "txtOutputPath"; this.txtOutputPath.Name = "txtOutputPath";
this.toolTip1.SetToolTip(this.txtOutputPath, resources.GetString("txtOutputPath.ToolTip"));
this.txtOutputPath.DragDrop += new System.Windows.Forms.DragEventHandler(this.PathTextBox_DragDrop); this.txtOutputPath.DragDrop += new System.Windows.Forms.DragEventHandler(this.PathTextBox_DragDrop);
this.txtOutputPath.DragEnter += new System.Windows.Forms.DragEventHandler(this.PathTextBox_DragEnter); this.txtOutputPath.DragEnter += new System.Windows.Forms.DragEventHandler(this.PathTextBox_DragEnter);
// //
// txtInputPath // txtInputPath
// //
this.txtInputPath.AccessibleDescription = null;
this.txtInputPath.AccessibleName = null;
this.txtInputPath.AllowDrop = true; this.txtInputPath.AllowDrop = true;
resources.ApplyResources(this.txtInputPath, "txtInputPath"); resources.ApplyResources(this.txtInputPath, "txtInputPath");
this.txtInputPath.BackgroundImage = null;
this.txtInputPath.Font = null;
this.txtInputPath.Name = "txtInputPath"; this.txtInputPath.Name = "txtInputPath";
this.toolTip1.SetToolTip(this.txtInputPath, resources.GetString("txtInputPath.ToolTip"));
this.txtInputPath.TextChanged += new System.EventHandler(this.txtInputPath_TextChanged); this.txtInputPath.TextChanged += new System.EventHandler(this.txtInputPath_TextChanged);
this.txtInputPath.DragDrop += new System.Windows.Forms.DragEventHandler(this.PathTextBox_DragDrop); this.txtInputPath.DragDrop += new System.Windows.Forms.DragEventHandler(this.PathTextBox_DragDrop);
this.txtInputPath.DragEnter += new System.Windows.Forms.DragEventHandler(this.PathTextBox_DragEnter); this.txtInputPath.DragEnter += new System.Windows.Forms.DragEventHandler(this.PathTextBox_DragEnter);
// //
// grpOutputStyle // grpOutputStyle
// //
this.grpOutputStyle.AccessibleDescription = null;
this.grpOutputStyle.AccessibleName = null;
resources.ApplyResources(this.grpOutputStyle, "grpOutputStyle");
this.grpOutputStyle.BackgroundImage = null;
this.grpOutputStyle.Controls.Add(this.rbEmbedCUE); this.grpOutputStyle.Controls.Add(this.rbEmbedCUE);
this.grpOutputStyle.Controls.Add(this.rbGapsLeftOut); this.grpOutputStyle.Controls.Add(this.rbGapsLeftOut);
this.grpOutputStyle.Controls.Add(this.rbGapsPrepended); this.grpOutputStyle.Controls.Add(this.rbGapsPrepended);
this.grpOutputStyle.Controls.Add(this.rbGapsAppended); this.grpOutputStyle.Controls.Add(this.rbGapsAppended);
this.grpOutputStyle.Controls.Add(this.rbSingleFile); this.grpOutputStyle.Controls.Add(this.rbSingleFile);
resources.ApplyResources(this.grpOutputStyle, "grpOutputStyle"); this.grpOutputStyle.Font = null;
this.grpOutputStyle.Name = "grpOutputStyle"; this.grpOutputStyle.Name = "grpOutputStyle";
this.grpOutputStyle.TabStop = false; this.grpOutputStyle.TabStop = false;
this.toolTip1.SetToolTip(this.grpOutputStyle, resources.GetString("grpOutputStyle.ToolTip"));
// //
// rbEmbedCUE // rbEmbedCUE
// //
this.rbEmbedCUE.AccessibleDescription = null;
this.rbEmbedCUE.AccessibleName = null;
resources.ApplyResources(this.rbEmbedCUE, "rbEmbedCUE"); resources.ApplyResources(this.rbEmbedCUE, "rbEmbedCUE");
this.rbEmbedCUE.BackgroundImage = null;
this.rbEmbedCUE.Font = null;
this.rbEmbedCUE.Name = "rbEmbedCUE"; this.rbEmbedCUE.Name = "rbEmbedCUE";
this.rbEmbedCUE.TabStop = true; this.rbEmbedCUE.TabStop = true;
this.toolTip1.SetToolTip(this.rbEmbedCUE, resources.GetString("rbEmbedCUE.ToolTip")); this.toolTip1.SetToolTip(this.rbEmbedCUE, resources.GetString("rbEmbedCUE.ToolTip"));
@@ -170,29 +217,45 @@ namespace JDP {
// //
// rbGapsLeftOut // rbGapsLeftOut
// //
this.rbGapsLeftOut.AccessibleDescription = null;
this.rbGapsLeftOut.AccessibleName = null;
resources.ApplyResources(this.rbGapsLeftOut, "rbGapsLeftOut"); resources.ApplyResources(this.rbGapsLeftOut, "rbGapsLeftOut");
this.rbGapsLeftOut.BackgroundImage = null;
this.rbGapsLeftOut.Font = null;
this.rbGapsLeftOut.Name = "rbGapsLeftOut"; this.rbGapsLeftOut.Name = "rbGapsLeftOut";
this.toolTip1.SetToolTip(this.rbGapsLeftOut, resources.GetString("rbGapsLeftOut.ToolTip")); this.toolTip1.SetToolTip(this.rbGapsLeftOut, resources.GetString("rbGapsLeftOut.ToolTip"));
this.rbGapsLeftOut.UseVisualStyleBackColor = true; this.rbGapsLeftOut.UseVisualStyleBackColor = true;
// //
// rbGapsPrepended // rbGapsPrepended
// //
this.rbGapsPrepended.AccessibleDescription = null;
this.rbGapsPrepended.AccessibleName = null;
resources.ApplyResources(this.rbGapsPrepended, "rbGapsPrepended"); resources.ApplyResources(this.rbGapsPrepended, "rbGapsPrepended");
this.rbGapsPrepended.BackgroundImage = null;
this.rbGapsPrepended.Font = null;
this.rbGapsPrepended.Name = "rbGapsPrepended"; this.rbGapsPrepended.Name = "rbGapsPrepended";
this.toolTip1.SetToolTip(this.rbGapsPrepended, resources.GetString("rbGapsPrepended.ToolTip")); this.toolTip1.SetToolTip(this.rbGapsPrepended, resources.GetString("rbGapsPrepended.ToolTip"));
this.rbGapsPrepended.UseVisualStyleBackColor = true; this.rbGapsPrepended.UseVisualStyleBackColor = true;
// //
// rbGapsAppended // rbGapsAppended
// //
this.rbGapsAppended.AccessibleDescription = null;
this.rbGapsAppended.AccessibleName = null;
resources.ApplyResources(this.rbGapsAppended, "rbGapsAppended"); resources.ApplyResources(this.rbGapsAppended, "rbGapsAppended");
this.rbGapsAppended.BackgroundImage = null;
this.rbGapsAppended.Font = null;
this.rbGapsAppended.Name = "rbGapsAppended"; this.rbGapsAppended.Name = "rbGapsAppended";
this.toolTip1.SetToolTip(this.rbGapsAppended, resources.GetString("rbGapsAppended.ToolTip")); this.toolTip1.SetToolTip(this.rbGapsAppended, resources.GetString("rbGapsAppended.ToolTip"));
this.rbGapsAppended.UseVisualStyleBackColor = true; this.rbGapsAppended.UseVisualStyleBackColor = true;
// //
// rbSingleFile // rbSingleFile
// //
this.rbSingleFile.AccessibleDescription = null;
this.rbSingleFile.AccessibleName = null;
resources.ApplyResources(this.rbSingleFile, "rbSingleFile"); resources.ApplyResources(this.rbSingleFile, "rbSingleFile");
this.rbSingleFile.BackgroundImage = null;
this.rbSingleFile.Checked = true; this.rbSingleFile.Checked = true;
this.rbSingleFile.Font = null;
this.rbSingleFile.Name = "rbSingleFile"; this.rbSingleFile.Name = "rbSingleFile";
this.rbSingleFile.TabStop = true; this.rbSingleFile.TabStop = true;
this.toolTip1.SetToolTip(this.rbSingleFile, resources.GetString("rbSingleFile.ToolTip")); this.toolTip1.SetToolTip(this.rbSingleFile, resources.GetString("rbSingleFile.ToolTip"));
@@ -200,13 +263,22 @@ namespace JDP {
// //
// btnAbout // btnAbout
// //
this.btnAbout.AccessibleDescription = null;
this.btnAbout.AccessibleName = null;
resources.ApplyResources(this.btnAbout, "btnAbout"); resources.ApplyResources(this.btnAbout, "btnAbout");
this.btnAbout.BackgroundImage = null;
this.btnAbout.Font = null;
this.btnAbout.Name = "btnAbout"; this.btnAbout.Name = "btnAbout";
this.toolTip1.SetToolTip(this.btnAbout, resources.GetString("btnAbout.ToolTip"));
this.btnAbout.UseVisualStyleBackColor = true; this.btnAbout.UseVisualStyleBackColor = true;
this.btnAbout.Click += new System.EventHandler(this.btnAbout_Click); this.btnAbout.Click += new System.EventHandler(this.btnAbout_Click);
// //
// grpOutputPathGeneration // grpOutputPathGeneration
// //
this.grpOutputPathGeneration.AccessibleDescription = null;
this.grpOutputPathGeneration.AccessibleName = null;
resources.ApplyResources(this.grpOutputPathGeneration, "grpOutputPathGeneration");
this.grpOutputPathGeneration.BackgroundImage = null;
this.grpOutputPathGeneration.Controls.Add(this.txtCustomFormat); this.grpOutputPathGeneration.Controls.Add(this.txtCustomFormat);
this.grpOutputPathGeneration.Controls.Add(this.rbCustomFormat); this.grpOutputPathGeneration.Controls.Add(this.rbCustomFormat);
this.grpOutputPathGeneration.Controls.Add(this.txtCreateSubdirectory); this.grpOutputPathGeneration.Controls.Add(this.txtCreateSubdirectory);
@@ -214,60 +286,100 @@ namespace JDP {
this.grpOutputPathGeneration.Controls.Add(this.rbCreateSubdirectory); this.grpOutputPathGeneration.Controls.Add(this.rbCreateSubdirectory);
this.grpOutputPathGeneration.Controls.Add(this.rbAppendFilename); this.grpOutputPathGeneration.Controls.Add(this.rbAppendFilename);
this.grpOutputPathGeneration.Controls.Add(this.txtAppendFilename); this.grpOutputPathGeneration.Controls.Add(this.txtAppendFilename);
resources.ApplyResources(this.grpOutputPathGeneration, "grpOutputPathGeneration"); this.grpOutputPathGeneration.Font = null;
this.grpOutputPathGeneration.Name = "grpOutputPathGeneration"; this.grpOutputPathGeneration.Name = "grpOutputPathGeneration";
this.grpOutputPathGeneration.TabStop = false; this.grpOutputPathGeneration.TabStop = false;
this.toolTip1.SetToolTip(this.grpOutputPathGeneration, resources.GetString("grpOutputPathGeneration.ToolTip"));
// //
// txtCustomFormat // txtCustomFormat
// //
this.txtCustomFormat.AccessibleDescription = null;
this.txtCustomFormat.AccessibleName = null;
resources.ApplyResources(this.txtCustomFormat, "txtCustomFormat"); resources.ApplyResources(this.txtCustomFormat, "txtCustomFormat");
this.txtCustomFormat.BackgroundImage = null;
this.txtCustomFormat.Font = null;
this.txtCustomFormat.Name = "txtCustomFormat"; this.txtCustomFormat.Name = "txtCustomFormat";
this.toolTip1.SetToolTip(this.txtCustomFormat, resources.GetString("txtCustomFormat.ToolTip"));
this.txtCustomFormat.TextChanged += new System.EventHandler(this.txtCustomFormat_TextChanged); this.txtCustomFormat.TextChanged += new System.EventHandler(this.txtCustomFormat_TextChanged);
// //
// rbCustomFormat // rbCustomFormat
// //
this.rbCustomFormat.AccessibleDescription = null;
this.rbCustomFormat.AccessibleName = null;
resources.ApplyResources(this.rbCustomFormat, "rbCustomFormat"); resources.ApplyResources(this.rbCustomFormat, "rbCustomFormat");
this.rbCustomFormat.BackgroundImage = null;
this.rbCustomFormat.Font = null;
this.rbCustomFormat.Name = "rbCustomFormat"; this.rbCustomFormat.Name = "rbCustomFormat";
this.rbCustomFormat.TabStop = true; this.rbCustomFormat.TabStop = true;
this.toolTip1.SetToolTip(this.rbCustomFormat, resources.GetString("rbCustomFormat.ToolTip"));
this.rbCustomFormat.UseVisualStyleBackColor = true; this.rbCustomFormat.UseVisualStyleBackColor = true;
this.rbCustomFormat.CheckedChanged += new System.EventHandler(this.rbCustomFormat_CheckedChanged); this.rbCustomFormat.CheckedChanged += new System.EventHandler(this.rbCustomFormat_CheckedChanged);
// //
// txtCreateSubdirectory // txtCreateSubdirectory
// //
this.txtCreateSubdirectory.AccessibleDescription = null;
this.txtCreateSubdirectory.AccessibleName = null;
resources.ApplyResources(this.txtCreateSubdirectory, "txtCreateSubdirectory"); resources.ApplyResources(this.txtCreateSubdirectory, "txtCreateSubdirectory");
this.txtCreateSubdirectory.BackgroundImage = null;
this.txtCreateSubdirectory.Font = null;
this.txtCreateSubdirectory.Name = "txtCreateSubdirectory"; this.txtCreateSubdirectory.Name = "txtCreateSubdirectory";
this.toolTip1.SetToolTip(this.txtCreateSubdirectory, resources.GetString("txtCreateSubdirectory.ToolTip"));
this.txtCreateSubdirectory.TextChanged += new System.EventHandler(this.txtCreateSubdirectory_TextChanged); this.txtCreateSubdirectory.TextChanged += new System.EventHandler(this.txtCreateSubdirectory_TextChanged);
// //
// rbDontGenerate // rbDontGenerate
// //
this.rbDontGenerate.AccessibleDescription = null;
this.rbDontGenerate.AccessibleName = null;
resources.ApplyResources(this.rbDontGenerate, "rbDontGenerate"); resources.ApplyResources(this.rbDontGenerate, "rbDontGenerate");
this.rbDontGenerate.BackgroundImage = null;
this.rbDontGenerate.Font = null;
this.rbDontGenerate.Name = "rbDontGenerate"; this.rbDontGenerate.Name = "rbDontGenerate";
this.toolTip1.SetToolTip(this.rbDontGenerate, resources.GetString("rbDontGenerate.ToolTip"));
this.rbDontGenerate.UseVisualStyleBackColor = true; this.rbDontGenerate.UseVisualStyleBackColor = true;
// //
// rbCreateSubdirectory // rbCreateSubdirectory
// //
this.rbCreateSubdirectory.AccessibleDescription = null;
this.rbCreateSubdirectory.AccessibleName = null;
resources.ApplyResources(this.rbCreateSubdirectory, "rbCreateSubdirectory"); resources.ApplyResources(this.rbCreateSubdirectory, "rbCreateSubdirectory");
this.rbCreateSubdirectory.BackgroundImage = null;
this.rbCreateSubdirectory.Checked = true; this.rbCreateSubdirectory.Checked = true;
this.rbCreateSubdirectory.Font = null;
this.rbCreateSubdirectory.Name = "rbCreateSubdirectory"; this.rbCreateSubdirectory.Name = "rbCreateSubdirectory";
this.rbCreateSubdirectory.TabStop = true; this.rbCreateSubdirectory.TabStop = true;
this.toolTip1.SetToolTip(this.rbCreateSubdirectory, resources.GetString("rbCreateSubdirectory.ToolTip"));
this.rbCreateSubdirectory.UseVisualStyleBackColor = true; this.rbCreateSubdirectory.UseVisualStyleBackColor = true;
this.rbCreateSubdirectory.CheckedChanged += new System.EventHandler(this.rbCreateSubdirectory_CheckedChanged); this.rbCreateSubdirectory.CheckedChanged += new System.EventHandler(this.rbCreateSubdirectory_CheckedChanged);
// //
// rbAppendFilename // rbAppendFilename
// //
this.rbAppendFilename.AccessibleDescription = null;
this.rbAppendFilename.AccessibleName = null;
resources.ApplyResources(this.rbAppendFilename, "rbAppendFilename"); resources.ApplyResources(this.rbAppendFilename, "rbAppendFilename");
this.rbAppendFilename.BackgroundImage = null;
this.rbAppendFilename.Font = null;
this.rbAppendFilename.Name = "rbAppendFilename"; this.rbAppendFilename.Name = "rbAppendFilename";
this.toolTip1.SetToolTip(this.rbAppendFilename, resources.GetString("rbAppendFilename.ToolTip"));
this.rbAppendFilename.UseVisualStyleBackColor = true; this.rbAppendFilename.UseVisualStyleBackColor = true;
this.rbAppendFilename.CheckedChanged += new System.EventHandler(this.rbAppendFilename_CheckedChanged); this.rbAppendFilename.CheckedChanged += new System.EventHandler(this.rbAppendFilename_CheckedChanged);
// //
// txtAppendFilename // txtAppendFilename
// //
this.txtAppendFilename.AccessibleDescription = null;
this.txtAppendFilename.AccessibleName = null;
resources.ApplyResources(this.txtAppendFilename, "txtAppendFilename"); resources.ApplyResources(this.txtAppendFilename, "txtAppendFilename");
this.txtAppendFilename.BackgroundImage = null;
this.txtAppendFilename.Font = null;
this.txtAppendFilename.Name = "txtAppendFilename"; this.txtAppendFilename.Name = "txtAppendFilename";
this.toolTip1.SetToolTip(this.txtAppendFilename, resources.GetString("txtAppendFilename.ToolTip"));
this.txtAppendFilename.TextChanged += new System.EventHandler(this.txtAppendFilename_TextChanged); this.txtAppendFilename.TextChanged += new System.EventHandler(this.txtAppendFilename_TextChanged);
// //
// grpAudioOutput // grpAudioOutput
// //
this.grpAudioOutput.AccessibleDescription = null;
this.grpAudioOutput.AccessibleName = null;
resources.ApplyResources(this.grpAudioOutput, "grpAudioOutput");
this.grpAudioOutput.BackgroundImage = null;
this.grpAudioOutput.Controls.Add(this.rbTTA); this.grpAudioOutput.Controls.Add(this.rbTTA);
this.grpAudioOutput.Controls.Add(this.chkLossyWAV); this.grpAudioOutput.Controls.Add(this.chkLossyWAV);
this.grpAudioOutput.Controls.Add(this.rbAPE); this.grpAudioOutput.Controls.Add(this.rbAPE);
@@ -275,21 +387,31 @@ namespace JDP {
this.grpAudioOutput.Controls.Add(this.rbWavPack); this.grpAudioOutput.Controls.Add(this.rbWavPack);
this.grpAudioOutput.Controls.Add(this.rbWAV); this.grpAudioOutput.Controls.Add(this.rbWAV);
this.grpAudioOutput.Controls.Add(this.rbFLAC); this.grpAudioOutput.Controls.Add(this.rbFLAC);
resources.ApplyResources(this.grpAudioOutput, "grpAudioOutput"); this.grpAudioOutput.Font = null;
this.grpAudioOutput.Name = "grpAudioOutput"; this.grpAudioOutput.Name = "grpAudioOutput";
this.grpAudioOutput.TabStop = false; this.grpAudioOutput.TabStop = false;
this.toolTip1.SetToolTip(this.grpAudioOutput, resources.GetString("grpAudioOutput.ToolTip"));
// //
// rbTTA // rbTTA
// //
this.rbTTA.AccessibleDescription = null;
this.rbTTA.AccessibleName = null;
resources.ApplyResources(this.rbTTA, "rbTTA"); resources.ApplyResources(this.rbTTA, "rbTTA");
this.rbTTA.BackgroundImage = null;
this.rbTTA.Font = null;
this.rbTTA.Name = "rbTTA"; this.rbTTA.Name = "rbTTA";
this.rbTTA.TabStop = true; this.rbTTA.TabStop = true;
this.toolTip1.SetToolTip(this.rbTTA, resources.GetString("rbTTA.ToolTip"));
this.rbTTA.UseVisualStyleBackColor = true; this.rbTTA.UseVisualStyleBackColor = true;
this.rbTTA.CheckedChanged += new System.EventHandler(this.rbTTA_CheckedChanged); this.rbTTA.CheckedChanged += new System.EventHandler(this.rbTTA_CheckedChanged);
// //
// chkLossyWAV // chkLossyWAV
// //
this.chkLossyWAV.AccessibleDescription = null;
this.chkLossyWAV.AccessibleName = null;
resources.ApplyResources(this.chkLossyWAV, "chkLossyWAV"); resources.ApplyResources(this.chkLossyWAV, "chkLossyWAV");
this.chkLossyWAV.BackgroundImage = null;
this.chkLossyWAV.Font = null;
this.chkLossyWAV.Name = "chkLossyWAV"; this.chkLossyWAV.Name = "chkLossyWAV";
this.toolTip1.SetToolTip(this.chkLossyWAV, resources.GetString("chkLossyWAV.ToolTip")); this.toolTip1.SetToolTip(this.chkLossyWAV, resources.GetString("chkLossyWAV.ToolTip"));
this.chkLossyWAV.UseVisualStyleBackColor = true; this.chkLossyWAV.UseVisualStyleBackColor = true;
@@ -297,15 +419,24 @@ namespace JDP {
// //
// rbAPE // rbAPE
// //
this.rbAPE.AccessibleDescription = null;
this.rbAPE.AccessibleName = null;
resources.ApplyResources(this.rbAPE, "rbAPE"); resources.ApplyResources(this.rbAPE, "rbAPE");
this.rbAPE.BackgroundImage = null;
this.rbAPE.Font = null;
this.rbAPE.Name = "rbAPE"; this.rbAPE.Name = "rbAPE";
this.rbAPE.TabStop = true; this.rbAPE.TabStop = true;
this.toolTip1.SetToolTip(this.rbAPE, resources.GetString("rbAPE.ToolTip"));
this.rbAPE.UseVisualStyleBackColor = true; this.rbAPE.UseVisualStyleBackColor = true;
this.rbAPE.CheckedChanged += new System.EventHandler(this.rbAPE_CheckedChanged); this.rbAPE.CheckedChanged += new System.EventHandler(this.rbAPE_CheckedChanged);
// //
// rbNoAudio // rbNoAudio
// //
this.rbNoAudio.AccessibleDescription = null;
this.rbNoAudio.AccessibleName = null;
resources.ApplyResources(this.rbNoAudio, "rbNoAudio"); resources.ApplyResources(this.rbNoAudio, "rbNoAudio");
this.rbNoAudio.BackgroundImage = null;
this.rbNoAudio.Font = null;
this.rbNoAudio.Name = "rbNoAudio"; this.rbNoAudio.Name = "rbNoAudio";
this.toolTip1.SetToolTip(this.rbNoAudio, resources.GetString("rbNoAudio.ToolTip")); this.toolTip1.SetToolTip(this.rbNoAudio, resources.GetString("rbNoAudio.ToolTip"));
this.rbNoAudio.UseVisualStyleBackColor = true; this.rbNoAudio.UseVisualStyleBackColor = true;
@@ -313,85 +444,137 @@ namespace JDP {
// //
// rbWavPack // rbWavPack
// //
this.rbWavPack.AccessibleDescription = null;
this.rbWavPack.AccessibleName = null;
resources.ApplyResources(this.rbWavPack, "rbWavPack"); resources.ApplyResources(this.rbWavPack, "rbWavPack");
this.rbWavPack.BackgroundImage = null;
this.rbWavPack.Font = null;
this.rbWavPack.Name = "rbWavPack"; this.rbWavPack.Name = "rbWavPack";
this.toolTip1.SetToolTip(this.rbWavPack, resources.GetString("rbWavPack.ToolTip"));
this.rbWavPack.UseVisualStyleBackColor = true; this.rbWavPack.UseVisualStyleBackColor = true;
this.rbWavPack.CheckedChanged += new System.EventHandler(this.rbWavPack_CheckedChanged); this.rbWavPack.CheckedChanged += new System.EventHandler(this.rbWavPack_CheckedChanged);
// //
// rbWAV // rbWAV
// //
this.rbWAV.AccessibleDescription = null;
this.rbWAV.AccessibleName = null;
resources.ApplyResources(this.rbWAV, "rbWAV"); resources.ApplyResources(this.rbWAV, "rbWAV");
this.rbWAV.BackgroundImage = null;
this.rbWAV.Checked = true; this.rbWAV.Checked = true;
this.rbWAV.Font = null;
this.rbWAV.Name = "rbWAV"; this.rbWAV.Name = "rbWAV";
this.rbWAV.TabStop = true; this.rbWAV.TabStop = true;
this.toolTip1.SetToolTip(this.rbWAV, resources.GetString("rbWAV.ToolTip"));
this.rbWAV.UseVisualStyleBackColor = true; this.rbWAV.UseVisualStyleBackColor = true;
this.rbWAV.CheckedChanged += new System.EventHandler(this.rbWAV_CheckedChanged); this.rbWAV.CheckedChanged += new System.EventHandler(this.rbWAV_CheckedChanged);
// //
// rbFLAC // rbFLAC
// //
this.rbFLAC.AccessibleDescription = null;
this.rbFLAC.AccessibleName = null;
resources.ApplyResources(this.rbFLAC, "rbFLAC"); resources.ApplyResources(this.rbFLAC, "rbFLAC");
this.rbFLAC.BackgroundImage = null;
this.rbFLAC.Font = null;
this.rbFLAC.Name = "rbFLAC"; this.rbFLAC.Name = "rbFLAC";
this.toolTip1.SetToolTip(this.rbFLAC, resources.GetString("rbFLAC.ToolTip"));
this.rbFLAC.UseVisualStyleBackColor = true; this.rbFLAC.UseVisualStyleBackColor = true;
this.rbFLAC.CheckedChanged += new System.EventHandler(this.rbFLAC_CheckedChanged); this.rbFLAC.CheckedChanged += new System.EventHandler(this.rbFLAC_CheckedChanged);
// //
// btnBatch // btnBatch
// //
this.btnBatch.AccessibleDescription = null;
this.btnBatch.AccessibleName = null;
resources.ApplyResources(this.btnBatch, "btnBatch"); resources.ApplyResources(this.btnBatch, "btnBatch");
this.btnBatch.BackgroundImage = null;
this.btnBatch.Font = null;
this.btnBatch.Name = "btnBatch"; this.btnBatch.Name = "btnBatch";
this.toolTip1.SetToolTip(this.btnBatch, resources.GetString("btnBatch.ToolTip"));
this.btnBatch.UseVisualStyleBackColor = true; this.btnBatch.UseVisualStyleBackColor = true;
this.btnBatch.Click += new System.EventHandler(this.btnBatch_Click); this.btnBatch.Click += new System.EventHandler(this.btnBatch_Click);
// //
// btnFilenameCorrector // btnFilenameCorrector
// //
this.btnFilenameCorrector.AccessibleDescription = null;
this.btnFilenameCorrector.AccessibleName = null;
resources.ApplyResources(this.btnFilenameCorrector, "btnFilenameCorrector"); resources.ApplyResources(this.btnFilenameCorrector, "btnFilenameCorrector");
this.btnFilenameCorrector.BackgroundImage = null;
this.btnFilenameCorrector.Font = null;
this.btnFilenameCorrector.Name = "btnFilenameCorrector"; this.btnFilenameCorrector.Name = "btnFilenameCorrector";
this.toolTip1.SetToolTip(this.btnFilenameCorrector, resources.GetString("btnFilenameCorrector.ToolTip"));
this.btnFilenameCorrector.UseVisualStyleBackColor = true; this.btnFilenameCorrector.UseVisualStyleBackColor = true;
this.btnFilenameCorrector.Click += new System.EventHandler(this.btnFilenameCorrector_Click); this.btnFilenameCorrector.Click += new System.EventHandler(this.btnFilenameCorrector_Click);
// //
// btnSettings // btnSettings
// //
this.btnSettings.AccessibleDescription = null;
this.btnSettings.AccessibleName = null;
resources.ApplyResources(this.btnSettings, "btnSettings"); resources.ApplyResources(this.btnSettings, "btnSettings");
this.btnSettings.BackgroundImage = null;
this.btnSettings.Font = null;
this.btnSettings.Name = "btnSettings"; this.btnSettings.Name = "btnSettings";
this.toolTip1.SetToolTip(this.btnSettings, resources.GetString("btnSettings.ToolTip"));
this.btnSettings.UseVisualStyleBackColor = true; this.btnSettings.UseVisualStyleBackColor = true;
this.btnSettings.Click += new System.EventHandler(this.btnSettings_Click); this.btnSettings.Click += new System.EventHandler(this.btnSettings_Click);
// //
// grpAccurateRip // grpAccurateRip
// //
this.grpAccurateRip.AccessibleDescription = null;
this.grpAccurateRip.AccessibleName = null;
resources.ApplyResources(this.grpAccurateRip, "grpAccurateRip");
this.grpAccurateRip.BackgroundImage = null;
this.grpAccurateRip.Controls.Add(this.rbArAndEncode); this.grpAccurateRip.Controls.Add(this.rbArAndEncode);
this.grpAccurateRip.Controls.Add(this.label1); this.grpAccurateRip.Controls.Add(this.label1);
this.grpAccurateRip.Controls.Add(this.txtDataTrackLength); this.grpAccurateRip.Controls.Add(this.txtDataTrackLength);
this.grpAccurateRip.Controls.Add(this.rbArApplyOffset); this.grpAccurateRip.Controls.Add(this.rbArApplyOffset);
this.grpAccurateRip.Controls.Add(this.rbArVerify); this.grpAccurateRip.Controls.Add(this.rbArVerify);
this.grpAccurateRip.Controls.Add(this.rbArNone); this.grpAccurateRip.Controls.Add(this.rbArNone);
resources.ApplyResources(this.grpAccurateRip, "grpAccurateRip"); this.grpAccurateRip.Font = null;
this.grpAccurateRip.Name = "grpAccurateRip"; this.grpAccurateRip.Name = "grpAccurateRip";
this.grpAccurateRip.TabStop = false; this.grpAccurateRip.TabStop = false;
this.toolTip1.SetToolTip(this.grpAccurateRip, resources.GetString("grpAccurateRip.ToolTip"));
// //
// rbArAndEncode // rbArAndEncode
// //
this.rbArAndEncode.AccessibleDescription = null;
this.rbArAndEncode.AccessibleName = null;
resources.ApplyResources(this.rbArAndEncode, "rbArAndEncode"); resources.ApplyResources(this.rbArAndEncode, "rbArAndEncode");
this.rbArAndEncode.BackgroundImage = null;
this.rbArAndEncode.Font = null;
this.rbArAndEncode.Name = "rbArAndEncode"; this.rbArAndEncode.Name = "rbArAndEncode";
this.rbArAndEncode.TabStop = true; this.rbArAndEncode.TabStop = true;
this.toolTip1.SetToolTip(this.rbArAndEncode, resources.GetString("rbArAndEncode.ToolTip"));
this.rbArAndEncode.UseVisualStyleBackColor = true; this.rbArAndEncode.UseVisualStyleBackColor = true;
// //
// label1 // label1
// //
this.label1.AccessibleDescription = null;
this.label1.AccessibleName = null;
resources.ApplyResources(this.label1, "label1"); resources.ApplyResources(this.label1, "label1");
this.label1.Font = null;
this.label1.Name = "label1"; this.label1.Name = "label1";
this.toolTip1.SetToolTip(this.label1, resources.GetString("label1.ToolTip"));
// //
// txtDataTrackLength // txtDataTrackLength
// //
this.txtDataTrackLength.AccessibleDescription = null;
this.txtDataTrackLength.AccessibleName = null;
resources.ApplyResources(this.txtDataTrackLength, "txtDataTrackLength");
this.txtDataTrackLength.BackgroundImage = null;
this.txtDataTrackLength.Culture = new System.Globalization.CultureInfo(""); this.txtDataTrackLength.Culture = new System.Globalization.CultureInfo("");
this.txtDataTrackLength.CutCopyMaskFormat = System.Windows.Forms.MaskFormat.IncludePromptAndLiterals; this.txtDataTrackLength.CutCopyMaskFormat = System.Windows.Forms.MaskFormat.IncludePromptAndLiterals;
this.txtDataTrackLength.Font = null;
this.txtDataTrackLength.InsertKeyMode = System.Windows.Forms.InsertKeyMode.Overwrite; this.txtDataTrackLength.InsertKeyMode = System.Windows.Forms.InsertKeyMode.Overwrite;
resources.ApplyResources(this.txtDataTrackLength, "txtDataTrackLength");
this.txtDataTrackLength.Name = "txtDataTrackLength"; this.txtDataTrackLength.Name = "txtDataTrackLength";
this.txtDataTrackLength.TextMaskFormat = System.Windows.Forms.MaskFormat.IncludePromptAndLiterals; this.txtDataTrackLength.TextMaskFormat = System.Windows.Forms.MaskFormat.IncludePromptAndLiterals;
this.toolTip1.SetToolTip(this.txtDataTrackLength, resources.GetString("txtDataTrackLength.ToolTip")); this.toolTip1.SetToolTip(this.txtDataTrackLength, resources.GetString("txtDataTrackLength.ToolTip"));
// //
// rbArApplyOffset // rbArApplyOffset
// //
this.rbArApplyOffset.AccessibleDescription = null;
this.rbArApplyOffset.AccessibleName = null;
resources.ApplyResources(this.rbArApplyOffset, "rbArApplyOffset"); resources.ApplyResources(this.rbArApplyOffset, "rbArApplyOffset");
this.rbArApplyOffset.BackgroundImage = null;
this.rbArApplyOffset.Font = null;
this.rbArApplyOffset.Name = "rbArApplyOffset"; this.rbArApplyOffset.Name = "rbArApplyOffset";
this.toolTip1.SetToolTip(this.rbArApplyOffset, resources.GetString("rbArApplyOffset.ToolTip")); this.toolTip1.SetToolTip(this.rbArApplyOffset, resources.GetString("rbArApplyOffset.ToolTip"));
this.rbArApplyOffset.UseVisualStyleBackColor = true; this.rbArApplyOffset.UseVisualStyleBackColor = true;
@@ -399,7 +582,11 @@ namespace JDP {
// //
// rbArVerify // rbArVerify
// //
this.rbArVerify.AccessibleDescription = null;
this.rbArVerify.AccessibleName = null;
resources.ApplyResources(this.rbArVerify, "rbArVerify"); resources.ApplyResources(this.rbArVerify, "rbArVerify");
this.rbArVerify.BackgroundImage = null;
this.rbArVerify.Font = null;
this.rbArVerify.Name = "rbArVerify"; this.rbArVerify.Name = "rbArVerify";
this.toolTip1.SetToolTip(this.rbArVerify, resources.GetString("rbArVerify.ToolTip")); this.toolTip1.SetToolTip(this.rbArVerify, resources.GetString("rbArVerify.ToolTip"));
this.rbArVerify.UseVisualStyleBackColor = true; this.rbArVerify.UseVisualStyleBackColor = true;
@@ -407,8 +594,12 @@ namespace JDP {
// //
// rbArNone // rbArNone
// //
this.rbArNone.AccessibleDescription = null;
this.rbArNone.AccessibleName = null;
resources.ApplyResources(this.rbArNone, "rbArNone"); resources.ApplyResources(this.rbArNone, "rbArNone");
this.rbArNone.BackgroundImage = null;
this.rbArNone.Checked = true; this.rbArNone.Checked = true;
this.rbArNone.Font = null;
this.rbArNone.Name = "rbArNone"; this.rbArNone.Name = "rbArNone";
this.rbArNone.TabStop = true; this.rbArNone.TabStop = true;
this.toolTip1.SetToolTip(this.rbArNone, resources.GetString("rbArNone.ToolTip")); this.toolTip1.SetToolTip(this.rbArNone, resources.GetString("rbArNone.ToolTip"));
@@ -416,32 +607,44 @@ namespace JDP {
// //
// statusStrip1 // statusStrip1
// //
this.statusStrip1.AccessibleDescription = null;
this.statusStrip1.AccessibleName = null;
resources.ApplyResources(this.statusStrip1, "statusStrip1");
this.statusStrip1.BackgroundImage = null;
this.statusStrip1.Font = null;
this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.toolStripStatusLabel1, this.toolStripStatusLabel1,
this.toolStripProgressBar1, this.toolStripProgressBar1,
this.toolStripProgressBar2}); this.toolStripProgressBar2});
resources.ApplyResources(this.statusStrip1, "statusStrip1");
this.statusStrip1.Name = "statusStrip1"; this.statusStrip1.Name = "statusStrip1";
this.statusStrip1.SizingGrip = false; this.statusStrip1.SizingGrip = false;
this.toolTip1.SetToolTip(this.statusStrip1, resources.GetString("statusStrip1.ToolTip"));
// //
// toolStripStatusLabel1 // toolStripStatusLabel1
// //
this.toolStripStatusLabel1.Name = "toolStripStatusLabel1"; this.toolStripStatusLabel1.AccessibleDescription = null;
this.toolStripStatusLabel1.AccessibleName = null;
resources.ApplyResources(this.toolStripStatusLabel1, "toolStripStatusLabel1"); resources.ApplyResources(this.toolStripStatusLabel1, "toolStripStatusLabel1");
this.toolStripStatusLabel1.BackgroundImage = null;
this.toolStripStatusLabel1.Name = "toolStripStatusLabel1";
this.toolStripStatusLabel1.Spring = true; this.toolStripStatusLabel1.Spring = true;
// //
// toolStripProgressBar1 // toolStripProgressBar1
// //
this.toolStripProgressBar1.AccessibleDescription = null;
this.toolStripProgressBar1.AccessibleName = null;
resources.ApplyResources(this.toolStripProgressBar1, "toolStripProgressBar1");
this.toolStripProgressBar1.AutoToolTip = true; this.toolStripProgressBar1.AutoToolTip = true;
this.toolStripProgressBar1.Name = "toolStripProgressBar1"; this.toolStripProgressBar1.Name = "toolStripProgressBar1";
resources.ApplyResources(this.toolStripProgressBar1, "toolStripProgressBar1");
this.toolStripProgressBar1.Style = System.Windows.Forms.ProgressBarStyle.Continuous; this.toolStripProgressBar1.Style = System.Windows.Forms.ProgressBarStyle.Continuous;
// //
// toolStripProgressBar2 // toolStripProgressBar2
// //
this.toolStripProgressBar2.AccessibleDescription = null;
this.toolStripProgressBar2.AccessibleName = null;
resources.ApplyResources(this.toolStripProgressBar2, "toolStripProgressBar2");
this.toolStripProgressBar2.AutoToolTip = true; this.toolStripProgressBar2.AutoToolTip = true;
this.toolStripProgressBar2.Name = "toolStripProgressBar2"; this.toolStripProgressBar2.Name = "toolStripProgressBar2";
resources.ApplyResources(this.toolStripProgressBar2, "toolStripProgressBar2");
this.toolStripProgressBar2.Style = System.Windows.Forms.ProgressBarStyle.Continuous; this.toolStripProgressBar2.Style = System.Windows.Forms.ProgressBarStyle.Continuous;
// //
// toolTip1 // toolTip1
@@ -452,66 +655,109 @@ namespace JDP {
// //
// btnCUECreator // btnCUECreator
// //
this.btnCUECreator.AccessibleDescription = null;
this.btnCUECreator.AccessibleName = null;
resources.ApplyResources(this.btnCUECreator, "btnCUECreator"); resources.ApplyResources(this.btnCUECreator, "btnCUECreator");
this.btnCUECreator.BackgroundImage = null;
this.btnCUECreator.Font = null;
this.btnCUECreator.Name = "btnCUECreator"; this.btnCUECreator.Name = "btnCUECreator";
this.toolTip1.SetToolTip(this.btnCUECreator, resources.GetString("btnCUECreator.ToolTip"));
this.btnCUECreator.UseVisualStyleBackColor = true; this.btnCUECreator.UseVisualStyleBackColor = true;
this.btnCUECreator.Click += new System.EventHandler(this.btnCUECreator_Click); this.btnCUECreator.Click += new System.EventHandler(this.btnCUECreator_Click);
// //
// btnStop // btnStop
// //
this.btnStop.AccessibleDescription = null;
this.btnStop.AccessibleName = null;
resources.ApplyResources(this.btnStop, "btnStop"); resources.ApplyResources(this.btnStop, "btnStop");
this.btnStop.BackgroundImage = null;
this.btnStop.Font = null;
this.btnStop.Name = "btnStop"; this.btnStop.Name = "btnStop";
this.toolTip1.SetToolTip(this.btnStop, resources.GetString("btnStop.ToolTip"));
this.btnStop.UseVisualStyleBackColor = true; this.btnStop.UseVisualStyleBackColor = true;
this.btnStop.Click += new System.EventHandler(this.btnStop_Click); this.btnStop.Click += new System.EventHandler(this.btnStop_Click);
// //
// btnPause // btnPause
// //
this.btnPause.AccessibleDescription = null;
this.btnPause.AccessibleName = null;
resources.ApplyResources(this.btnPause, "btnPause"); resources.ApplyResources(this.btnPause, "btnPause");
this.btnPause.BackgroundImage = null;
this.btnPause.Font = null;
this.btnPause.Name = "btnPause"; this.btnPause.Name = "btnPause";
this.toolTip1.SetToolTip(this.btnPause, resources.GetString("btnPause.ToolTip"));
this.btnPause.UseVisualStyleBackColor = true; this.btnPause.UseVisualStyleBackColor = true;
this.btnPause.Click += new System.EventHandler(this.btnPause_Click); this.btnPause.Click += new System.EventHandler(this.btnPause_Click);
// //
// btnResume // btnResume
// //
this.btnResume.AccessibleDescription = null;
this.btnResume.AccessibleName = null;
resources.ApplyResources(this.btnResume, "btnResume"); resources.ApplyResources(this.btnResume, "btnResume");
this.btnResume.BackgroundImage = null;
this.btnResume.Font = null;
this.btnResume.Name = "btnResume"; this.btnResume.Name = "btnResume";
this.toolTip1.SetToolTip(this.btnResume, resources.GetString("btnResume.ToolTip"));
this.btnResume.UseVisualStyleBackColor = true; this.btnResume.UseVisualStyleBackColor = true;
this.btnResume.Click += new System.EventHandler(this.btnPause_Click); this.btnResume.Click += new System.EventHandler(this.btnPause_Click);
// //
// groupBox1 // groupBox1
// //
this.groupBox1.AccessibleDescription = null;
this.groupBox1.AccessibleName = null;
resources.ApplyResources(this.groupBox1, "groupBox1");
this.groupBox1.BackgroundImage = null;
this.groupBox1.Controls.Add(this.rbFreedbAlways); this.groupBox1.Controls.Add(this.rbFreedbAlways);
this.groupBox1.Controls.Add(this.rbFreedbIf); this.groupBox1.Controls.Add(this.rbFreedbIf);
this.groupBox1.Controls.Add(this.rbFreedbNever); this.groupBox1.Controls.Add(this.rbFreedbNever);
resources.ApplyResources(this.groupBox1, "groupBox1"); this.groupBox1.Font = null;
this.groupBox1.Name = "groupBox1"; this.groupBox1.Name = "groupBox1";
this.groupBox1.TabStop = false; this.groupBox1.TabStop = false;
// this.toolTip1.SetToolTip(this.groupBox1, resources.GetString("groupBox1.ToolTip"));
// rbFreedbNever
//
resources.ApplyResources(this.rbFreedbNever, "rbFreedbNever");
this.rbFreedbNever.Name = "rbFreedbNever";
this.rbFreedbNever.TabStop = true;
this.rbFreedbNever.UseVisualStyleBackColor = true;
//
// rbFreedbIf
//
resources.ApplyResources(this.rbFreedbIf, "rbFreedbIf");
this.rbFreedbIf.Name = "rbFreedbIf";
this.rbFreedbIf.TabStop = true;
this.rbFreedbIf.UseVisualStyleBackColor = true;
// //
// rbFreedbAlways // rbFreedbAlways
// //
this.rbFreedbAlways.AccessibleDescription = null;
this.rbFreedbAlways.AccessibleName = null;
resources.ApplyResources(this.rbFreedbAlways, "rbFreedbAlways"); resources.ApplyResources(this.rbFreedbAlways, "rbFreedbAlways");
this.rbFreedbAlways.BackgroundImage = null;
this.rbFreedbAlways.Font = null;
this.rbFreedbAlways.Name = "rbFreedbAlways"; this.rbFreedbAlways.Name = "rbFreedbAlways";
this.rbFreedbAlways.TabStop = true; this.rbFreedbAlways.TabStop = true;
this.toolTip1.SetToolTip(this.rbFreedbAlways, resources.GetString("rbFreedbAlways.ToolTip"));
this.rbFreedbAlways.UseVisualStyleBackColor = true; this.rbFreedbAlways.UseVisualStyleBackColor = true;
// //
// rbFreedbIf
//
this.rbFreedbIf.AccessibleDescription = null;
this.rbFreedbIf.AccessibleName = null;
resources.ApplyResources(this.rbFreedbIf, "rbFreedbIf");
this.rbFreedbIf.BackgroundImage = null;
this.rbFreedbIf.Font = null;
this.rbFreedbIf.Name = "rbFreedbIf";
this.rbFreedbIf.TabStop = true;
this.toolTip1.SetToolTip(this.rbFreedbIf, resources.GetString("rbFreedbIf.ToolTip"));
this.rbFreedbIf.UseVisualStyleBackColor = true;
//
// rbFreedbNever
//
this.rbFreedbNever.AccessibleDescription = null;
this.rbFreedbNever.AccessibleName = null;
resources.ApplyResources(this.rbFreedbNever, "rbFreedbNever");
this.rbFreedbNever.BackgroundImage = null;
this.rbFreedbNever.Font = null;
this.rbFreedbNever.Name = "rbFreedbNever";
this.rbFreedbNever.TabStop = true;
this.toolTip1.SetToolTip(this.rbFreedbNever, resources.GetString("rbFreedbNever.ToolTip"));
this.rbFreedbNever.UseVisualStyleBackColor = true;
//
// frmCUETools // frmCUETools
// //
this.AccessibleDescription = null;
this.AccessibleName = null;
resources.ApplyResources(this, "$this"); resources.ApplyResources(this, "$this");
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackgroundImage = null;
this.Controls.Add(this.groupBox1); this.Controls.Add(this.groupBox1);
this.Controls.Add(this.btnResume); this.Controls.Add(this.btnResume);
this.Controls.Add(this.btnPause); this.Controls.Add(this.btnPause);
@@ -529,8 +775,10 @@ namespace JDP {
this.Controls.Add(this.grpCUEPaths); this.Controls.Add(this.grpCUEPaths);
this.Controls.Add(this.btnConvert); this.Controls.Add(this.btnConvert);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
this.Icon = null;
this.MaximizeBox = false; this.MaximizeBox = false;
this.Name = "frmCUETools"; this.Name = "frmCUETools";
this.toolTip1.SetToolTip(this, resources.GetString("$this.ToolTip"));
this.Load += new System.EventHandler(this.frmCUETools_Load); this.Load += new System.EventHandler(this.frmCUETools_Load);
this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.frmCUETools_FormClosed); this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.frmCUETools_FormClosed);
this.grpCUEPaths.ResumeLayout(false); this.grpCUEPaths.ResumeLayout(false);

View File

@@ -417,7 +417,8 @@ namespace JDP {
CenterSubForm(reportForm); CenterSubForm(reportForm);
reportForm.ShowDialog(this); reportForm.ShowDialog(this);
} }
else if (cueSheet.AccurateRip != AccurateRipMode.None) else if (cueSheet.AccurateRip == AccurateRipMode.Verify ||
(cueSheet.AccurateRip != AccurateRipMode.None && outputFormat != OutputAudioFormat.NoAudio))
{ {
frmReport reportForm = new frmReport(); frmReport reportForm = new frmReport();
StringWriter sw = new StringWriter(); StringWriter sw = new StringWriter();
@@ -488,6 +489,7 @@ namespace JDP {
grpAudioOutput.Enabled = !running && !rbArVerify.Checked; grpAudioOutput.Enabled = !running && !rbArVerify.Checked;
grpAccurateRip.Enabled = !running; grpAccurateRip.Enabled = !running;
grpOutputStyle.Enabled = !running && !rbArVerify.Checked; grpOutputStyle.Enabled = !running && !rbArVerify.Checked;
groupBox1.Enabled = !running && !rbArVerify.Checked;
txtDataTrackLength.Enabled = !running && !rbArNone.Checked; txtDataTrackLength.Enabled = !running && !rbArNone.Checked;
btnAbout.Enabled = !running; btnAbout.Enabled = !running;
btnSettings.Enabled = !running; btnSettings.Enabled = !running;

View File

@@ -145,22 +145,22 @@
<data name="lblOutput.ToolTip" xml:space="preserve"> <data name="lblOutput.ToolTip" xml:space="preserve">
<value /> <value />
</data> </data>
<data name="lblInput.Size" type="System.Drawing.Size, System.Drawing">
<value>49, 13</value>
</data>
<data name="lblInput.Text" xml:space="preserve"> <data name="lblInput.Text" xml:space="preserve">
<value>E&amp;ingabe:</value> <value>E&amp;ingabe:</value>
</data> </data>
<data name="lblInput.ToolTip" xml:space="preserve"> <data name="lblInput.ToolTip" xml:space="preserve">
<value /> <value />
</data> </data>
<data name="txtOutputPath.ToolTip" xml:space="preserve">
<value />
</data>
<data name="txtOutputPath.Location" type="System.Drawing.Point, System.Drawing"> <data name="txtOutputPath.Location" type="System.Drawing.Point, System.Drawing">
<value>62, 48</value> <value>62, 48</value>
</data> </data>
<data name="txtOutputPath.Size" type="System.Drawing.Size, System.Drawing"> <data name="txtOutputPath.Size" type="System.Drawing.Size, System.Drawing">
<value>382, 21</value> <value>382, 21</value>
</data> </data>
<data name="txtInputPath.ToolTip" xml:space="preserve"> <data name="txtOutputPath.ToolTip" xml:space="preserve">
<value /> <value />
</data> </data>
<data name="txtInputPath.Location" type="System.Drawing.Point, System.Drawing"> <data name="txtInputPath.Location" type="System.Drawing.Point, System.Drawing">
@@ -169,6 +169,9 @@
<data name="txtInputPath.Size" type="System.Drawing.Size, System.Drawing"> <data name="txtInputPath.Size" type="System.Drawing.Size, System.Drawing">
<value>382, 21</value> <value>382, 21</value>
</data> </data>
<data name="txtInputPath.ToolTip" xml:space="preserve">
<value />
</data>
<data name="grpCUEPaths.Text" xml:space="preserve"> <data name="grpCUEPaths.Text" xml:space="preserve">
<value>CUE-Pfade</value> <value>CUE-Pfade</value>
</data> </data>
@@ -448,15 +451,33 @@
<data name="btnResume.ToolTip" xml:space="preserve"> <data name="btnResume.ToolTip" xml:space="preserve">
<value /> <value />
</data> </data>
<data name="rbFreedbAlways.Size" type="System.Drawing.Size, System.Drawing">
<value>55, 17</value>
</data>
<data name="rbFreedbAlways.Text" xml:space="preserve"> <data name="rbFreedbAlways.Text" xml:space="preserve">
<value>Immer</value> <value>Immer</value>
</data> </data>
<data name="rbFreedbAlways.ToolTip" xml:space="preserve">
<value />
</data>
<data name="rbFreedbIf.Size" type="System.Drawing.Size, System.Drawing">
<value>80, 17</value>
</data>
<data name="rbFreedbIf.Text" xml:space="preserve"> <data name="rbFreedbIf.Text" xml:space="preserve">
<value>Wenn nötig</value> <value>Wenn nötig</value>
</data> </data>
<data name="rbFreedbIf.ToolTip" xml:space="preserve">
<value />
</data>
<data name="rbFreedbNever.Size" type="System.Drawing.Size, System.Drawing">
<value>40, 17</value>
</data>
<data name="rbFreedbNever.Text" xml:space="preserve"> <data name="rbFreedbNever.Text" xml:space="preserve">
<value>Nie</value> <value>Nie</value>
</data> </data>
<data name="rbFreedbNever.ToolTip" xml:space="preserve">
<value />
</data>
<data name="groupBox1.Text" xml:space="preserve"> <data name="groupBox1.Text" xml:space="preserve">
<value>FreeDB-Abfrage</value> <value>FreeDB-Abfrage</value>
</data> </data>

File diff suppressed because it is too large Load Diff

View File

@@ -28,19 +28,20 @@ namespace HDCDDotNet
public class HDCDDotNet public class HDCDDotNet
{ {
public HDCDDotNet (Int16 channels, Int32 sample_rate, Int32 output_bps, bool decode) public HDCDDotNet (int channels, int sample_rate, int output_bps, bool decode)
{ {
_decoder = IntPtr.Zero; _decoder = IntPtr.Zero;
#if !MONO #if !MONO
_decoder = hdcd_decoder_new(); _decoder = hdcd_decoder_new();
_channelCount = channels; _channelCount = channels;
_bitsPerSample = output_bps;
if (_decoder == IntPtr.Zero) if (_decoder == IntPtr.Zero)
throw new Exception("Failed to initialize HDCD decoder."); throw new Exception("Failed to initialize HDCD decoder.");
bool b = true; bool b = true;
b &= hdcd_decoder_set_num_channels(_decoder, channels); b &= hdcd_decoder_set_num_channels(_decoder, (short) _channelCount);
b &= hdcd_decoder_set_sample_rate(_decoder, sample_rate); b &= hdcd_decoder_set_sample_rate(_decoder, sample_rate);
b &= hdcd_decoder_set_input_bps(_decoder, 16); b &= hdcd_decoder_set_input_bps(_decoder, 16);
b &= hdcd_decoder_set_output_bps(_decoder, (short) output_bps); b &= hdcd_decoder_set_output_bps(_decoder, (short)_bitsPerSample);
if (!b) if (!b)
throw new Exception("Failed to set up HDCD _decoder parameters."); throw new Exception("Failed to set up HDCD _decoder parameters.");
_decoderCallback = decode ? new hdcd_decoder_write_callback(DecoderCallback) : null; _decoderCallback = decode ? new hdcd_decoder_write_callback(DecoderCallback) : null;
@@ -76,6 +77,14 @@ namespace HDCDDotNet
} }
} }
public bool Decoding
{
get
{
return _decoderCallback != null;
}
}
public int Channels public int Channels
{ {
get get
@@ -84,6 +93,14 @@ namespace HDCDDotNet
} }
} }
public int BitsPerSample
{
get
{
return _bitsPerSample;
}
}
public void Reset() public void Reset()
{ {
#if !MONO #if !MONO
@@ -184,7 +201,7 @@ namespace HDCDDotNet
private IntPtr _decoder; private IntPtr _decoder;
private int[,] _inSampleBuffer; private int[,] _inSampleBuffer;
private int[,] _outSampleBuffer; private int[,] _outSampleBuffer;
private int _channelCount; private int _channelCount, _bitsPerSample;
hdcd_decoder_write_callback _decoderCallback; hdcd_decoder_write_callback _decoderCallback;
IAudioDest _audioDest; IAudioDest _audioDest;
GCHandle _gch; GCHandle _gch;

View File

@@ -81,14 +81,14 @@
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ProjectReference Include="..\CUETools.Codecs\CUETools.Codecs.csproj">
<Project>{6458A13A-30EF-45A9-9D58-E5031B17BEE2}</Project>
<Name>CUETools.Codecs</Name>
</ProjectReference>
<ProjectReference Include="..\CUETools.Codecs.LossyWAV\CUETools.Codecs.LossyWAV.csproj"> <ProjectReference Include="..\CUETools.Codecs.LossyWAV\CUETools.Codecs.LossyWAV.csproj">
<Project>{8A0426FA-0BC2-4C49-A6E5-1F9A68156F19}</Project> <Project>{8A0426FA-0BC2-4C49-A6E5-1F9A68156F19}</Project>
<Name>CUETools.Codecs.LossyWAV</Name> <Name>CUETools.Codecs.LossyWAV</Name>
</ProjectReference> </ProjectReference>
<ProjectReference Include="..\CUETools.Codecs\CUETools.Codecs.csproj">
<Project>{6458A13A-30EF-45A9-9D58-E5031B17BEE2}</Project>
<Name>CUETools.Codecs</Name>
</ProjectReference>
</ItemGroup> </ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it. <!-- To modify your build process, add your task inside one of the targets below and uncomment it.

View File

@@ -53,6 +53,8 @@ namespace LossyWAVSharp
double quality = 5.0; double quality = 5.0;
bool createCorrection = false; bool createCorrection = false;
bool toStdout = false; bool toStdout = false;
int outputBPS = 0;
for (int arg = 1; arg < args.Length; arg++) for (int arg = 1; arg < args.Length; arg++)
{ {
bool ok = true; bool ok = true;
@@ -66,6 +68,8 @@ namespace LossyWAVSharp
quality = 2.5; quality = 2.5;
else if (args[arg] == "-C" || args[arg] == "--correction") else if (args[arg] == "-C" || args[arg] == "--correction")
createCorrection = true; createCorrection = true;
else if (args[arg] == "--16")
outputBPS = 16;
else if ((args[arg] == "-N" || args[arg] == "--stdinname") && ++arg < args.Length) else if ((args[arg] == "-N" || args[arg] == "--stdinname") && ++arg < args.Length)
stdinName = args[arg]; stdinName = args[arg];
else if ((args[arg] == "-q" || args[arg] == "--quality") && ++arg < args.Length) else if ((args[arg] == "-q" || args[arg] == "--quality") && ++arg < args.Length)
@@ -88,7 +92,7 @@ namespace LossyWAVSharp
{ {
WAVReader audioSource = new WAVReader(sourceFile, (sourceFile == "-" ? Console.OpenStandardInput() : null)); WAVReader audioSource = new WAVReader(sourceFile, (sourceFile == "-" ? Console.OpenStandardInput() : null));
if (sourceFile == "-" && stdinName != null) sourceFile = stdinName; if (sourceFile == "-" && stdinName != null) sourceFile = stdinName;
WAVWriter audioDest = new WAVWriter(Path.ChangeExtension(sourceFile, ".lossy.wav"), audioSource.BitsPerSample, audioSource.ChannelCount, audioSource.SampleRate, toStdout ? Console.OpenStandardOutput() : null); WAVWriter audioDest = new WAVWriter(Path.ChangeExtension(sourceFile, ".lossy.wav"), outputBPS == 0 ? audioSource.BitsPerSample : outputBPS, audioSource.ChannelCount, audioSource.SampleRate, toStdout ? Console.OpenStandardOutput() : null);
WAVWriter lwcdfDest = createCorrection ? new WAVWriter(Path.ChangeExtension(sourceFile, ".lwcdf.wav"), audioSource.BitsPerSample, audioSource.ChannelCount, audioSource.SampleRate, null) : null; WAVWriter lwcdfDest = createCorrection ? new WAVWriter(Path.ChangeExtension(sourceFile, ".lwcdf.wav"), audioSource.BitsPerSample, audioSource.ChannelCount, audioSource.SampleRate, null) : null;
LossyWAVWriter lossyWAV = new LossyWAVWriter(audioDest, lwcdfDest, audioSource.BitsPerSample, audioSource.ChannelCount, audioSource.SampleRate, quality); LossyWAVWriter lossyWAV = new LossyWAVWriter(audioDest, lwcdfDest, audioSource.BitsPerSample, audioSource.ChannelCount, audioSource.SampleRate, quality);
int[,] buff = new int[0x1000, audioSource.ChannelCount]; int[,] buff = new int[0x1000, audioSource.ChannelCount];

Binary file not shown.

Binary file not shown.

Binary file not shown.