Home of the Squeezebox™ & Transporter® network music players.
Page 4 of 4 FirstFirst ... 234
Results 31 to 39 of 39
  1. #31
    Senior Member w3wilkes's Avatar
    Join Date
    Jan 2009
    Location
    Utah, USA
    Posts
    1,292
    Seems that the easiest think would be 2 copies. One as individual albums, the other as a multidisc album. The multidisc would have all songs in the same folder with a common Album title. File names for the tracks would be something like "Disc# Track# Track title" and include Disc# in the tags.
    Main system - Rock Solid with LMS 7.9.1 Official on WHS 2011 - 2 Duets and Squeeseslave
    Cabin system - Rock solid with LMS 7.9.1 Official on Win10 Pro - 1 RPi 3 Model B/Hifiberry DAC+ Pro/PiCorePlayer and Squeezeslave
    Headphones and car - Android phone/Bluetooth w/full library on MicroSD card - PowerAmp music player app (similar to Material Skin)

  2. #32
    Senior Member
    Join Date
    Jun 2017
    Posts
    111
    Clearly, having multiple copies of the identical file in different folders and with different album tags and different track numbers is the best solution. But the inefficiency of that offends me, for some reason. (It's not necessarily logical. It's not as though I'm remarkably efficient in everything else I do.)

    Here's a workaround I'm trying:

    Put all tracks from a box set in a single folder, using filenames in the form suggested by w3wilkes: [disc#]-[track#]-title. Edit track number tags so that they are sequential through the entire set. It helps if there are gaps in the numbering. For instance, for a four-disc set containing a total 65 tracks, instead of numbering the tracks 01 through 65, number then 101 through 118 (or whatever the number of tracks on the first disc), 201 through 221, 301-314, and 401-412.

    Then, edit tags so that every track that was originally released on an album has ONLY the name of the original album in the album tag. In many cases, especially with Mosaic sets, the tracks in the box sets are not in the same order as on the original albums, so it will be necessary to juggle the track number tags to get them in the right sequence for the original albums. (That's why it's important to leave gaps in the number sequence; that will make it much easier to get track numbers in original album order when the tracks are spread out over multiple discs in the box set.)

    In my limited testing so far, this seems to work. LMS sees the original albums, and they should be available for Random Albums, which is important to me. The box set discs will NOT appear as albums in the LMS database (except for the outtakes and alternates), but that's okay with me. They aren't albums, in the sense of a programmed listening experience; they're archival volumes. The box set discs can be accessed through the Music Folder, though, with the tracks in the order as they appear in the box set.

    This seems to work for me. I'm sure it's not for everybody, but I hope somebody will find it useful and maybe help refine it.

  3. #33
    Senior Member
    Join Date
    Jun 2017
    Posts
    111
    Three months after my previous post, I have to say that the workaround I described then is not very satisfactory to me. If I do want to access the discs as released in the box set, they are available by browsing the music folder, as stated. However, it is not an easy or pleasant task to select all tracks on a single disc from, say, a ten-disc set when all tracks from all discs are in a single folder.

    I think I have found a better workaround, though. What's needed is a file format that LMS can recognize and read metadata from while using audio from a linked file. There is a file format that meets that description: cue files. Unfortunately, the standard cue file, which defines individual tracks in a large file, typically the entire contents of a CD, is not suitable for changing the order of tracks and/or omitting some tracks. There are cue files that use separate files as sources (examples here) but LMS does not currently support this type of cue file (discussion here).

    That leaves just one option that I can see: a separate cue file for each track. There is no need to alter the metadata in the original files from the box set, as the metadata will be read from the cue file. Here's an example from a set in my collection:

    Code:
    REM GENRE Jazz
    REM DATE 1953
    REM COMMENT "from Mingus Complete Debut Recordings"
    PERFORMER "Charlie Parker\\Dizzy Gillespie\\Bud Powell\\Charles Mingus\\Max Roach"
    TITLE "Jazz at Massey Hall complete, reconstructed"
    FILE "02-09 - I've Got You Under My Skin.flac" WAVE
      TRACK 05 AUDIO
        TITLE "I've Got You Under My Skin"
        PERFORMER "Bud Powell\\Charles Mingus\\Max Roach"
        INDEX 01 00:00:00
    That's one of thirteen cue files that define an album contained within a box set. Obviously, the album metadata, especially the title, needs to be the same in every file, while the name of the linked file and the track number and title will be different.

    The biggest disadvantage of this method is that it will not work for those who are already using cue lists with large files containing multiple tracks. The tracks must be split into separate files. And, needless to say, creating all those cue files is a tedious process.

    I should also note that these cue files do not seem to be picked up by an ad-hoc folder scan. When you add playable files to a folder and then use the browse music folder option to access that folder, LMS usually adds the new files to the library, but not these cue files. So far as I can tell, it is necessary to do a complete rescan. I have only used the "clear library and rescan everything" option, so I don't know if a "new and changed" rescan will work. (I'm currently using the August 16 build of 3.9.2.)

    There are bound to be other pitfalls that I have not found yet. I hope somebody else will try this and report back on what works and what doesn't.
    LMS (recent) running on Debian X86_64; 5 Squeezelite players (3 in PiCorePlayer), 3 players connected via Airplay Bridge
    1 Squeezebox Radio (upgraded UE Smart Radio) now mostly retired

  4. #34
    Senior Member
    Join Date
    Jun 2017
    Posts
    111
    What, nobody's excited about this?

    Never mind! I totally understand that this is a very niche subject. And may be my "discovery" is something that was already well known. But I didn't find any information about doing this when I searched. The one cue file per track method I described in the previous post seems to be an effective way to assign audio files to multiple "albums", without making a physical copy of each file. So far as I can tell, it's the only way to do it that works with the LMS database. (Symlinks would work fine, if you only browse through the file folder.)

    I'm going to add a few more observations, just in case somebody discovers this thread in the future and needs a bit more information. I should mention that all my experience is based in Linux: LMS runs on Debian and my music is on a drive formatted as ext4. I don't know how well anything I report will translate to other environments.

    It seems that the cue files do not have to be in the same folder as the audio files, but all audio files for an album need to be in a single folder. Let's say that I have a folder for one of my favorite musicians, who goes by the name, Artist01, and in that folder is a folder for a box set, entitled BoxSet, and I've just added a folder for an album, Album01, that is entirely contained in that set, but in the wrong order and intermingled with other tracks. All the box set files are in Artist01/BoxSet, but the cue files will be in Artist01/Album01. I have used relative paths in my tests, so the file statements in the cue files will look like this:
    Code:
    FILE  "../BoxSet/01 - This is the first track.flac  WAVE"
    Absolute paths would probably work, too, but I have not tried them.

    Moving the cue files into a separate folder for each album this way may be helpful for organizing a music collection, but unfortunately it does not help with other issues. Album art will be displayed from the audio file's folder; any "cover.jpg" or other appropriately-named files in the folder with the cue files will be ignored. Likewise, if you use the Music & Artist Information plugin, its links to "Local artwork" and "Text files from music folder" will also ignore the cue folder and list appropriate files in the folder with the audio file.

    This is in danger of becoming intolerably long, so I'll end this post here and continue in a separate one.
    LMS (recent) running on Debian X86_64; 5 Squeezelite players (3 in PiCorePlayer), 3 players connected via Airplay Bridge
    1 Squeezebox Radio (upgraded UE Smart Radio) now mostly retired

  5. #35
    Senior Member
    Join Date
    Jun 2017
    Posts
    111
    Continuing on the subject of using one cue file per track to create a separate album from the tracks included in a box set, one significant obstacle is the number of cue files that have to be created, especially if it's all done by hand.

    Being lazy, I have written a Bash script that assists in generating the cue files needed. The template is below. This template needs to be edited for each album. It needs a list of the audio files to be included in the album. one filename per line, in the correct order for the album. The filename of that list needs to be assigned to the variable Filelist in line 6. The variable Outfile in line 8 will be the base name of the cue files generated. In my example above, that would probably be "Album01_". Each cue filename will have the track number and the .cue file extension appended to that base.

    Line 20 will attempt to extract the track title from the filename of each audio file it processes. It assumes that filenames are in the format TRACKNUMBER - TITLE.EXTENSION, because that is the format I use, as in the example above. If your filenames are in a different format, it will be necessary to edit the command. It is also necessary to specify the extension where you see -F'.XXX' near the end of that line. That should be -F'.flac' or -F'.MP3' or whatever.

    The rest should be obvious. Lines 22 through 26 should be filled in with appropriate data for the album. Lines 28 through 32 contain information about individual tracks, most of which is derived from the filename, but you have the option of specifying a different track artist here.

    As I said, this script works for me. I have no idea if there's any chance of getting it to work on a Mac or in Cygwin. Even on other Linux machines, it may require some fiddling. The echo command seems to be especially prone to behaving differently on different systems. I've used the -e option with echo, so I can escape the quotes that need to be echoed to the cue files. However, I dropped that option on the two lines specifying the PERFORMER tag, because using it prevented echoing the \\ separator between multiple artists (it has to be echoed as "\\"), and the escaped quotes still work. But I suspect others will have different experiences, If anybody cares to try it, that is! If you do, good luck!

    Code:
    #!/bin/bash
    #template for script to create cue files for individual tracks comprising an album
    #Xs must be filled in!
    
    #list of files to be processed, one filename per line (no blank lines) in desired sequence
    Filelist="XXX"
    #base name of output cue files (will have number appended)
    Outfile="XXX_"
    Tracknum="0"
    #  The following line begins a loop that reads one line from the file list and processes that line to generate a single-track cue file
    while IFS= read -r Trackname
    do
    #  increment track number and add leading zero if needed, then append it and extension to base name of cue file
       let "Tracknum++"
       Trackout="$(printf "%02d" $Tracknum)"
       Cuefilename="$Outfile$Trackout.cue"
    #  The next executable line assumes that the filenames of music tracks consist of track number, a " - " separator (space, hyphen, space), the title of the track, and then the file type extension.
    #  Adjust the awk commands as needed, if the filename is in a different format.
    # .XXX must match the file type (extension) of the files to be processed, eg. .wav or .FLAC (case sensitive)  
       Title="$(echo -n $Trackname | awk -F' - ' '{print $2}' | awk -F'.XXX' '{print $1}')"
    #  The next five lines will embed the genre, year, comment, artist and title fields for the ALBUM in the cue file
       echo -e "REM GENRE \"XXXX\"" > $Cuefilename
       echo -e "REM DATE \"XXXX\"" >> $Cuefilename
       echo -e "REM COMMENT \"XXX XXX\"" >> $Cuefilename
       echo "PERFORMER \"XXX XXX\"" >> $Cuefilename
       echo -e "TITLE \"XXXX XXXX\"" >> $Cuefilename
    #  The next line will link to the audio file for the track and the following lines will provide track number, title, performer and starting point
       echo -e "FILE \"$Trackname\" WAVE" >> $Cuefilename
       echo -e "TRACK $Trackout AUDIO" >> $Cuefilename
       echo -e "  TITLE \"$Title\"" >> $Cuefilename
       echo "  PERFORMER \"XXX XXX\"" >> $Cuefilename
       echo -e "  INDEX 01 00:00:00" >> $Cuefilename
    done < "$Filelist"
    LMS (recent) running on Debian X86_64; 5 Squeezelite players (3 in PiCorePlayer), 3 players connected via Airplay Bridge
    1 Squeezebox Radio (upgraded UE Smart Radio) now mostly retired

  6. #36
    Junior Member
    Join Date
    Sep 2019
    Posts
    2
    I tried this solution, but I could not get it work properly. I tried this with Duke Ellington's Centennial edition box which contains 24 CD's. CD #18 contains 13 tracks which are taken from 'Concert of Sacred Music' album. So I created 13 cue files and executed complete scan. A new album ''Concert of Sacred Music'' appeared correctly (even artwork was correct), but at the same time those 13 tracks removed from the original Centennial Edition album.

    I looked at the "albums" and "tracks" database tables and realized that those 13 tracks each have 3 records in tracks table. One record links correctly to the new 'Concert of Sacred Music' (with album field) and actual flac file (uri field). Second record is otherwise clone of the first record except that album field is cleared (=links to nowhere). Third record links to the cue files (uri) and album field is again cleared.

  7. #37
    Senior Member
    Join Date
    Jun 2017
    Posts
    111
    Quote Originally Posted by Pauke View Post
    I tried this solution, but I could not get it work properly. I tried this with Duke Ellington's Centennial edition box which contains 24 CD's. CD #18 contains 13 tracks which are taken from 'Concert of Sacred Music' album. So I created 13 cue files and executed complete scan. A new album ''Concert of Sacred Music'' appeared correctly (even artwork was correct), but at the same time those 13 tracks removed from the original Centennial Edition album.

    I looked at the "albums" and "tracks" database tables and realized that those 13 tracks each have 3 records in tracks table. One record links correctly to the new 'Concert of Sacred Music' (with album field) and actual flac file (uri field). Second record is otherwise clone of the first record except that album field is cleared (=links to nowhere). Third record links to the cue files (uri) and album field is again cleared.
    I wish I knew enough to offer some advice, but I do not. All I can say is that this is not what I'm seeing on Linux (Debian) with music on a drive formatted as ext4. That's based on what I see under the "Artists" and "Albums" items in the "My Music" menu, where I find both the compilation album and the album defined in the cue files, each containing all the tracks it should. I have NOT examined the database structure as you have and would require some guidance to do so.
    LMS (recent) running on Debian X86_64; 5 Squeezelite players (3 in PiCorePlayer), 3 players connected via Airplay Bridge
    1 Squeezebox Radio (upgraded UE Smart Radio) now mostly retired

  8. #38
    Junior Member
    Join Date
    Sep 2019
    Posts
    2
    Quote Originally Posted by RobbH View Post
    I wish I knew enough to offer some advice, but I do not. All I can say is that this is not what I'm seeing on Linux (Debian) with music on a drive formatted as ext4. That's based on what I see under the "Artists" and "Albums" items in the "My Music" menu, where I find both the compilation album and the album defined in the cue files, each containing all the tracks it should. I have NOT examined the database structure as you have and would require some guidance to do so.
    It is good news that you don't have same problem as I. Maybe I still have hope. I must rethink if I made mistake somewhere.
    Anyway, thank you for this great idea!

  9. #39
    Senior Member
    Join Date
    Jun 2017
    Posts
    111
    Quote Originally Posted by Pauke View Post
    It is good news that you don't have same problem as I. Maybe I still have hope. I must rethink if I made mistake somewhere.
    Anyway, thank you for this great idea!
    Good luck to you! If you manage to get it to work for you, I hope you'll post about it here. I still hope someone will find a way to make LMS work with multi-file cue sheets, since that would be a much more satisfactory solution.
    LMS (recent) running on Debian X86_64; 5 Squeezelite players (3 in PiCorePlayer), 3 players connected via Airplay Bridge
    1 Squeezebox Radio (upgraded UE Smart Radio) now mostly retired

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •