Media Share - Mediatomb Is Now Working

Discussion in 'DIRECTV Tips and Resources' started by boilerjt, May 18, 2008.

  1. MyCatsNameIsBernie

    MyCatsNameIsBernie Cool Member

    14
    0
    Dec 31, 2008
    I tried mediatomb in the hope of solving the HR2x photo display aspect ratio problem. Up until now I have been using TVersity.

    Thanks to the great info on this thread, I built mediatomb on Ubuntu 8.04, and it worked (at least for images and music) on the first try!

    The good news is I was able to use ImageMagic to change the photo's aspect ratio to cancel out the HR2x's distortion. I changed config.xml's <rescalejpeg> to run this script:
    Code:
    #!/bin/sh
    image=1080x720
    border=1080x758
    result=1213x758
    convert "$1" -auto-orient -resize $image +profile '*' -bordercolor black -border $border -gravity center -crop $border+0+0 -resize $result! "$2"
    The pixel dimensions work best with 3:2 images. They are approximate and can probably be improved. I made some images with Photoshop with round circles, displayed them on my TV, and measured them with a ruler. Then I experimented with different settings for image, border, and result until I was able to fill the screen vertically, and the circles measured round with a ruler.

    Note that the script adds a border (padding) on the top and bottom to compensate for the part of the image that normally gets stretched and then cropped (in the vertical direction) by the HR2x. It changes the aspect ratio slightly to compensate for the distortion introduced by the HR2x.

    Updated 2/2/09: The settings for image, border, result were changed, and now work well with 3:2 images in HD mode. There is no longer any need to set the HR2x to 480i original format. The above settings work best when tuned to a 720P station prior to entering Media Share. It you start with a 480i or 1080i station, the top and bottom of your images will be slightly cropped

    Another issue I noticed on Ubuntu 8.04: The pre-built Ubuntu ImageMagick package (version 6.3.7) has a bug that prevents auto-orient from working. I had to build and install ImageMagick from source to make auto-orient work.

    So here is my question:

    There are no photo thumbnails displayed by mediatomb. Is there a solution to this, or any hope of one? (My googling found no answer.) The lack of thumbnail support is the main feature I miss from TVersity.

    Thanks for the help!
     
  2. boilerjt

    boilerjt Icon

    908
    0
    Jan 11, 2007
    Thanks for the contribution :) As for thumbnails, I have never gotten them to work with MediaTomb. Actually, I prefer the photo list approach and found thumbnail display too buggy and slow.
     
  3. Feb 3, 2009 #543 of 637
    jdhoover

    jdhoover Mentor

    36
    0
    Dec 2, 2008
    boiler, any idea why my hr20 doesn't show avi's? If I rename the avi to mpg, it shows up, and plays just fine. but, its annoying to have to rename all the avi's to mpg. I wonder if i'll have the same problem with dvd iso's.
     
  4. Feb 3, 2009 #544 of 637
    jdhoover

    jdhoover Mentor

    36
    0
    Dec 2, 2008
    yep, confirmed, same problem with iso files. and if i rename the iso to mpg, the hr ain't happy, and won't play it (unlike how it will play the renamed avi file). Thoughts?
     
  5. Feb 3, 2009 #545 of 637
    jdhoover

    jdhoover Mentor

    36
    0
    Dec 2, 2008
    alright, so also, how do we give mediatomb a URL to a youtube video that the directv unit can play?
     
  6. Feb 4, 2009 #546 of 637
    boilerjt

    boilerjt Icon

    908
    0
    Jan 11, 2007
    What is the mimetype of the avi file after it is imported? You can check the mimetype from the webui using the edit icon. If it is a dvix or xvid, the mimetype should be video/x-msvideo.

    Also, since the hr2x will not play avi files, they have to be transcoded. This information is posted in the wiki:

    http://mediatomb.cc/dokuwiki/transcoding:transcoding#directv_hr2x_transcoding
     
  7. Feb 4, 2009 #547 of 637
    boilerjt

    boilerjt Icon

    908
    0
    Jan 11, 2007
    The iso dvd playback feature is not yet working properly. Hopefully, Jin will find some time to work on this soon...
     
  8. Feb 4, 2009 #548 of 637
    boilerjt

    boilerjt Icon

    908
    0
    Jan 11, 2007
    You don't provide URLs for YouTube in MediaTomb. It provides a listing for you. In config.xml, you'll find something like this:

    Code:
        <online-content>
          <!-- Make sure to setup a transcoding profile for flv -->
          <YouTube enabled="yes" refresh="28800" update-at-start="yes" purge-after="604800" racy-content="include">
            <favorites user="mediatomb"/>
            <standardfeed feed="most_viewed" time-range="today"/>
            <playlists user="mediatomb"/>
            <uploads user="mediatomb"/>
            <standardfeed feed="recently_featured" time-range="today"/>
          </YouTube>
        </online-content>
    
    Make sure it is enabled. If you have a youtube account, replace the user "mediatomb" with your username and your favorites and playlists will be show in MediaTomb. There will be listed in the "online Services" menu. You must also transcode these as well since the hr2x cannot play flv files. You can use the vlcyoutube transcoding profile from the wiki. All of the YouTube options are documented in doc/readme.lyx.
     
  9. GregLee

    GregLee Hall Of Fame

    1,703
    19
    Dec 28, 2005
    I generated a series of jpeg images with various aspect ratios, looking for a size that would fill my 16:9 TV screen, and found that a 1440x720 jpeg would do it. (I can't say for sure that that is exactly right -- maybe it's really 1460x720, e.g.)

    Accordingly, I have changed my transjpeg script to say this:
    Code:
    #!/bin/bash
    exec convert "$1" -resize 1440x720 +profile '*' - > "$2"
    
    I think it's possible that the aspect ratio for videos is also not quite what one would expect.

    Edit: Looking at http://mediatomb.cc/dokuwiki/transcoding:transcoding, I see that in boilerjt's latest version of config.xml there is no longer reference to a transjpeg script, so I guess in the most recent version of config.xml, one could just change the arguments for "convert" from "1080x720" to "1440x720", but I haven't yet actually tried that.
     
  10. boilerjt

    boilerjt Icon

    908
    0
    Jan 11, 2007
    Greg,
    I cleaned up the wiki a little and incorporated some of the scripts directly into the transcoding profiles in config.xml. Please let me know how 1440x720 works and feel free to update the wiki.
     
  11. GregLee

    GregLee Hall Of Fame

    1,703
    19
    Dec 28, 2005
    "1440x720" seems to work. I did update the wiki.
     
  12. GregLee

    GregLee Hall Of Fame

    1,703
    19
    Dec 28, 2005
    Sorry, that change doesn't quite make sense. If an image is 16:9 and so should occupy the entire screen, and actually only 2:1 images will occupy the entire screen, we should stretch out a 16:9 image to 2:1, or 18:9. 18/16 is 112.5 percent, and "convert" allows percentage resize arguments. So I've now changed the argument to "-resize 112.5%x100%". I do hope that's right.
     
  13. shredhead

    shredhead New Member

    4
    0
    Jan 27, 2009
    Trying mediatomb for the first time with my brand new HR22's I got yesterday...

    Mediatomb appears to be working on my Suse 10.3 box since my Windows box can see it as a PnP device and if I click that I get the mediatomb web page with all my shared items. The share and its contents show up in the music photos and more on both DVR units. BUT, every item, no matter what it is, AVI file, photo, MP3, etc. has an X on the left and cannot be accessed.

    Mediatomb, vlc, ffmpeg, and the dependencies I had to install to make vlc install properly were ALL rpm packages not built by me, but downloaded from the public repositories. SuSE firewall is turned off. Everything is on the same subnet. It's obvious I've done something wrong but I don't know where to start. Versions of everything are listed below.

    Code:
    bigone:/etc/mediatomb # rpm -qa | grep vlc
    vlc-gnome-0.9.8a-8.1
    libvlccore0-0.9.8a-8.1
    vlc-0.9.8a-8.1
    vlc-noX-0.9.8a-8.1
    vlc-devel-0.9.8a-8.1
    libvlccore1-1.0.0-2009012201.1
    vlc-qt-0.9.8a-8.1
    libvlc2-1.0.0-2009012201.1
    bigone:/etc/mediatomb # rpm -qa |grep mediatomb
    mediatomb-mysql-0.11.0-0.pm.4
    mediatomb-0.11.0-0.pm.4
    bigone:/etc/mediatomb # rpm -qa |grep ffmpeg
    ffmpeg-0.4.9.16647svn-20090116.pm.2207
    
    What could I be missing?



    [by the way, for anyone using MySQL, you cannot set the database up with no password. that's not in the docs]
     
  14. Stuart Sweet

    Stuart Sweet The Shadow Knows!

    37,060
    288
    Jun 18, 2006
    I've moved this to the information, tips and resources forum.
     
  15. GregLee

    GregLee Hall Of Fame

    1,703
    19
    Dec 28, 2005
    In the first post of this thread, boilerjt says that mediatomb version 0.11.0 will not work with the HR20. That's the version you have. I compiled mine from the svn, but there may be a released version now that works -- 0.12.0 ?
     
  16. boilerjt

    boilerjt Icon

    908
    0
    Jan 11, 2007
    No official 0.12 release yet. Real life has been keeping Jin from working on it recently and he says hopefully he'll be back working on it soon.
     
  17. boilerjt

    boilerjt Icon

    908
    0
    Jan 11, 2007
    As Greg mentioned, version 0.11 will not work with the HR2x. You need to compile the current SVN version and all of the info you need is linked in the first post and scattered throughout this thread.

    One other thing... Make sure you set up the transcoding profiles and scripts in MediaTomb and ensure <transcoding enabled="yes"> in config.xml or you will see the 'X's.
     
  18. jjaromin

    jjaromin Mentor

    34
    0
    Nov 11, 2006
    Hi everyone. I hope I'm not hijacking. But, I'm starting to collect all my dvd's and transfer them to a 3TB raid array for storage / use. I have seen that mediatomb will transcode DVD images. Forgive my ignorance, but what is the best format to rip the DVDs into for this. Also, if anyone has any recommendations for a Mac (or I can use windows with bootcamp) utility to perform this action it would be greatly appreciated, otherwise I'll just search for a utility.

    Thanks,
    John
     
  19. boilerjt

    boilerjt Icon

    908
    0
    Jan 11, 2007
    As of now, DVD images do not work in the current SVN (pre-release) code, but a solution has been found that works perfectly with the HR2x (all credit goes to bmeeks) :) This solution internally remuxes a selected title from the DVD to TS, so no transcoding is needed :) Right now, we are waiting for the MediaTomb developer to review the patch and hopefully implement it soon.

    What I do is rip a DVD using DVD Decrypter (Windows app) to a single iso file. MediaTomb can then read and import the iso so that titles are sorted by audio soundtrack and language. You can also select by chapter and this helps a lot since there is no FF or RW.
     
  20. Mar 2, 2009 #560 of 637
    shredhead

    shredhead New Member

    4
    0
    Jan 27, 2009
    Thanks to those who pointed it out, I was trying to use a version with my HR22 that doesn't work properly.


    So I have attempted to build it from SVN. In addition I dropped the mysql database and recreated it, and to give it more transcode options I compiled ffmpeg even though I had installed it previously as part of the distro.

    I'm now at another standstill.. it shows up as a PnP device on the network, even my Windows PCs can see it... but if I browse to the web page I cannot log in (I don't have accounts enabled, but it is still asking for a log in).

    I'm sure it's something simple but I have no idea what is wrong. I can see from my log file that as soon as I attempt to log in, it dies but can't tell why.

    Code:
    2009-03-02 14:09:23    INFO: Loading configuration from: /root/.mediatomb/config.xml
    2009-03-02 14:09:23    INFO: Checking configuration...
    2009-03-02 14:09:23    INFO: Setting filesystem import charset to UTF-8
    2009-03-02 14:09:23    INFO: Setting metadata import charset to UTF-8
    2009-03-02 14:09:23    INFO: Setting playlist charset to UTF-8
    2009-03-02 14:09:23    INFO: Configuration check succeeded.
    2009-03-02 14:09:23    INFO: Initialized port: 49153
    2009-03-02 14:09:23    INFO: Server bound to: 192.168.50.104
    2009-03-02 14:09:24    INFO: MediaTomb Web UI can be reached by following this link:
    2009-03-02 14:09:24    INFO: http://192.168.50.104:49153/
    2009-03-02 14:09:53    INFO: thread cleanup; thread_id=-1225151600
    
     

Share This Page

spam firewall