Sign up here and you can log into the forum!

Thumbs for UMSP channels

Discussion, features, plugins--everything about zoster's UMSP UPnP Media Server software

Thumbs for UMSP channels   

Postby gotteN » Thu May 27, 2010 2:19 am

Hey all,

so after some reading and asking people I would like to share my new knowledge about thumbs for UMSP channels...may someone else want to take advantage of this possibilty :-).

1. What you have to do is place a thumb in the /etc/umsp directory. For example Apple-Trailers.thumb
2. You have to edit the media-files.php file and change the following line

'upnp:album_art'=> ' ',
To
'upnp:album_art'=> '/var/www/umsp/Apple-Trailers.thumb',

Code: Select all
$myMediaItems[] = array(   
   'id'         => 'umsp://plugins/apple-trailers',   #Attribute of item
   'parentID'      => '0',                     #Attribute of item
   'restricted'   => '1',                     #Attribute of item
   'dc:creator'   => 'myCreator',
   'dc:title'      => 'Apple-Trailers',
   'dc:date'      => '2009-12-30',
   'upnp:author'   => 'myAuthor',
   'upnp:artist'   => 'myArtist',
   'upnp:album'   => 'myAlbum',
   'upnp:genre'   => 'myGenre',
   'upnp:length'   => '2:10:20',
   'desc'         => 'myDesc',
   'upnp:class'   => 'object.container',
   'upnp:album_art'=> '/var/www/umsp/Apple-Trailers.thumb',
#   'res'         => '',
   'duration'      => 'myDur3',            #Attribute of res
   'size'         => 'mySize3',            #Attribute of res in bytes
   'bitrate'      => 'myBitr',            #Attribute of res
#   'protocolInfo'   => '*:*:video/avi:*',      #Attribute of res
   'protocolInfo'   => '*:*:*:*',      #Attribute of res
   'resolution'   => 'myReso',            #Attribute of res
   'colorDepth'   => 'myColor',   


Also if you want to "delete the UMSP v.1.03 channel you have to edit the control-reply.php ( /etc/umsp/ )

1.uncomment the line after $items = $myMediaItems; --> There should be in brackets something like ( 'UMSP....' )
2.Put after the uncommented line $msgItems = array();

Code: Select all
$items = array();
$cachedItems = _readCache($upnpRequest['objectid']);
if (isset($cachedItems)) {
   # cache hit
   $items = $cachedItems;
} else {
   # cache miss
   switch ($upnpRequest['objectid']) {
      case '0':
         # Root items:
         $items = $myMediaItems;
         $msgItems = array();
         $items = array_merge($items, $msgItems);
         break;
         
      default:
         # The parse_url function returns an array in this format:
         # Array (
         #    [scheme] => http
         #    [host] => hostname
         #    [user] => username
         #    [pass] => password
         #    [path] => /path
         #    [query] => arg=value
         #    [fragment] => anchor
         # )
         $reqObjectURL = parse_url($upnpRequest['objectid']);
         switch ($reqObjectURL['scheme']) {
            case 'umsp':
               switch ($reqObjectURL['host']) {
                  case 'plugins':
                     # handle plugins
                     # call with parameters query and path
                     $items = _callPlugin($reqObjectURL['path'], $reqObjectURL['query']);
                     break;
                  case 'local':
                     # handle local content
                     # call with parameters query and path
                     $items = _localMain($reqObjectURL['path'], $reqObjectURL['query']);
                     break;
               } # end switch
               break;
               # URL is not umsp:// try to load URL as DIDL-XML ??
         } # end switch
   } # end switch
} # end if


That´s it...if there are some open questions...feel free to ask :D. Hope you enjoy this...or maybe everyone knows this^^ ? dunno ! hf :)
gotteN
Beta Tester
 
Posts: 18
Joined: Thu May 20, 2010 12:26 am

Re: Thumbs for UMSP channels   

Postby CrashX » Thu May 27, 2010 12:34 pm

I believe brad said he was going to talk the author about removing "UMSP v.1.03"?
CrashX
Global Moderator
 
Posts: 143
Joined: Thu Apr 15, 2010 9:04 am

Re: Thumbs for UMSP channels   

Postby zoster » Thu May 27, 2010 1:23 pm

Yeah I don't think the version info is needed anymore. I'll remove it.
zoster
WDLXTV Team
 
Posts: 218
Joined: Wed Apr 14, 2010 10:14 am

Re: Thumbs for UMSP channels   

Postby maber » Thu May 27, 2010 10:01 pm

@ gotteN:
how did you make the thumb-file? i tried this
1. What you have to do is place a thumb in the /etc/umsp directory. For example Apple-Trailers.thumb
and therefore i just renamed a jpg to ".thumb", but no thumb was displayed.

thanks for your short input. :)
maber
n00b
 
Posts: 18
Joined: Sat May 15, 2010 11:59 am

Re: Thumbs for UMSP channels   

Postby OneStone » Thu May 27, 2010 11:14 pm

What firmware version do you use? I think this will only work with ext3.
OneStone
WDTVer
 
Posts: 23
Joined: Sat May 01, 2010 11:51 pm

Re: Thumbs for UMSP channels   

Postby maber » Fri May 28, 2010 2:11 am

