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: foo_upnp (Read 1622730 times) previous topic - next topic
0 Members and 3 Guests are viewing this topic.

foo_upnp

Reply #75
Is there anything that has to be done to get album art working on a PS3? Do the files have to be named in a particular way?


foo_upnp

Reply #76
hey! this component is great.
Bad thing that xbox360 is not standard compliant for the upnp stuff.

If you are interesed, there's a modification to a streaming software for ubuntu, ushare, made by some guy 'NeToU' that added the feature streaming to xbox360. (It's written in C, but I guess the core of the problem in the upnp stuff is how to pass the stream to the xbox, so looking in the source code for references to the "xbox360 streaming enabled" flag, we've got this ocurrences:
(the license first)
Code: [Select]
/*
* Originally developped for the GeeXboX project.
* Copyright (C) 2005-2007 Benjamin Zores <ben@geexbox.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
* GNU Library General Public License for more details.
*
* You should have received a copy of the GNU General Public License along
* with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/

First one, cds.c (line 860)
Code: [Select]
 /* Don't confuse the 360 container IDs with uShares content directory container IDs */
  if(ut->xbox360)
  {
      entry = upnp_get_entry (ut, 0);
  }
  else
  {
      entry = upnp_get_entry (ut, id);
      if (!entry && (id < ut->starting_id))
        entry = upnp_get_entry (ut, ut->starting_id);
  }

Second one, metadata.c (line 199)
Code: [Select]
if (ut->xbox360)
  {
    if (ut->root_entry)
      entry->id = ut->starting_id + ut->nr_entries++;
    else
      entry->id = 0; /* Creating the root node so don't use the usual IDs */
  }
  else
    entry->id = ut->starting_id + ut->nr_entries++;


Of course ushare's code is totally different to your implementation of upnp, but maybe there's a solution in the source code.
The source code is available at the developer's blog

foo_upnp

Reply #77
Code under GPL license can't ever be used in foobar2000 components, fyi.
Full-quoting makes you scroll past the same junk over and over.

foo_upnp

Reply #78
Anyway I believe bubbleguuum can use it as a study material if he's interested. No one can disallow that.

This plugin seems to provide planty usefull features. Is there a place where I can seriously suggest making DUI SDK available so it can be really integrated without requiring columns UI?
Or in other words can anybody suggest a correct way of trying to achieve my goal?
Yes maybe you are about to say it can be done when it all matures and proves it-self stable. I see it from a different point of view. Bubbleguuum seems to be motivated right now and he's doing a lot of hard but fantastic work these days. Why FB2k team cant open the gates and make it a little easier for him?
To put some tags I'd say: Foobar 2000, accessibility, default user interface, keyboard access, streaming....

foo_upnp

Reply #79
@cmdrpaddy:  I don't think album art streaming to the PS3 ever worked, and I don't have one to test anymore. The only reason I see it could fail is that it doesn't like the URL or the returned image data (more likely).

@nullstring: might be useful to share knowledge with the author. In a future release there will be a debug mode to log many info and troubleshoot various hardware.

@pv: if I'm given access to the Element UI SDK I'll gladly add support for it but I can also wait the official release, it can't be that far, is it ?



Note that in 0.95 there's a bug with remote internet access. If you enter the wrong parameter in the "connect to remote foobar2000 server" dialog and connection (silently) fails, all future connections will fail (even with the good parameters) until you restart foobar and try again.

foo_upnp

Reply #80
v 0.96

+ fix: a failure to connect to a remote internet foobar2000 server was making all future connect attempts to fail
+ fix: A remote internet foobar2000 server listed in the UPnP Browser tree was automatically removed after 1800 secs
+ add: display a progress popup when connecting to a remote internet server and a proper failure message if connection fails
+ add: added option to enable debug messages in the console, useful to troubleshoot problematic clients (Server/Advanced Settings)
+ some misc polishing

known issues:
- there might be problems when fetch album art when connected to the server via the Internet.
- when changing changing CUI configuration (adding removing  / panels) all listed servers in the browser are removed

foo_upnp

Reply #81
Rewritten first post to explain more clearly what this component can do + some doc about remote Internet access of the server.

foo_upnp

Reply #82
Would it be possible to improve the usability with Default UI by making the browser available thru a popup window (as it is possible with the album list for example)?

foo_upnp

Reply #83
Any chance you could make it compatible with Windows Media Center too?

While trying to access, i get this at the fb2k console:

foo_upnp: FbMediaServer::ProcessHttpRequest: received request URL=/X_MS_MediaReceiverRegistrar/6F50F066-23DF-4A59-A91D-D7621F85DB10/event.xml from a LAN client
foo_upnp: NPT_HttpClient::SendRequestOnce: NPT_CHECK failed, result=-20008 [NPT_ERROR_INTERNAL]
You can fool some of the people all of the time, and all of the people some of the time, but you can not fool all of the people all of the time.

- Abraham Lincoln

foo_upnp

Reply #84
Any chance you could make it compatible with Windows Media Center too?

While trying to access, i get this at the fb2k console:

foo_upnp: FbMediaServer::ProcessHttpRequest: received request URL=/X_MS_MediaReceiverRegistrar/6F50F066-23DF-4A59-A91D-D7621F85DB10/event.xml from a LAN client
foo_upnp: NPT_HttpClient::SendRequestOnce: NPT_CHECK failed, result=-20008 [NPT_ERROR_INTERNAL]


I'll recheck that there is no regression when using WMP (as I do not have Windows Media Center) in the latest version as it used to work in previous version.

foo_upnp

Reply #85
I hope this gets you closer to xbox 360 glory:
Quote
"the only way to connect the XBox 360 to a UPnP server, was to have a service that is only found on Microsoft services (used for registering for DRM content) and for the server itself to be claimed to be made by Microsoft. Legal would not allow us to pretend to be Microsoft (although there are other servers out there that do)."    from Media Center from Google

so looking at the source code of the xbox360 compliant server, a "model name" string you could use with the xbox is:
Code: [Select]
Windows Media Connect Compatible (foo_upnp)



foo_upnp

Reply #86
This component exposes your entire computer's files to the internet.

I've sent a PM to the author about the issue as to not increase the dangers related to the exploit.


Another note:

I can't seem to stream WAV to Windows media player at all. I need to use transcoding here.
Windows media player is trying to download the entire WAV before it starts playback, but then times out and skips to the next song on the list.
Putting the URL manually in a browser lets me download the track.

foo_upnp

Reply #87
This component exposes your entire computer's files to the internet.


Wrong, as the URL scheme is different if a client connects from the Internet instead of the LAN.

foo_upnp

Reply #88
Let me post some stuff from the console, see if that helps troubleshoot my Popcorn Hour:

I'm trying to stream the following files:



