1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

PyTivo Video Manager HME App for pyhme

Discussion in 'Developers Corner' started by jbernardis, Apr 20, 2011.

  1. May 2, 2011 #41 of 735
    lew

    lew Active Member

    3,964
    3
    Mar 12, 2002
    Thanks for the suggestion.

    jbernardis--Thanks for sharing your work. Great tool. I may go back to the SD version. The font size is too small for me to read on a 42" LCD. I suspect you have better eyesight then some of us.:)
     
  2. May 2, 2011 #42 of 735
    innocentfreak

    innocentfreak Active Member

    8,950
    3
    Aug 25, 2001
    Florida
    Ok glad it wasn't just me with the font size.
     
  3. May 2, 2011 #43 of 735
    jcthorne

    jcthorne Active Member

    2,726
    3
    Jan 28, 2002
    Houston
    If you go into the .py file, the font sizes and colors are easily adjusted. Jbernardis did a great job of documenting the code throughout.

    Any one here want to tackle a project converting meta data in an xml or ifo file to a pytivo compatible .txt file? I'd like to get the data from thumbgen to the tivo but not sure where to start with this.
     
  4. May 2, 2011 #44 of 735
    wmcbrine

    wmcbrine Ziphead

    10,368
    22
    Aug 2, 2003
    Well, "xml" isn't a format -- you'll have to be more specific. jbernardis' metadata.py is borrowed from pyTivo, although he's trimmed it down. My version already supported importing data from TiVo-style XML (two different kinds just for that), as well as EyeTV (which uses plists, which use XML). But I assume none of those are what you want.

    "ifo", I'm not even sure what you mean. There are .IFO files that come as part of a DVD structure, but they don't contain (this kind of) metadata. And then I see ".nfo" files, but those seem to be plain text in no fixed format.
     
  5. May 2, 2011 #45 of 735
    jbernardis

    jbernardis New Member

    1,072
    0
    Oct 21, 2003
    Princeton NJ
    Version 0.2c is now in the repository. A new option has been added to the config.ini file.

    descsize=<size of the font for descriptive text>

    For example

    descsize=20


    If omitted, it will default to its present value of 16.

    BTW - I don't think my 54 year old eyes are any better than anyone elses :) - I chose the 16 point font because I needed it to fit the larger descriptions on screen.

    Also note - if you choose a large font, the image will not be overwritten. The description view does NOT overlap the view for the image. What this means is that is the descriptive font is too large for the text, the text will simply be truncated.
     
  6. May 2, 2011 #46 of 735
    innocentfreak

    innocentfreak Active Member

    8,950
    3
    Aug 25, 2001
    Florida
    I am guessing this will only change the episode summary and not the size of the episode name or series name?
     
  7. May 2, 2011 #47 of 735
    jbernardis

    jbernardis New Member

    1,072
    0
    Oct 21, 2003
    Princeton NJ
    Correct - only the description field.
     
  8. May 3, 2011 #48 of 735
    jcthorne

    jcthorne Active Member

    2,726
    3
    Jan 28, 2002
    Houston
    I should have been more specific. I will try and attach an .nfo file generated by thumbgen here for example. Since thumbgen webscrapes the data and images for both movies and tv shows and is actively being developed, being able to use this data for tivo would prove useful.

    Code:
     <?xml version="1.0" encoding="utf-8"?>
    <movie xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ThumbGen="1">
      <hasrighttoleftdirection>false</hasrighttoleftdirection>
      <title>Avatar</title>
      <originaltitle>Avatar</originaltitle>
      <year>2009</year>
      <plot>Disabled Marine Jake Sully travels to planet Pandora to become an avatar, ingratiate himself with the natives and help Americans mine lucrative unobtainium. But he finds himself in an interstellar conflict after falling for Na'vi warrior Neytiri.</plot>
      <filename>Avatar.1080p.2009.mp4</filename>
      <tagline>Enter the World of Pandora</tagline>
      <metascore>84</metascore>
      <rating>8.2</rating>
      <homepage>http://www.avatarmovie.com/</homepage>
      <episodes />
      <episodesnames />
      <writers />
      <gueststars />
      <id>tt0499549</id>
      <releasedate>18.12.2009</releasedate>
      <mpaa>Rated PG-13 for intense epic battle sequences and warfare, sensuality, language and some smoking. (also special edition)</mpaa>
      <actor>
        <name>Sam Worthington</name>
        <name>Zoe Saldana</name>
        <name>Sigourney Weaver</name>
        <name>Stephen Lang</name>
        <name>Michelle Rodriguez</name>
        <name>Joel Moore</name>
        <name>Giovanni Ribisi</name>
        <name>CCH Pounder</name>
        <name>Laz Alonso</name>
        <name>Wes Studi</name>
        <name>Dileep Rao</name>
        <name>Matt Gerald</name>
        <name>Dean Knowsley</name>
      </actor>
      <genre>
        <name>Action</name>
        <name>Adventure</name>
        <name>Science Fiction</name>
        <name>Romance</name>
      </genre>
      <director>
        <name>James Cameron</name>
      </director>
      <runtime>162</runtime>
      <certification>PG-13</certification>
      <studio>
        <name>20th Century Fox</name>
      </studio>
      <country>
        <name>United Kingdom</name>
        <name>United States of America</name>
      </country>
      <cover>
        <name>http://cf1.imgobject.com/posters/88c/4cc481d15e73d6778400188c/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/374/4bd29ddd017a3c63e8000374/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/351/4bed3468017a3c37ac000351/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a32/4bc95853017a3c57fe027a32/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/284/4c60d0215e73d63460000284/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a5a/4bc95859017a3c57fe027a5a/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/730/4d4075c67b9aa15bab002730/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/8f4/4d376aac5e73d6334f00d8f4/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/1a5/4c6b23605e73d65f7e0001a5/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/277/4bd29e03017a3c63eb000277/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/3d2/4bd2b01b017a3c63f50003d2/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/255/4bdda594017a3c20c3000255/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/32f/4cb1bc627b9aa1263f00032f/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a3c/4bc95853017a3c57fe027a3c/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/673/4d78c5ef7b9aa157b4000673/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/0cf/4bedd282017a3c45930000cf/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a64/4bc9585d017a3c57fe027a64/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/04b/4bedd253017a3c458900004b/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/527/4ce2dd595e73d60f71000527/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a50/4bc95858017a3c57fe027a50/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a5f/4bc9585a017a3c57fe027a5f/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/5d8/4ce453967b9aa168b00005d8/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a55/4bc95859017a3c57fe027a55/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a4b/4bc95858017a3c57fe027a4b/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/a46/4bc95857017a3c57fe027a46/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/097/4c41ccc25e73d60f3b000097/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/posters/2e2/4d7cf7365e73d651740022e2/avatar-original.jpg</name>
      </cover>
      <backdrop>
        <name>http://cf1.imgobject.com/backdrops/a2e/4bc95852017a3c57fe027a2e/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a0e/4bc95848017a3c57fe027a0e/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/20e/4bd1e35c017a3c63ea00020e/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/2e7/4bd9de08017a3c1c090002e7/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/9ee/4bc95842017a3c57fe0279ee/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a16/4bc9584c017a3c57fe027a16/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a26/4bc9584e017a3c57fe027a26/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a2a/4bc9584f017a3c57fe027a2a/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/0e1/4bdd0e91017a3c20c30000e1/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a1a/4bc9584d017a3c57fe027a1a/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/9ea/4bc9583e017a3c57fe0279ea/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/042/4bd5c1c4017a3c658a000042/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/9f2/4bc95842017a3c57fe0279f2/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a02/4bc95846017a3c57fe027a02/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/9f6/4bc95844017a3c57fe0279f6/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/348/4bd9dcff017a3c1bfb000348/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/ff8/4d29a7e25e73d626b0002ff8/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a1e/4bc9584d017a3c57fe027a1e/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a22/4bc9584e017a3c57fe027a22/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/a12/4bc9584c017a3c57fe027a12/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/9fa/4bc95845017a3c57fe0279fa/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/800/4cf54d7b5e73d6299e000800/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/74d/4cf54e065e73d6299900074d/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/9fe/4bc95846017a3c57fe0279fe/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/833/4cf54e325e73d6299a000833/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/84f/4cf54e425e73d6299b00084f/avatar-original.jpg</name>
        <name>http://cf1.imgobject.com/backdrops/754/4cf54e555e73d62999000754/avatar-original.jpg</name>
      </backdrop>
      <mediainfo>
        <Resolution>
          <Flag>Resolution_1080p</Flag>
        </Resolution>
        <resolution>1080P</resolution>
        <Format>
          <Flag>Format_Mpeg</Flag>
        </Format>
        <format>mpeg4</format>
        <Video>
          <Flag>Video_H264</Flag>
        </Video>
        <video>avc</video>
        <Audio>
          <Flag>Audio_DolbyDigital</Flag>
        </Audio>
        <audio>DD51</audio>
        <Subtitles>
          <Flag>Unknown</Flag>
        </Subtitles>
        <SubtitlesText>Unknown</SubtitlesText>
        <framerate>23.976</framerate>
        <aspectratio>16:9</aspectratio>
        <videoresolution>1920x1080</videoresolution>
        <videocodec>AVC</videocodec>
        <videobitrate>8 Mbps</videobitrate>
        <audiocodec>AC-3</audiocodec>
        <audiochannels>6</audiochannels>
        <audiobitrate>448 Kbps</audiobitrate>
        <durationseconds>9701</durationseconds>
        <durationminutes>161</durationminutes>
        <duration>2h 41m</duration>
        <filesizebytes>10444713701</filesizebytes>
        <filesize>9.73 GB</filesize>
        <container>MPEG-4</container>
        <language>English</language>
        <languagecode>en</languagecode>
        <languages>English</languages>
        <languagecodes>en</languagecodes>
        <externalsubtitles />
      </mediainfo>
    </movie>
    

    Just FYI, the author of Thumbgen just messaged me and has agreed to look at adding direct support of pyTivo metadata .txt files to the program. I sent him a link to the wiki site http://pytivo.sourceforge.net/wiki/index.php/Metadata
    and an example of one of my files.
     
  9. May 8, 2011 #49 of 735
    windracer

    windracer joined the 10k club

    11,580
    3
    Jan 3, 2003
    St. Pete, FL
    Is there an option in config.ini to hide directories? For pyTivo, I use the .meta subfolder to keep all the metadata files. pyTiVo hides this folder but vidmgr does not.
     
  10. May 8, 2011 #50 of 735
    jbernardis

    jbernardis New Member

    1,072
    0
    Oct 21, 2003
    Princeton NJ
    This capability doesn't exist now, but theres no reason I couldn't implement it. Let me think about how it should be designed.

    One question - should I ignore all directories below the meta directory? I knew this isn't the way meta directories are used, but it's a possibility my logic needs to consider. Initially my thought is to eliminate any directory that has a node named meta somewhere in the path name beneath the rout.
     
  11. May 8, 2011 #51 of 735
    windracer

    windracer joined the 10k club

    11,580
    3
    Jan 3, 2003
    St. Pete, FL
    Or just hide any subdirectory that starts with a period?
     
  12. May 8, 2011 #52 of 735
    wmcbrine

    wmcbrine Ziphead

    10,368
    22
    Aug 2, 2003
    Yes, a leading period is the Unix convention for hidden files and directories, which is why pyTivo uses it. It pays no special attention to "meta". You probably want the same behavior as pyTivo, since this is a front-end for it.

    Code:
    if f.startswith('.'):
        continue
     
  13. May 8, 2011 #53 of 735
    jbernardis

    jbernardis New Member

    1,072
    0
    Oct 21, 2003
    Princeton NJ
    Ok - version 0.2d is now available at github. The only change is to ignore directories that start with a period ala the unix convention.
     
  14. May 9, 2011 #54 of 735
    windracer

    windracer joined the 10k club

    11,580
    3
    Jan 3, 2003
    St. Pete, FL
  15. May 9, 2011 #55 of 735
    rrr22777

    rrr22777 New Member

    532
    0
    Jul 31, 2002
    Does this do HD Photos? I am keeping Tivo Desktop running in a VM just for the HD photos.
     
  16. May 10, 2011 #56 of 735
    jcthorne

    jcthorne Active Member

    2,726
    3
    Jan 28, 2002
    Houston
    vidmgr does not but pytivo does.
     
  17. May 10, 2011 #57 of 735
    wmcbrine

    wmcbrine Ziphead

    10,368
    22
    Aug 2, 2003
    What you can do is to rip the HD Photos app out of TiVo Desktop -- it's in Java, and will run on Linux, Mac, etc. -- and use pyTivo as the backend for it, instead of TD. See here.

    Alternatively, if all you want is a slide show, you can use the "Pictures" sample app from the HME for Python package.
     
  18. May 14, 2011 #58 of 735
    windracer

    windracer joined the 10k club

    11,580
    3
    Jan 3, 2003
    St. Pete, FL
    I've been digging around trying to find this on the pyTivo and streambaby wikis, but how do you add the cover art to the metadata files? What's the syntax/format?
     
  19. May 14, 2011 #59 of 735
    jbernardis

    jbernardis New Member

    1,072
    0
    Oct 21, 2003
    Princeton NJ
    I don't know about pytivo and/or streambaby, but I don't use the metadata file to find the thumbnail. I simply look for a file name following a specific rule.
     
  20. May 14, 2011 #60 of 735
    windracer

    windracer joined the 10k club

    11,580
    3
    Jan 3, 2003
    St. Pete, FL
    Doh, right there in your readme. :eek: I'll check it out, thanks!
     

Share This Page