yes, since yesterday i use the ext3-fw, but there is still no thumb :(
maber
n00b
 
Posts: 18
Joined: Sat May 15, 2010 11:59 am

Re: Thumbs for UMSP channels   

Postby gotteN » Fri May 28, 2010 3:49 am

@maber, may you can show me your media-items.php ?

As you just did...I renamed the .jpg to .thumb file...Have you checked the spelling of the entries you made ?
gotteN
Beta Tester
 
Posts: 18
Joined: Thu May 20, 2010 12:26 am

Re: Thumbs for UMSP channels   

Postby recliq » Fri May 28, 2010 7:57 am

@all,

the file should be a normal image file with it's normal extension (like test.png, apple.jpg, or whatever)
I don't think it's a good idea to change the file extension to .thumb, because there are a lot of applications and also some OS's (like Windows) which decide what to do with a file just based on the file ending.
­WDLXTV Project Maintainer
-:] If you like my contributions feel free to donate for a beer or a new flash drive. ...and always remember: RTFM! (README, FAQ, WIKI) [:-
User avatar
recliq
WDLXTV Team
 
Posts: 5513
Joined: Thu Apr 15, 2010 8:09 am
Location: Kiel, Germany

Re: Thumbs for UMSP channels   

Postby maber » Fri Jun 04, 2010 12:04 am

@ relicq:
the file should be a normal image file with it's normal extension (like test.png, apple.jpg, or whatever)

if this works, it is also fine for me. i just thought that is must be a file with the extension ".thumb"

so, i will try this, when i´ll be home again. :)
maber
n00b
 
Posts: 18
Joined: Sat May 15, 2010 11:59 am

Re: Thumbs for UMSP channels   

Postby PaulF » Tue Jun 08, 2010 1:22 pm

I have tried file and URL methods to show the thumbs in podcast audio files. The file method works for the list thumbs screen, but does not show the thumb in the player. The URL method shows the thumb in the list and in the player except for one site.

File example of a dump of the DIDL XML using a local file:
Code: Select all
  <item id="umsp://plugins/podcasts?http://podcastdownload.npr.org/anon.npr-podcasts/podcast/35/127501683/npr_127501683.mp3">
    <dc:title>NPR: 06-05-2010 Wait Wait... Don't Tell Me!</dc:title>
    <upnp:class>object.item.audioItem</upnp:class>
    <upnp:artist>Sat, 05 Jun 2010 17:01:46 -0400</upnp:artist>
    <upnp:genre>Podcast</upnp:genre>
    <upnp:album>NPR: Wait Wait... Don't Tell Me! Podcast</upnp:album>
    <upnp:album_art>/tmp/stick/albumart/npr_wwdtm_image_75.jpg</upnp:album_art>
    <res protocolInfo="http-get:*:audio/mpeg:*">http://podcastdownload.npr.org/anon.npr-podcasts/podcast/35/127501683/npr_127501683.mp3</res>
  </item>

URL method works great for this and most sites:
Code: Select all
  <item id="umsp://plugins/podcasts?http://podcastdownload.npr.org/anon.npr-podcasts/podcast/35/127501683/npr_127501683.mp3">
    <dc:title>NPR: 06-05-2010 Wait Wait... Don't Tell Me!</dc:title>
    <upnp:class>object.item.audioItem</upnp:class>
    <upnp:artist>Sat, 05 Jun 2010 17:01:46 -0400</upnp:artist>
    <upnp:genre>Podcast</upnp:genre>
    <upnp:album>NPR: Wait Wait... Don't Tell Me! Podcast</upnp:album>
    <upnp:album_art>http://media.npr.org/images/podcasts/thumbnail/npr_wwdtm_image_75.jpg</upnp:album_art>
    <res protocolInfo="http-get:*:audio/mpeg:*">http://podcastdownload.npr.org/anon.npr-podcasts/podcast/35/127501683/npr_127501683.mp3</res>
  </item>


This site is the only one that doesn't work in URL album_art:
Code: Select all
  <item id="umsp://plugins/podcasts?http://www.thisamericanlife.org/radio-archives/episode/409/held-hostage">
    <dc:title>This American Life #409: Held Hostage</dc:title>
    <upnp:class>object.item.audioItem</upnp:class>
    <upnp:artist>Sun, 06 Jun 2010 18:00:00 -0500</upnp:artist>
    <upnp:genre>News &amp; Politics</upnp:genre>
    <upnp:album>This American Life</upnp:album>
    <upnp:album_art>http://www.thisamericanlife.org/sites/all/play_music/player-logo.png</upnp:album_art>
    <res protocolInfo="http-get:*:audio/mpeg:*">http://feeds.thisamericanlife.org/~r/talpodcast/~5/LOf4sykFdYA/409.mp3</res>
  </item>


Anyone have an answer to one of these two fix questions:

1. How do you get the album_art to show in the music player when the album_art is in a local file?
or
2: Why doesn't the album_art URL for "This American Life" work?
http://www.thisamericanlife.org/sites/all/play_music/player-logo.png

Better yet, is there a way to dump the messages between the site and WD TV?
User avatar
PaulF
Developer
 
Posts: 427
Joined: Sat May 08, 2010 8:34 pm
Location: Oregon

Next

Return to UMSP Media Server

Who is online

Users browsing this forum: No registered users and 1 guest

cron