I’m sure it could be rewritten in just about anything. PHP. Python. Rust. Whatever
It just happens that my first need was from the console and awk worked great. And then it was a natural evolution to front-end that with bash.
Then, sometime later, the idea hit me that I could make it available online as a service. So in true Unix fashion (which I started with back in 1982, after several years with a plethora of lesser-knowns) I used HTML+PHP to call an existing tool and parsed the return. So, basically, it’s a pipe, just on the net.
Anyway, not terribly complex, just obscure these days – except maybe to some old-school sysadmins.
# 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.
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.
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.
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
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)
[quote=“, post:26, topic:19925”]
I would value that the resulting LBL would show: TIMESTAMPS PERFORMER - TITLE
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!
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
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
(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?
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.
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).