Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Customize media library tree ALL TRACKS (Read 3586 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Customize media library tree ALL TRACKS

Hi, When using the media server function and accessing it over a network, for example from my yamaha recevier, I want to be able to play "all tracks" of a specific tag, for example genre. Currently, when I click on artist, it gives me a list of artists and when I select one, it'll then give me a list of all the albums but also at the end it has the option "ALL TRACKS." I just want that option after selecting a genre, or possible another tag like year.

I assume I just have to change the
"C:\Users\Benjamin\AppData\Roaming\foobar2000\foo_upnp_ml_tree.xml"
file but am not sure want to type and where.

Thanks

Ben

 

Customize media library tree ALL TRACKS

Reply #1
You can modify this entry for genre, for example:

Code: [Select]
<SubTree label="Genres">
        <spec type="object.container.genre.musicGenre">%&lt;genre&gt;%</spec>
        <spec type="object.container.album.musicAlbum">[$swapprefix(%album artist%) - ]%album%</spec>
</SubTree>

to this:

Code: [Select]
<SubTree label="Genres">
        <spec>%&lt;genre&gt;%</spec>
</SubTree>

Please be aware that when selecting a genre, it will return a list of all tracks with that genre (sorted by album and ? in my tests, but you have no control on how they're listed) and that without any subnodes, [All Tracks] will not appear.

Thus modifying the subtree to this:

Code: [Select]
<SubTree label="Genres">
        <spec type="object.container.genre.musicGenre">%&lt;genre&gt;%</spec>
</SubTree>

will have not make [All Tracks] appear because there isn't a spec for a subnode.

[All Tracks] nodes are achieved by these specs, by the way:
Code: [Select]
<spec type="object.container.person.musicArtist">
<spec type="object.container.album.musicAlbum">
<spec type="object.container.genre.musicGenre">

Customize media library tree ALL TRACKS

Reply #2
Thanks for the info - that helps a lot and ultimately gets me what I want but what I meant to ask was to have the option of selecting [All Tracks], not just having all the tracks present.

Currently when I use my A/V receiver or use foobar on another another computer via the media server,I can click on media library, Artists, select an artist (for example AC/DC) and then I get a list of all the albums but also the term [All Tracks] is present which will play all the tracks from that artist. I am trying to make this an option for the genre (and possibly others as well if possible, like "year").

Is this possible?  Can I get the following functionality? Media Library-->Genre-->select a genre (Rock And Roll for example)-->then it would list Artists and I could select an Artist and have all the albums listed AND [All Tracks] appear so I can play all the tracks by the artist in that genre (I have figured out how to achieve this by the way but only this, not in addition with) BUT ALSO in the Artist field have the option for [All Tracks] so I could play every song in that genre independent of artist or album.

Thanks for the help

Ben

Customize media library tree ALL TRACKS

Reply #3
The only way I've been able to achieve this is two have two foobar programs open at the same time (each with their own and differently named media servers) one with the just list everything in the genre option and the other with the genre-->artist-->album & All Tracks option. Seems a bit wasteful to me though having to have two identical programs open ontop of each other.

Customize media library tree ALL TRACKS

Reply #4
It appears that the component's developer has built a limitation into this spec:
Code: [Select]
<spec type="object.container.genre.musicGenre">

that prevents it from being used as you wish to do. I base this on your usage scenario which carries the risk of harmful potentialities due to the fact that an [All Tracks] entry under a genre could contain several hundred or thousands of tracks (maybe tens of thousands in a large library), which might cause crashes and/or freezes and possibly worse.

Then again, it could be a bug, but I'm inclined to think not for the reason given.

Now that you've been warned of the risk, you can achieve what you want with this:
Code: [Select]
<SubTree label="Genres">
    <spec type="object.container.person.musicArtist">%&lt;genre&gt;%</spec>
    <spec type="object.container.person.musicArtist">%&lt;artist&gt;%</spec>
    <spec type="object.container.album.musicAlbum">%album%</spec>
</SubTree>

It will give you an [All Tracks] entry in the artist list under each genre and in the album list under each artist such as:
Code: [Select]
Genre
    Artist 1
        Album 1
        Album 2
        Album 3
        [All Tracks]
    Artist 2
    Artist 3
    [All Tracks]

I tested it on a new PS3 (which seems to have built-in precautions against the risk I spoke of, luckily) for about an hour and encountered no problems other than the shuffle seems a little wonky, but that's no guarantee that there won't be any problems or that it will work with your hardware.

Use at your own risk!

Customize media library tree ALL TRACKS

Reply #5
Okay, I've had a chance to test the subtree in my above post a bit more and have discovered an issue involving tracks with a multi-value artist tag when selecting [All Tracks] under a genre.

What it comes down to is a track can only appear once. The issue appears when that track is encountered again under another artist. For example, let's say you have a track with an artist tag of "Bob; Aaron". The track will be loaded under Aaron, then when the track is encountered again under Bob, the loading of tracks will stop at that point and any tracks from that artist and subsequent artists will fail to load.

The only way around the issue is to use the following subtree instead.
Code: [Select]
<SubTree label="Genres">
    <spec type="object.container.person.musicArtist">%&lt;genre&gt;%</spec>
    <spec type="object.container.person.musicArtist">%artist%</spec>
    <spec type="object.container.album.musicAlbum">%album%</spec>
</SubTree>

I also suggest not ticking the box for "Allow album art streaming" located under Preferences > Tools > UPnP > Server > Content if selecting [All tracks] under a genre is likely to load hundreds of tracks.

The wonky shuffling issue on a PS3 was overcome by ensuring that all tracks loaded.

Again, use at your own risk.

Customize media library tree ALL TRACKS

Reply #6
Okay, I've had a chance to test the subtree in my above post a bit more and have discovered an issue involving tracks with a multi-value artist tag when selecting [All Tracks] under a genre.

What it comes down to is a track can only appear once. The issue appears when that track is encountered again under another artist. For example, let's say you have a track with an artist tag of "Bob; Aaron". The track will be loaded under Aaron, then when the track is encountered again under Bob, the loading of tracks will stop at that point and any tracks from that artist and subsequent artists will fail to load.

The only way around the issue is to use the following subtree instead.
Code: [Select]
<SubTree label="Genres">
    <spec type="object.container.person.musicArtist">%&lt;genre&gt;%</spec>
    <spec type="object.container.person.musicArtist">%artist%</spec>
    <spec type="object.container.album.musicAlbum">%album%</spec>
</SubTree>

I also suggest not ticking the box for "Allow album art streaming" located under Preferences > Tools > UPnP > Server > Content if selecting [All tracks] under a genre is likely to load hundreds of tracks.

The wonky shuffling issue on a PS3 was overcome by ensuring that all tracks loaded.

Again, use at your own risk.


Thank you so much, I'll give it a go. I am a winamp user and have been since it came out and to be honest love winamp, their media library is unmatched. You can customize it so quickly and easily to give you whatever you want it's great...they always have an "All" in every category so you can always see everything as well as the line level, be it artist, album, genre, etc.

With that said, I really do like foobar, it's a great program it just seems so odd to me that the most functional part of a music player, the media library seems to be clunky or not as well engineered as it should/could be...that is the only reason why I can't say it is the best media player around unanimously. Winamp doesn't support upnp and network stuff so foobar is definitely the way to go. I just seems weird to me.

My above opinion only pertains to the server related stuff - I still think winamp is better overall but when using a "local" media library and foobar software on a pc with a mouse, you can right click and add via "send to current (or new) playlist any field in the media liibrary which is great...I just don't understand why you can't do the exact same thing in virtually the same format (the windows looks almost identical) when connecting via a upnp browser.
Quick example...on this computer here I load my 12000 songs into my library. I can sort and look for whatever I want under the library tab. So, I click library-->album list. I sort by genre The very top thing it says is all music, and under it genres, I can always right click any of those fields and add everything to the playlist. Now, on my computer upstairs, I open foobar, goto view-->upnp browser and click on my foobar media server and i get virtually all the same fields, album, artist, artsist/album, genre, year, but when you right click on any of them and send to playlist nothing happens...interesting.

Thanks again for the code...can't wait to try it out when I get home.