Foobar2000 with your plugin does the following with "Stream in native format" set to OFF (doesn't produce a valid sound-file icon):
Without persistent URLs or DLNA:

foo_upnp: FbMediaServer::OnAction: action 'Browse' response: args = { ObjectID=0/1/5/4/0, BrowseFlag=BrowseDirectChildren, Filter=dc:title,dc:creator,upnp:class,res,res@duration,res@protection,upnp:albumArtURI,upnp:artist,u
pnp:album,upnp:originalTrackNumber, StartingIndex=0, RequestedCount=11, SortCriteria=, NumberReturned=8, TotalMatches=8, UpdateID=0 }
foo_upnp: FbMediaServer::ProcessHttpRequest: received request URL=/content/1.wav?convert=wav from a LAN client

Without DLNA but persistent URLs:

foo_upnp: FbMediaServer::OnAction: action 'Browse' response: args = { ObjectID=0/1/5/4/0, BrowseFlag=BrowseDirectChildren, Filter=dc:title,dc:creator,upnp:class,res,res@duration,res@protection,upnp:albumArtURI,upnp:artist,u
pnp:album,upnp:originalTrackNumber, StartingIndex=0, RequestedCount=11, SortCriteria=, NumberReturned=8, TotalMatches=8, UpdateID=0 }
foo_upnp: FbMediaServer::ProcessHttpRequest: received request URL=/content/file://Q:\Musik\#Modern#\0-9\10cc - The Original Soundtrack (MFSL)\08. The Film Of My Love.flac.wav?convert=wav from a LAN client

With DLNA and persistent URLs:

oo_upnp: FbMediaServer::OnAction: action 'Browse' response: args = { ObjectID=0/1/5/4/0, BrowseFlag=BrowseDirectChildren, Filter=dc:title,dc:creator,upnp:class,res,res@duration,res@protection,upnp:albumArtURI,upnp:artist,u
pnp:album,upnp:originalTrackNumber, StartingIndex=0, RequestedCount=11, SortCriteria=, NumberReturned=8, TotalMatches=8, UpdateID=0 }
foo_upnp: FbMediaServer::ProcessHttpRequest: received request URL=/content/file://Q:\Musik\#Modern#\0-9\10cc - The Original Soundtrack (MFSL)\08. The Film Of My Love.flac.wav?convert=wav from a LAN client

So far, so good.

Now, to check the other end. I'm able to browse into the Popcorn Hour's menu at
Code: [Select]
http://192.168.1.4:8883/upnp/upnp-av.cgi?cmd=cd&filter=24&level=5&udn=0/1/5/4/0&name=10cc%20-%20The%20Original%20Soundtrack%20%28UltraDisc%20II%29


It looks like this:



The first thing I notice is that the numbering/order does not correspond to the actual file names. This is the URL of the first file listed on the PCH, "The Film of My Love" (with persistent URL and DLNA):
Code: [Select]
http://192.168.1.201:56923/content/file:%252f%252fQ:%255cMusik%255c%2523Modern%2523%255c0-9%255c10cc%2520-%2520The%2520Original%2520Soundtrack%2520%2528MFSL%2529%255c08.%2520The%2520Film%2520Of%2520My%2520Love.flac.wav%3Fconvert=wav


Is this info helpful in any way?

foo_upnp

Reply #89
The first thing I notice is that the numbering/order does not correspond to the actual file names. This is the URL of the first file listed on the PCH, "The Film of My Love" (with persistent URL and DLNA):
Code: [Select]
http://192.168.1.201:56923/content/file:%252f%252fQ:%255cMusik%255c%2523Modern%2523%255c0-9%255c10cc%2520-%2520The%2520Original%2520Soundtrack%2520%2528MFSL%2529%255c08.%2520The%2520Film%2520Of%2520My%2520Love.flac.wav%3Fconvert=wav

Is this info helpful in any way?


Yes, it looks like the PCH has URL encoded the query part of the URL producing an invalid URL.
The URL should read (skipping the beginning):          ....flac.wav?convert=wav.

Notice how the ? has been wrongly encoded to %3F by the PCH.
The good news is that I noticed another UPnP client wrongly encoding the '?' while it shouldn't, and I fixed it in my current version (even if it is a bug of the client).
There are some UPnP clients that just expect a HTTP path without a query,  they will mess the URL if there is one.

I suppose it plays fine if you try to play a mp3 without having transcode to mp3 enabled (in that case there is no query in the URL) ?

Note that the effect of the DLNA switch is minor and here mostly to make the PS3 happy.

foo_upnp

Reply #90
Another note:

I can't seem to stream WAV to Windows media player at all. I need to use transcoding here.
Windows media player is trying to download the entire WAV before it starts playback, but then times out and skips to the next song on the list.
Putting the URL manually in a browser lets me download the track.


This is due to the fact that I couldn't make http seek working with WMP.
When streaming a HTTP location, WMP first do a range (seek) request. If that request fails (It does in that case),  then WMP fallback to a traditional GET request but
it will start playing only when it has read all the file. This is acceptable and fast for lossy files on a LAN but not lossless.
Until I find a way to make http seek work with WMP I have no solution.


foo_upnp

Reply #92
hey bubbleguuum, this link explains in depth the xbox 360 upnp profile, from the discovery to the description, searching and browsing phase: http://code.google.com/p/jems/wiki/XBox360Notes
seems a lot of work though =\


Already implemented all of this already (including the specific hierarchy) but there's still sth that does not work, and without a 360 to test, it's impossible to fix.
At some point I'll have a 360 to make it work.
You can enable debug traces and send  me the result but that may not be sufficient info.

EDIT: if you test, set the server netowrk name to "TEST : Windows Media Player"  in the server's main preference page, else I don't think the server will be listed by the 360.

foo_upnp

Reply #93
Already implemented all of this already (including the specific hierarchy) but there's still sth that does not work, and without a 360 to test, it's impossible to fix.
At some point I'll have a 360 to make it work.
You can enable debug traces and send  me the result but that may not be sufficient info.

EDIT: if you test, set the server netowrk name to "TEST : Windows Media Player"  in the server's main preference page, else I don't think the server will be listed by the 360.

Yeah, with that server network name it appeared, but after trying to connect it timed out. This is the log: (just for discovery I guess)
Code: [Select]
foo_upnp: FbMediaServer::ProcessHttpRequest: received request URL=/DeviceDescription.xml from a LAN client

Tried changing some advanced options (DLNA, persistent URL's) with no avail. I guess they still don't come into play because there is no actual connection taking place.

foo_upnp

Reply #94
I suppose it plays fine if you try to play a mp3 without having transcode to mp3 enabled (in that case there is no query in the URL) ?


Yes, it plays mp3, AAC and WMA perfectly over UPnP.

foo_upnp

Reply #95
Thanks for this plugin, I've been waiting for something that could integrate directly with foobar2000.  I can finally dump WMP and Tversity forever!

I use this thing primarily to stream music to a Denon 3808ci receiver, which pretty much uses a cursor up/down/back/forward interface to browse.  No keyboard or anything like that to search the remote library.  Which leads me to a couple of usability questions/requests:

1) Is there any way to make the component recognize foobar's grouping configuration in playlists?  For example, I have a dynamic playlist that keeps track of all the music I rip and encode myself.  This playlist uses the artist/date/album grouping in the default UI's playlist view.  It would be nice to be able to break down this massive playlist by those groups.

2)  Would it be possible to expose the options in the "media library" view (i.e., genre, album artist, year) for customization?  For example, it would be nice to be able to use the existing views, but have them filtered by other criteria.  For example, it would be cool to be able to bring up the "genre" view filtered by my "ENCODED" tag, or the "album" view that only shows FLAC files.

