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: UPnP: How does the Media Library Tree work? (Read 8239 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

UPnP: How does the Media Library Tree work?

I specifically referring to the foo_upnp_ml_tree.xml from the UPnP/DLNA Renderer, Server, Control Point component.

For example, what's the difference between object.container.album.musicAlbum and object.container.genre.musicGenre. Obviously, one has to do with Albums and the other has to do with Genres, but I can't tell what they're specific functions are.  Also, which object.container do I use for single tracks?  I saw something about object.item, is that a thing?

Is there any documentation out there?

Thanks for any help!
Windows 10 | Foobar2000 v2.0 Portable | Columns 2.1.0 | SQLite Utilities 3.0.4 | SQLite Tree 4.0.6

Re: UPnP: How does the Media Library Tree work?

Reply #1
Is there any documentation out there?

There is a link from the download page.

http://bubbleguuum.free.fr/foo_upnp/foo_upnp.txt

I don't use it but check Customizing the browse tree.

Re: UPnP: How does the Media Library Tree work?

Reply #2
Thanks for the suggestion, but that doc is pretty light on what I'm looking for.
Windows 10 | Foobar2000 v2.0 Portable | Columns 2.1.0 | SQLite Utilities 3.0.4 | SQLite Tree 4.0.6

Re: UPnP: How does the Media Library Tree work?

Reply #3
For example, what's the difference between object.container.album.musicAlbum and object.container.genre.musicGenre. Obviously, one has to do with Albums and the other has to do with Genres, but I can't tell what they're specific functions are.  Also, which object.container do I use for single tracks?  I saw something about object.item, is that a thing?

Before you dig in too deep, are you sure you want to start using a component that hasn't been updated in 9 years and only works with foobar x86 (and only runs on Windows)?

From the UPnP Content Directory specification:
Quote
A class is used to assign a type to an object. It also identifies the minimum required set of properties that shall be included in the object’s metadata and the allowed properties that may be included. Classes are organized in a hierarchy with certain classes being derived from others as in a typical object-oriented system.

If you want to create other indexes you should be able to use 'object.container'. e.g.
Code: [Select]
    <spec type="object.container">%releasetype%</spec>
    <spec type="object.container.album.musicAlbum">%album%</spec>

Music tracks are <upnp:class>object.item.audioItem.musicTrack</upnp:class> but the component will populate those for you as part of the musicAlbum class definition.

Re: UPnP: How does the Media Library Tree work?

Reply #4
Thanks for the link, SimBun!

Is there another UPnP component that allows this much control over the Media Library Tree?
Windows 10 | Foobar2000 v2.0 Portable | Columns 2.1.0 | SQLite Utilities 3.0.4 | SQLite Tree 4.0.6

Re: UPnP: How does the Media Library Tree work?

Reply #5
Is there another UPnP component that allows this much control over the Media Library Tree?
I guess it depends what your requirements are, as foo_upnp benefits hugely from having foobar as the backend e.g. the ability to handle CUE sheets, the playlist functionality e.t.c.

I use the licensed version of MinimServer on a Pi and I think it's just as flexible as foo_upnp (in terms of presentation). There's also AssetUPnP which does a few things differently to MinimServer, but I prefer MinimServer overall.

If you have anything specific you're looking for let me know.

Re: UPnP: How does the Media Library Tree work?

Reply #6
@SimBun
Do you know if I can add ratings through the MinimServer android app?  I know that's not something UPnP can do.
Windows 10 | Foobar2000 v2.0 Portable | Columns 2.1.0 | SQLite Utilities 3.0.4 | SQLite Tree 4.0.6

Re: UPnP: How does the Media Library Tree work?

Reply #7
@SimBun
Do you know if I can add ratings through the MinimServer android app?  I know that's not something UPnP can do.
MinimServer is the server component of UPnP. It reads ratings and passes them onto the control point but there's no way for the control point to pass an updated rating back and to store it in the file.

The only control point I know that displays the ratings properly from MinimServer (or any UPnP server) is the MediaMonkey Android app. I have requested this feature of BubbleUPnP but it has yet to be developed. Just like foobar's title formatting, MinimServer can append the rating to the track title so it's visible to any app, but it's not as nice as seeing it on the Now Playing screen.

There are ugly workarounds that consist of adding the track to a playlist (1*, 2*, 3*, 4*, 5*) and then exporting those playlists to update the tracks.

Systems like PlexAmp have it, but I don't know if you can get the ratings back out.

Re: UPnP: How does the Media Library Tree work?

Reply #8
There are ugly workarounds that consist of adding the track to a playlist (1*, 2*, 3*, 4*, 5*) and then exporting those playlists to update the tracks.
Thanks for the idea, I'm going to give it a shot.  Ugly or not.
I just have to figure out how to export the playlists in Foobar2000 Mobile.
Systems like PlexAmp have it, but I don't know if you can get the ratings back out.
You can rate the tracks but it's only saved to the Plex database, so it requires a similar ugly workaround.  I like Plexamp, but I'm not in love with it.  However, I do fall back on it when I mess something up in my UPnP setup.

Do you know if the playcount is updated in Foobar2K when I stream with UPnP?  I added the Playback Statistics component.
Also, going back to the MediaTree, do you know how to add a folder to a SubTree?

I tried something like this, but looking at it now, the logic feels kind of wonky:
Code: [Select]
<SubTree label="Parent Node">
<SubTree label="Child Node">
<spec>%field1%</spec>
<spec>%field2%</spec>
</SubTree>
<spec>%fieldA%</spec>
<spec>%fieldB%</spec>
</SubTree>
Windows 10 | Foobar2000 v2.0 Portable | Columns 2.1.0 | SQLite Utilities 3.0.4 | SQLite Tree 4.0.6

Re: UPnP: How does the Media Library Tree work?

Reply #9
There are ugly workarounds that consist of adding the track to a playlist (1*, 2*, 3*, 4*, 5*) and then exporting those playlists to update the tracks.
Thanks for the idea, I'm going to give it a shot.  Ugly or not.
I just have to figure out how to export the playlists in Foobar2000 Mobile.
If you're trying to use foobar/foo_upnp then I'm not sure you're going to be able to link playlists back to the files as the URL that foo_upnp generates doesn't contain the path to the file, instead it appears to be some sort of hash e.g.
Code: [Select]
http::/*.*.*.*:56923/content/dda71144f43629ed8b34a9b107cf4915.flac
MinimServer is one of the few servers that uses the filepath in the URL which makes it so easy to link it back to the file.


Do you know if the playcount is updated in Foobar2K when I stream with UPnP?  I added the Playback Statistics component.
I only use foobar for metadata management not playback, so I can't help you there.
MinimServer records the last 300 played items (1000 max). I use incrontab to scrape that history in order to keep everything that's been played, thinking I'll eventually feed it into last.fm (or similar).


Also, going back to the MediaTree, do you know how to add a folder to a SubTree?

I tried something like this, but looking at it now, the logic feels kind of wonky:
Code: [Select]
<SubTree label="Parent Node">
<SubTree label="Child Node">
<spec>%field1%</spec>
<spec>%field2%</spec>
</SubTree>
<spec>%fieldA%</spec>
<spec>%fieldB%</spec>
</SubTree>

What are you trying to do? In UPnP you descend one level at a time e.g.
Code: [Select]
<SubTree label="Release Type">
    <spec type="object.container.genre.musicGenre">%releasetype%</spec>
    <spec type="object.container.person.musicArtist">%album artist%</spec>
    <spec type="object.container.album.musicAlbum">%album%</spec>
</SubTree>

Re: UPnP: How does the Media Library Tree work?

Reply #10
@dix-hill :
Playback statistics are updated using foo_UPnP if selected in Server > Content > Submit playback statistics (playcount, ...)

 

Re: UPnP: How does the Media Library Tree work?

Reply #11
Awesome, thanks!
Windows 10 | Foobar2000 v2.0 Portable | Columns 2.1.0 | SQLite Utilities 3.0.4 | SQLite Tree 4.0.6