Until recently, my iTunes media has been trapped on my PC without any easy path to my television. Apple offers some great solutions, using an AppleTV or connecting a Mac Mini to my big screen would provide a great viewing experience. However, we already have a Tivo and rely on this for just about everything – so it seems like this would be a good place to start.
The first step was to configure a media server that would be visible from our TiVo. Using pyTivo was the ideal choice, and this was incredibly easy to configure. There were a few key settings to optimize it for our Tivo Premiere. Using the output pixel width/height the max resolution was bumped up to take advantage of the HD resolution, and ffmpeg_pram was used to maximize a dual-core dual-CPU server configuration:
# Full path to ffmpeg with options
# Output Pixel Width
# Use 16:9 aspect ratio
Increasing the number of threads for transcoding allows the pyTivo server to make HD quality video instantly accessible from my TV. You will need to exercise caution, however, if your server has less hardware then you need to adjust accordingly.
In this configuration, getting videos to the Tivo is as simple as copying them to the
/export/video/Movies directory. While this is possible to do directly, automating this process for videos and movies in my iTunes database is more ideal. For movies tagged with meta-data it would be even better to publish this so that this information is displayed on my TiVo.
My first step was to relocate my iTunes database to my pyTivo server. These files were placed into
/export/video/iTunes and includes Music, Movies and TV Shows. For the purposes of this only the Movies are going to be considered for publishing to Tivo. As videos are added to my iTunes database, they are copied into a subdirectory under
/export/video/iTunes/Movies so my script simply watches this directory for new content.
Typical execution is something like this:
perl AtomicSage.pl monitor /export/video/iTunes/Movies /export/video/Movies/
A few things are going to be needed for AtomicSage, both AtomicParsley and the Perl library AtomicParsley::Command need to be installed. Additionally, the script assumes a Linux environment to monitor the iTunes movie directory for changes. When a new movie appears in iTunes, AtomicSage copies it to
/export/video/Movies and organizes the files by genre. A meta file is created for each video, inside this file things like movie title, description and genre are stored – this information is displayed on your Tivo screen.
You can use this with home movies and something like MetaX as well. Once your videos are built, run MetaX and you can edit the meta-data within the M4V container. Using AtomicSage, once videos are added to iTunes the meta data is extracted and displays on your TV as you browse media from your movie collection.
If you’re ready to go, download AtomicSage and get your movie database organized.