IMPORTANT: .NET Framework 2.0 (SP2) required. If you get a "could not load file or assembly" error message for CUETools.Codecs.TTA/APE/WavPack/FLAC, make sure the recent version of Visual C++ 2008 runtime files (x86,x64) is installed.

The source code can be downloaded from the project's Mercurial repository at SourceForge.Note: The repository has moved. The latest source code can be downloaded from the project's repository at GitHub.

CUETools versions 1.9.5 through 2.1.5 (current)

WAV output is greyed out<edit>Ah I didn't see the "embed cue sheet" was selected! But still, if the configuration file of the 1.9.1 version had WAV output, 1.9.2 will still output a WAV file... the greyed out radio button is selected 1.9.2 needs at least an error box before conversion begins or automatically change to FLAC or (best solution IMHO) default to "Single File + CUE" if is was "Single File" in 1.9.1.</edit>when I want to add a cue sheet via drag & drop into the "Input:" box, the cue sheet is not added.

But apart from that... embed cue sheet, add AR CRC tags, and so on... great job!

The status report is a nice feature, too. Make it so that the log can be written to the output dir (using the name scheme) for each conversion, would be useful for batch conversion. <edit>...I'm going blind I guess.</edit>

CUETools versions 1.9.5 through 2.1.5 (current)

What I don't understand is that my need is to be able to analyze a whole album made of single-track files in lossless form (FLAC, etc.) put inside the same album folder. I may be blind too Fandango , but I don't see CUETools doing that yet. Am I wrong ?

This functionality is mandatory for me since I have thousands of single-FLAC files and not a single cuesheet.

CUETools versions 1.9.5 through 2.1.5 (current)

WAV output is greyed out<edit>Ah I didn't see the "embed cue sheet" was selected! But still, if the configuration file of the 1.9.1 version had WAV output, 1.9.2 will still output a WAV file... the greyed out radio button is selected 1.9.2 needs at least an error box before conversion begins or automatically change to FLAC or (best solution IMHO) default to "Single File + CUE" if is was "Single File" in 1.9.1.</edit>when I want to add a cue sheet via drag & drop into the "Input:" box, the cue sheet is not added.

But apart from that... embed cue sheet, add AR CRC tags, and so on... great job!

The status report is a nice feature, too. Make it so that the log can be written to the output dir (using the name scheme) for each conversion, would be useful for batch conversion. <edit>...I'm going blind I guess.</edit>

What I don't understand is that my need is to be able to analyze a whole album made of single-track files in lossless form (FLAC, etc.) put inside the same album folder. I may be blind too Fandango , but I don't see CUETools doing that yet. Am I wrong ?

This functionality is mandatory for me since I have thousands of single-FLAC files and not a single cuesheet.

No, it's me who is blind, i didn't notice you didn't have cuesheets.I'll think about automating the process, but for now i would recomend to write a script whch would create cuesheets for each directory. This would be very easy if your files have gaps appended. If they have gaps prepended or left out, there's nothing really that can be done - you have to know the size of gaps to be able to compare the disc to the database. Also if the first track had index 00, you're out of luck.

In fact, you don't even have to specify correct file names - you can use an option "Preprocess with filename corrector if unable to locate audio files".You just have to have the correct number of tracks.So you can create those dummy cuesheets by hand, and then just copy into each folder a .cue sheet which has the same number of tracks as this folder.

CUETools versions 1.9.5 through 2.1.5 (current)

Oops, the path was longer than 255 characters, that's why nothing happened. My bad, that happens sometimes when I move folders. And when I used the "Browse" button I selected a different cue sheet, I guess.

CUETools versions 1.9.5 through 2.1.5 (current)

No, it's me who is blind, i didn't notice you didn't have cuesheets.I'll think about automating the process, but for now i would recomend to write a script whch would create cuesheets for each directory. This would be very easy if your files have gaps appended. If they have gaps prepended or left out, there's nothing really that can be done - you have to know the size of gaps to be able to compare the disc to the database. Also if the first track had index 00, you're out of luck.

Well, I believe there must already be some utility that can batch-create cuesheets from single-track files. I'm talking about simply selecting a start folder, and then the utility would scan all the subfolders, find all tracks within a given subfolder, then create a cuesheet from them. Am I wrong ?

I am not a programmer, but I guess if such utility doesn't exist yet, it should be quite easy to create, and also to implement in CUETools. So Gregory, I hope you'll have the time to automate such process in the future. Thank you.

CUETools versions 1.9.5 through 2.1.5 (current)