3) Similarly, it would be nice to be able to change the behavior or add new media library views.  Instead of having "genre" show albums, maybe have it break down into artists, then albums.  Also, a "folders" view would be nice, as Tversity and WMP both had this option.

foo_upnp

Reply #96
I'm having a rather odd problem with foo_upnp. i have one album that will not show one song in the correct order on our PS3. I have checked all the tags and the song appears in the correct order in foobar
Code: [Select]
The order the songs appear in foobar's album list 
01. Disclaimer
02. The Meaning Of Life
03. Mota
04. Me & My Old Lady
05. Cool To Hate
06. Leave It Behind
07. Gone Away
08. I Choose
09. Intermission
10. All I Want
11. Way Down The Line
12. Don't Pick It Up; Amazed
13. Change The World

but on the PS3 it shows up as
All I Want
Disclaimer
The Meaning Of Life
Mota
Me & My Old Lady
Cool To Hate
Leave It Behind
Gone Away
I Choose
Intermission
Way Down The Line
Don't Pick It Up
Amazed
Change The World
I have tried changing the preset from PS3 to WMP but still shows the funky track order.

Any ideas?
Who are you and how did you get in here ?
I'm a locksmith, I'm a locksmith.

foo_upnp

Reply #97
I'm having a rather odd problem with foo_upnp. i have one album that will not show one song in the correct order on our PS3. I have checked all the tags and the song appears in the correct order in foobar


Thanks for the report, will be fixed in next version. This also fixes the track order problem reported by Jorgo on the PCH.

foo_upnp

Reply #98
Thanks for this plugin, I've been waiting for something that could integrate directly with foobar2000.  I can finally dump WMP and Tversity forever!

I use this thing primarily to stream music to a Denon 3808ci receiver, which pretty much uses a cursor up/down/back/forward interface to browse.  No keyboard or anything like that to search the remote library.  Which leads me to a couple of usability questions/requests:

1) Is there any way to make the component recognize foobar's grouping configuration in playlists?  For example, I have a dynamic playlist that keeps track of all the music I rip and encode myself.  This playlist uses the artist/date/album grouping in the default UI's playlist view.  It would be nice to be able to break down this massive playlist by those groups.

2)  Would it be possible to expose the options in the "media library" view (i.e., genre, album artist, year) for customization?  For example, it would be nice to be able to use the existing views, but have them filtered by other criteria.  For example, it would be cool to be able to bring up the "genre" view filtered by my "ENCODED" tag, or the "album" view that only shows FLAC files.

3) Similarly, it would be nice to be able to change the behavior or add new media library views.  Instead of having "genre" show albums, maybe have it break down into artists, then albums.  Also, a "folders" view would be nice, as Tversity and WMP both had this option.



1. I suppose you mean that playlist nodes would be broken into browsable subnodes reflecting grouping ? why not, but not in the immediate future.

2 and 3. Configuration of the 'server generated browse tree is planned at some point, along the lines of the Album Browser configuration to give you an idea. I'll probably implement folder view too.


foo_upnp

Reply #99
new release. Now the browser is an UI Element  (as well as a CUI panel). First post to download

v 0.97

- new: browser: UI Element
- fix: browser: send items to playlist in the order the server returned them
- fix: server: in ML tree, returned album tracks were not sorted by track number (they'd appear in random order on the client if it was not itself reordering by tracknumber)
- fix: server: decode properly URLs that have the query part URL encoded (should fix non MP3/WMA/AAC formats not working on the PCH and possibly other hardware)