Thanks, working now.
About the scripts:
cue2lbl
- Find “TITLE”
- Find “INDEX”
- Format as Audacity Label (start time, start time again, label text)
Is that all that’s required?
lbl2cue
Is there any support for TITLE, PERFORMER, or FILE ?
Thanks, working now.
About the scripts:
cue2lbl
Is that all that’s required?
lbl2cue
Is there any support for TITLE, PERFORMER, or FILE ?
Notes I left for myself:
# Use Audacity to create a LBL file, with a single marker at
# the start of each track. Name the marker using the track
# name. Save the LBL file using the format "Artist - Album",
# and the script will use those for the PERFORMER and ALBUM
# records in the CUE file.
So yes, if you use those conventions the cue file will have track, performer and album.
It is not done in cue2lbl though.
How is Rekordbox formatting the time?
Here’s a Nyquist plug-in for “Labels to Cue Sheet”
LabelsToCue.ny (2.26 KB)
(Installation instructions: https://forum.audacityteam.org/t/installing-nyquist-plug-ins/62380/1)
I don’t use cue sheets, so perhaps one of you can check that this works correctly.
A plugin would certainly be better for the casual user.
Like this:
Note that all indexes start with hours before the first semicolon. The current tool expects only minutes before the first semicolon.
Also note that in this format (TITLE- PERFORMER- FILE - INDEX) the current online tool does not work correctly. It expects FILE, TITLE, and INDEX, in that order (source):
The cue2lbl conversion is rather finicky. It examines only three field (record) types: FILE, TITLE and INDEX. The order that these appear in is important.
(…) the FILE entry is checked first to find the track title. The path and extension are dropped and the remaining text is used as the first attempt at a track title. If a TITLE entry is subsequently found, then it is used for the title and the file-derived name is discarded.
To add a request: for my specific use the FILE tag may be ignored completely, but I would value that the resulting LBL would show:
TIMESTAMPS PERFORMER - TITLE
(If PERFORMER is empty the dash should probably be omitted)
To clarify my use case: as mentioned I create a DJ mix with multiple tracks, which I edit in Audacity. The CUE2LBL convert really helps the editing process, so I can see which track starts where.
When I’m done with the editing I upload my mix to my Mixcloud account, where I can also upload a cue sheet. This helps Mixcloud to identify (and show upon playback) the track’s start time, performer and title. When all those variables are included in the LBL they can be converted back to CUE accordingly.
Maybe helpful (for that last step, converting back to CUE): I also found the Github Project spreadsheet2cue, as used here.
Ref:
It seems that Rekordbox uses a non-standard format, so I assume that you would like a “Rekordbox format” option in a “Cue2Labels” plug-in.
Nyquist is not a nice language for working with text, but I think it would be possible for a plug-in to automatically handle both the standard format and the Rekordbox format.
From the above references, there does not seem to be a defined order for the track’s TITLE, FILE, INDEX (though they must all be after the first “TRACK” statement). I think that a Nyquist plug-in version could work with either order.
The online Cue2lbl tool takes the label text from the track TITLE (if present), or from the track FILE if TITLE is not present. I think that’s reasonable - do you agree milesvs?
I agree that it would be nice to include PERFORMER in the label text if present in the Cue sheet. Perhaps best for a plug-in to provide options for what to include in the label text.
Would be fine indeed. Another option would be to convert automatically: check for the number of semicolons (#): if # = 3 then add (60 x ] to the numbers.
[quote=“, post:26, topic:19925”]
Also note that in this format (TITLE- PERFORMER- FILE - INDEX) the current online tool does not work correctly. It expects FILE, TITLE, and INDEX, in that order
[/quote]From the above references, there does not seem to be a defined order for the > track> 's TITLE, FILE, INDEX
Indeed. But just pointing this out, in case somebody is taking the current tool as a starting point. Atm it seems to extract the data from the filename, and updates this with the title tag (so if the title tag comes before the filename, that doesn’t work)
absolutely.
[quote=“, post:26, topic:19925”]
I would value that the resulting LBL would show: TIMESTAMPS PERFORMER - TITLE
[/quote]I agree that it would be nice to include PERFORMER in the label text if present in the Cue sheet. Perhaps best for a plug-in to provide options for what to include in the label text.
Even better to make it adjustable!
Btw: just a thought in case there is somebody reading this who is into javascript and programming with arrays: I guess a webpage (much like the current tool) is built quite easily. Would require some extra manual steps, but it would be a quick fix. I’m not too good at JS, but when somebody who can code it doesn’t have a website, I could put it online on my site.
TRACK 03 doesn’t.
So…
I made a simple update in cue2lbl to handle [hh:]mm:ss:ff times.
If somebody would like to confirm that, but ran a few myself and it seems to be working as expected.
For the curious, it was in the awk code. I know… awk…
Given this input:
REM DATE 2021-08-14 04:27 PM
REM RECORDED_BY "rekordbox-dj"
TITLE "My Mix"
PERFORMER "DJ Me"
FILE "My Mixfile.wav" WAVE
TRACK 01 AUDIO
FILE "c:/path/to/artist1-song1.mp3" WAVE
TITLE "Song One"
PERFORMER "Artist One"
INDEX 01 01:00:00:00
TRACK 02 AUDIO
FILE "c:/path/to/artist2-song2.mp3" WAVE
TITLE "Song Two"
PERFORMER "Artist Two"
INDEX 01 00:22:41:00
TRACK 03 AUDIO
FILE "c:/path/to/artist3-song3.mp3" WAVE
TITLE "Song Three"
PERFORMER "Artist Three"
INDEX 01 00:01:08:15
The output is:
3600.000000 3600.000000 Song One
1361.000000 1361.000000 Song Two
68.200000 68.200000 Song Three
Where is it that PERFORMER should appear in the label output? Is it just another column as in:
3600.000000 3600.000000 Song One Artist One
1361.000000 1361.000000 Song Two Artist Two
68.200000 68.200000 Song Three Artist Three
??
Moot question, actually. Without getting into the extended label format (which I’m not going to do) the standard label supports three tab-delimited fields: start, duration, label text.
So I’ve updated the label text segment as “Title (Performer) [filename]”.
It doesn’t matter which order TITLE, PERFORMER, FILE occur.
However, for whatever reason (in a hurry, short on time is my guess) I keyed on TRACK as begin-record and INDEX as end-record, so those two need to be first and last.
And a couple of last things on cue2lbl
First, I don’t know what to do with the “top level” TITLE and PERFORMER that come before the first track. I considered treating them as globals, so if not present at the track level use the globals. But, that has pitfalls of its own.
Second, I add an ability to suppress the TITLE, PERFORMER, and FILE from the track label. Put these in the header area of the file
REM NOTITLE
REM NOPERFORMER
REM NOFILE
(case sensitive) and they will suppress that field from the output.
I suppose I’ve missed something (on cue2lbl, haven’t considered lbl2cue yet.) Have I?
Hmm, might have made a mistake with copy-pasting. Will check this evening!
Oh, sounds great! Will test this evening!
Audacity’s label format is tab delimited. If you want both the artist name and song title to appear in the label, then there must NOT be a tab character between them.
Label Format Change
A few years ago, the label format was extended to support labelling frequency ranges in track spectrogram view. This was an entirely unnecessary change in my opinion, that breaks tools such as Lbl2cue.
Example:
0.000000 0.000000 First Label
733.528709 733.528709 Second Label
\ 1465.034912 1737.762207
1334.034166 1334.034166 Third Label
3785.321945 3785.321945 Fourth Label
In the above example, “Second Label” has a spectrogram range (1.47 kHz to 1.74 kHz).
Fortunately, this new extension to the format is now off by default, so users are less likely to run into the problem, but ideally Lbl2cue should ignore lines that begin with a backslash.
See: Import / Export Preferences - Audacity Manual
and: Importing and Exporting Labels - Audacity Manual
I was wondering about this. What are pitfalls of using the top level TITLE and PERFORMER as global fallback values?
Frequency range lines now ignored.
A few other goodies added. Updating docs (w/examples) now.
Ok, feel free to beat on it (them) some more
I can’t see any technical pitfalls. It might have some interesting effects on the label content, but other than that… I don’t know.
I put it in there. No track title or performer, then use the top level values.
The most awkward thing about this is that there isn’t a single, well defined specification for Cue sheets