Strange...Can it be that CUE Tools cannot find right offset for a set of FLACs linked up with a dummy cuesheet?In my case it gives only "(00/01) No matches.", while TripleFlac! easily found offset to be -1501 (with "LeadIn: 0") and verification in CT with that value showed "Accurately ripped as in pressing(s) #1". Also when I converted "tracks + dummy cuesheet" to WAV "Single File + CUE", ARcue found -1501 as well.At the same time with another rip (in the form of "flac-image + cuesheet") verification, as it should, showed two results: one without offset correction ("No matches") and another, "offsetted".

Command line parameters is the feature I missed so much! Very nice verification mode & awesome new log! Now I wish only CT could directly handle a set of FLAC files (or folder containing them) - I'd throw away TripleFlac!As for usability I can suggest hotkeys (Alt+letter) and Write Offset box right in the main window (yeah, it was there already some time ago, and IMHO so it were much more convenient). Also an option to set up filename for AccurateRip report would be nice to have. And to be completely a bore… maybe you can remove those points at the end of almost every line of AR report to save a few bytes on HDD?

CUETools versions 1.9.5 through 2.1.5 (current)

Strange...Can it be that CUE Tools cannot find right offset for a set of FLACs linked up with a dummy cuesheet?In my case it gives only "(00/01) No matches.", while TripleFlac! easily found offset to be -1501 (with "LeadIn: 0") and verification in CT with that value showed "Accurately ripped as in pressing(s) #1". Also when I converted "tracks + dummy cuesheet" to WAV "Single File + CUE", ARcue found -1501 as well.At the same time with another rip (in the form of "flac-image + cuesheet") verification, as it should, showed two results: one without offset correction ("No matches") and another, "offsetted".

Command line parameters is the feature I missed so much! Very nice verification mode & awesome new log! Now I wish only CT could directly handle a set of FLAC files (or folder containing them) - I'd throw away TripleFlac!As for usability I can suggest hotkeys (Alt+letter) and Write Offset box right in the main window (yeah, it was there already some time ago, and IMHO so it were much more convenient). Also an option to set up filename for AccurateRip report would be nice to have. And to be completely a bore… maybe you can remove those points at the end of almost every line of AR report to save a few bytes on HDD?

Can i see that dummy cuesheet? Is the accuraterip discId identical in those logs? Did you use CUETools to convert "tracks + dummy cuesheet" to WAV "Single File + CUE", or something else was involved in that process?

CUETools versions 1.9.5 through 2.1.5 (current)

Can i see that dummy cuesheet? Is the accuraterip discId identical in those logs? Did you use CUETools to convert "tracks + dummy cuesheet" to WAV "Single File + CUE", or something else was involved in that process?

Of cause you can, although I can't even imagine what can be wrong there

CUETools versions 1.9.5 through 2.1.5 (current)

It should be able to find offsets within +/- 2939. I tried to reproduce this (same offset, generic cuesheet) but it worked fine for me, at least on the CD I tried. I wonder if it has a problem calculating the checksum when it has to read into the previous/next track, but I didn't notice this because my files had enough silence in between (just a guess).

Also, I tested the bugfix for the silent track issue, it works fine (although it reports no matches for that track, but that appears to be a limitation of AccurateRip rather than a bug in this code).

By the way, I modified the latest code a bit to make the AccurateRip part work on CDs with data tracks. I sent it to Gregory so maybe he'll post a new version soon. I accomplished this by looking for a line in the cuesheet such as:

CUETools versions 1.9.5 through 2.1.5 (current)

Maybe 1501 is beyond the window being used. The AR dll uses a window of 3527 samples (-1763...0...1763). The larger you make the window, the longer determining the offset will take.

I thought about that when I remembered about search range of 700 by default in previous version. So I applied +802 offset first to move audiodata at -699 samples from AR. But again CUE Tools didn't find that offset while TripleFlac did.

2Gregory S. ChudovWhy did you remove possibility to automatically verify output files after conversion?Instead maybe we could render AccurateRip support in two checkboxes: "Verify" and "Fix offset"?The first would depend on "Audio Output" selection: "None" - "Verify" will check source files, other options - "Verify" will check conversion result."Fix offset" must always turn on "Verify" and could be disabled if "Audio Output" set to "None".

By the way, I modified the latest code a bit to make the AccurateRip part work on CDs with data tracks. I sent it to Gregory so maybe he'll post a new version soon. I accomplished this by looking for a line in the cuesheet such as:

REM DATATRACKLENGTH 07:42:49

If anyone has a better idea, let me know.

Thanks for the code, i'm playing around with it. Unfortunately embedded flac cue sheets can't have arbitary comments, so i'm probably going to add a flac tag also. And probably an input box in CUETools gui.

2Gregory S. ChudovWhy did you remove possibility to automatically verify output files after conversion?Instead maybe we could render AccurateRip support in two checkboxes: "Verify" and "Fix offset"?The first would depend on "Audio Output" selection: "None" - "Verify" will check source files, other options - "Verify" will check conversion result."Fix offset" must always turn on "Verify" and could be disabled if "Audio Output" set to "None".

My reasoning was that if you are converting audio files and verifying them with AccurateRip, you'd usually want to correct offset while you're at it. What's the point of verifying audio files after conversion, if you are most probably going to find out that offset wasn't correct and you have to convert them again? So you basicly either don't care about AccurateRip, or just want to verify existing files and don't want to rewrite them, or you want to convert them and fix offset. Thus 3 options. I wanted to keep it simple.

CUETools versions 1.9.5 through 2.1.5 (current)

By the way, I modified the latest code a bit to make the AccurateRip part work on CDs with data tracks. I sent it to Gregory so maybe he'll post a new version soon. I accomplished this by looking for a line in the cuesheet such as:

REM DATATRACKLENGTH 07:42:49

If anyone has a better idea, let me know.

I'm starting to think we don't need to store so many tags - we already have ACCURATERIPID which is just what we need to get the right entry from the database. So we only need to specify DATATRACKLENGTH in source file or in the CUETools interface, but we should store only ACCURATERIPID and use ACCURATERIPID when it's available. In theory, that way we would be able to verify even a single track taken out of the album, if it has been verified and tagged before by someone - all we need is the ID of the album and the track number.

Also, if we have a decent EAC log in the same folder as a CUE sheet and with the same name, we can try to parse it and retrieve the data track length from there.

CUETools versions 1.9.5 through 2.1.5 (current)

Well, in this case there is no bug. Either your copy or the one in database is damaged in almost every track, there's only one submission to the database, so there's no way to find out which was the case.

My current guess is that Tripleflac compares partial CRCs, not of entire tracks, but of some small fragments. There is a mysterious unused alernate CRC for each track in AccurateRip database, and i suppose it's a CRC of some fragment of a track.

Tripleflac managed to guess the offset using bad copies - that's looks like a nice feature, and i would like to have it in CUETools too, though i think it's not very useful. Because if your copy is damaged, offset is the last thing you should worry about

CUETools versions 1.9.5 through 2.1.5 (current)

if your copy is damaged, offset is the last thing you should worry about

Agree, since I can verify rip without fixing offset at first I'm not worried about it at all Maybe that is why I haven't really tried "Fix offset" option yet and lack for autoverification after conversion. If AR knows about different pressing only but I'm sure the rip is offset corrected, I wouldn't adjust it to AR, only convert image to tracks (I like it that way) and verify result. Anyway I accept what you done with gratitude!

Creating .cue works fine! But I think there must be some remark about it's origin, maybe in filename or in REM or both.And that "Browse for folders" dialog always starting at Desktop is really a pain in the ass IMHO drag'n'drop straight on those three buttons would be much more handy (accepting cuesheet(s), folder(s) and a set of files would be nice).But it still wouldn't be as much handy as commandline switches to do whatever we want directly from favorite file manager

And could you please add hotkeys also for "Output" ("Fix offset" could be changed to "Fix offset"), "Manual" and "Create subdirectory"?

Let me know if I'm makin haste or distract you from more important things

CUETools versions 1.9.5 through 2.1.5 (current)

thanks a lot for jumpstarting CUEtools dev. Moitah did a fantastic job to begin with, and I'm sure that with all these new features, CUETools will be one of the ebst tools for lossless,cue,AR management.

I have a request though...

I'm currently transcoding very old single ape+cue albums to FLAC. I basically decode to wav, verify AR and if OK (all tracks present & confidently ripped) I encode them to FLAC. If AR check is not OK, I move the album to a ToVerify folder for later on inspection.

Can you implement an "Encode if AR verify OK" mode ? You could even have a setting to specify the confidence level of an OK AR verification, say for example, 5 (i.e.: if confidence level is >=5, then flag it as OK). An album should be considered AR OK if all tracks verify with the same offset, over the previously specified treshold.

On the other hand, you could also have an option to log all the AR verification activity to a central file. This is really helpful for batch processing. Say for example you you can log all the AR fails, and later on it's just a matter to manually parse the log looking for full albums that are eligible for offset correction (i.e: same offset for all tracks), and apply it using batch mode.

CUETools versions 1.9.5 through 2.1.5 (current)

Creating .cue works fine! But I think there must be some remark about it's origin, maybe in filename or in REM or both.

I second that. Cuesheets created by CUETools should be immediately distinguishable from others. Why not directly in the filename ? E.g. : "Artist - Album [CUETools].cue" (REM would be good also as a complement)