in

andy vt's tools & blog

Automating lazy

Transcoding video for the iPod

Last post 11-30-2007 5:05 PM by jelwood. 97 replies.
Page 1 of 7 (98 items) 1 2 3 4 5 Next > ... Last »
Sort Posts: Previous Next
  • 03-23-2007 3:12 PM

    • Coyote
    • Top 10 Contributor
    • Joined on 10-11-2006
    • Maryland
    • Posts 233

    Transcoding video for the iPod

    Download package here

    ffmpeg/mencoder profiles saved by 1.1.0.6 - use these if no profiles show up in the settings tool.

    mencoder / ffpmeg config - extract this to your DTb folder if you are using 1.1.0.6 or older. WIll overwrite existing mencoder/ffmpeg config 

    See the iPod Conversion Wiki Page for newest information

    Requirements:

    • DTb 1.2.0.8+ or 1.1.0.6+
    • iTunes 7. (iTunes 7.2+ is highly recommended if you are running on Vista. Older versions of iTunes are not Vista-ready and may crash or hang when updating the library or iPod.)
    • FFDshow (Stable Build) (only for AVIVO profile)
    • ATI AVIVO codecs.  (only for AVIVO profile)
    • Convert With Ffmpeg packages (included with DTB 1.2.0.9 and 1.1.0.6)
    NOTE: using mencoder requires ffmpeg to have a remuxing profile, so I've incuded a ffmpeg.conf with remuxing and iPod-certified H.264/AAC profiles. This will overwrite any existing ffmpeg.conf.

    You extract the zipped files/folders right into c:\program files\dvrmstoolbox. This will add the proper files to DTb. You'll then have new profiles called:

    • Export to iPod using AVIVO - detect and cut commercials, convert with ffdshow and AVIVO, import into iTunes.
    • Export to iPod using ffmpeg - detect and cut commercials, convert with ffmpeg, import into iTunes.
    • Export to iPod using mencoder - cut and convert with mencoder, remux with ffmpeg, import into iTunes. (Set ShowAnalyzer to output .EDL and be sure to set the EDL path in the profile!)

    Filed under:
  • 03-23-2007 5:01 PM In reply to

    • galt
    • Top 25 Contributor
    • Joined on 02-06-2007
    • Posts 65

    Re: Adding transcoded videos to iTunes

    i'm guessing you have, but have you looked at ipodifier?  http://www.ipodifier.com/  It does exactly this.

     

  • 03-23-2007 6:59 PM In reply to

    Re: Adding transcoded videos to iTunes

    Cool, thanks!  You can also use the iTunes Library Updater.  Here's some info on running it from the command line.
  • 03-24-2007 12:50 AM In reply to

    • Coyote
    • Top 10 Contributor
    • Joined on 10-11-2006
    • Maryland
    • Posts 233

    Re: Adding transcoded videos to iTunes

    yeah, i'm doing all of this because ipodifier is kind of lagging in development.
  • 03-26-2007 3:52 AM In reply to

    • Coyote
    • Top 10 Contributor
    • Joined on 10-11-2006
    • Maryland
    • Posts 233

    Re: Adding transcoded videos to iTunes

    Now this shows what DVRMSToolbox can really do!  

    I'm working on a graph/profile/script package that will:

    • Detect/Cut commercials (of course)
    • convert the CutDvrms to iPod-compatible mp4 (using ffdshow & AVIVO: SD or HD and extremely fast!)
    • rename the output to "show - episode - date.mp4" (iTunes doesn't like Media Center's file naming)
    • regex the new output filename to create show and episode contexts
    • use the javascript to add the video to iTunes as a TV Show, with Show/Episode set properly.

    My question: Is the metadata available in context? RenameOutputFile can find it, and what I'm doing now is using ChangeContext regexes on OutputFile to create %show% and %title% contexts.

    It's a workable solution, because I have to rename the file anyway, and it automagically uses the date if the episode title isn't there. Is there something like %WM/Title% and %WM/Episode% directly available?

  • 03-26-2007 11:11 AM In reply to

    Re: Adding transcoded videos to iTunes

    You can browse the metadata for a file using this tool.  The full collection is stored in context, but you can only use it from an action.
  • 03-26-2007 10:09 PM In reply to

    • Coyote
    • Top 10 Contributor
    • Joined on 10-11-2006
    • Maryland
    • Posts 233

    Re: Adding transcoded videos to iTunes

    huh.. i swear I tried %Title% and it came out null. Can you pass it to the command line args of a RunExternal action?

    my problem now is the &*#%ing graph I made doesn't work anymore for ATSC. It's just the avivo_divx.grf with ATI Scale Video Filter added and the filters configured to produce divx/mp3 muxed to mp4. avivo_divx doesn't even work now, and I don't know why. Video worked, and when I set ffdshow to decode AC3 audio, I transcoded with sound too. Now only the sound works!

    I loaded it in graphedit and tried to render a file, audio connects up but it won't connect a decrypt/tag to the ATI MPEG Video Decoder. I tried to manually connect video and got something like "pin cannot accept the media type" (which is probably why an explicit graph won't render either)

    Basically, it's the ATI MPEG Video Decoder not being connected, but i know it worked the other night on the same file. I even had an AVI playing in WMP.

  • 03-27-2007 7:56 AM In reply to

    Re: Adding transcoded videos to iTunes

    Coyote:

    huh.. i swear I tried %Title% and it came out null. Can you pass it to the command line args of a RunExternal action?

    my problem now is the &*#%ing graph I made doesn't work anymore for ATSC. It's just the avivo_divx.grf with ATI Scale Video Filter added and the filters configured to produce divx/mp3 muxed to mp4. avivo_divx doesn't even work now, and I don't know why. Video worked, and when I set ffdshow to decode AC3 audio, I transcoded with sound too. Now only the sound works!

    I loaded it in graphedit and tried to render a file, audio connects up but it won't connect a decrypt/tag to the ATI MPEG Video Decoder. I tried to manually connect video and got something like "pin cannot accept the media type" (which is probably why an explicit graph won't render either)

    Basically, it's the ATI MPEG Video Decoder not being connected, but i know it worked the other night on the same file. I even had an AVI playing in WMP.

    you should be able to use any string metadata value including %Title%, if you can repro the issue let me know and I'll take a look, I was having issues with some of the values (like duration) being wrong because there were read before the values were finalized; but things like title should always be right.

    you could try using a different mpeg decoder.

  • 03-27-2007 3:05 PM In reply to

    Re: Adding transcoded videos to iTunes

    Coyote:

    huh.. i swear I tried %Title% and it came out null. Can you pass it to the command line args of a RunExternal action?

    my problem now is the &*#%ing graph I made doesn't work anymore for ATSC. It's just the avivo_divx.grf with ATI Scale Video Filter added and the filters configured to produce divx/mp3 muxed to mp4. avivo_divx doesn't even work now, and I don't know why. Video worked, and when I set ffdshow to decode AC3 audio, I transcoded with sound too. Now only the sound works!

    I loaded it in graphedit and tried to render a file, audio connects up but it won't connect a decrypt/tag to the ATI MPEG Video Decoder. I tried to manually connect video and got something like "pin cannot accept the media type" (which is probably why an explicit graph won't render either)

    Basically, it's the ATI MPEG Video Decoder not being connected, but i know it worked the other night on the same file. I even had an AVI playing in WMP.

    Coyote, I wanted to invite you to the Mencoder thread (look in the Help Testing Mencoder)...  The version I've posted in this thread will read dvr-ms files without first converting to MPG.  Mencoder can encode in all the formats that IPod supports (Xvid/MP3 or H.264/AAC in both the AVI and MP4 containers).  The problem is we don't have an IPod so we don't really know if it works.  If you are interested, I would love to add you to the team.  We really could use someone to test the AAC audio for us and help figure out the command line switches for the IPod.

  • 03-27-2007 5:27 PM In reply to

    Re: Adding transcoded videos to iTunes

    Just a note that the iPod does not support MP3 audio in video streams - only AAC.

    Also, while I don't have a mencoder command-line that works on iPods, I do have the following ffmpeg command-line that works (from Videora):

    "C:\Program Files\VideoraiPodConverter\apps\ffmpeg.exe" -y  -maxfr 30 -i "C:\Documents and Settings\HTPC\Local Settings\Temp\temp.mpg" -title "House_WTTG_04_07_2006_19_58_02.dvr-ms" -timestamp "7/5/2006 12:15:01 AM" -bitexact -vol 256 -vcodec xvid -s 320x240 -b 512 -async 1 -acodec aac -ac 2 -ab 48 -f mp4 "D:\iPod Videos\House - Deception (7_4_2006 7_58 PM).mp4"

    Hope that helps some!
     

  • 03-27-2007 5:29 PM In reply to

    Re: Adding transcoded videos to iTunes

    Also, here are the specs from Apple:

    Video formats supported: H.264 video, up to 1.5 Mbps, 640 by 480 pixels, 30 frames per sec., Low-Complexity version of the H.264 Baseline Profile with AAC-LC audio up to 160 Kbps, 48 kHz, stereo audio in .m4v, .mp4, and .mov file formats; H.264 video, up to 768 Kbps, 320 by 240 pixels, 30 frames per sec., Baseline Profile up to Level 1.3 with AAC-LC audio up to 160 Kbps, 48 kHz, stereo audio in .m4v, .mp4, and .mov file formats; MPEG-4 video, up to 2.5 Mbps, 640 by 480 pixels, 30 frames per sec., Simple Profile with AAC-LC audio up to 160 Kbps, 48 kHz, stereo audio in .m4v, .mp4, and .mov file formats

  • 03-27-2007 7:52 PM In reply to

    • Coyote
    • Top 10 Contributor
    • Joined on 10-11-2006
    • Maryland
    • Posts 233

    Re: Adding transcoded videos to iTunes

    I'll take another look at it... the last time I tried it, I don't think it muxed the mp4 container properly.

     


    EDIT: That thread is hard to follow and the link to the mencoder build is struckout. Where's the latest build I should be using? 

  • 03-27-2007 10:00 PM In reply to

    • Coyote
    • Top 10 Contributor
    • Joined on 10-11-2006
    • Maryland
    • Posts 233

    Re: Adding transcoded videos to iTunes

    Anywho, I think the problem I'm having with a graph is the ATI MPEG Video Encoder. After using it a couple of times it stops working for HD content, even if that content has been scaled down to 320 x (auto). That's why I'm getting the "pin is already connected" error in Graphedit until I disconnect the video path and just process audio. If I reboot, it starts working again... for a while.

     AVIVO being an ATI product, this does not surprise me at all. 

     Now the other problem: I Re-read the howto on explicit graphs, and I see my snafu in the XML editing. That will teach me to RTFM a little more carefully.

  • 03-28-2007 3:19 AM In reply to

    Re: Adding transcoded videos to iTunes

    Coyote:

    Anywho, I think the problem I'm having with a graph is the ATI MPEG Video Encoder. After using it a couple of times it stops working for HD content, even if that content has been scaled down to 320 x (auto). That's why I'm getting the "pin is already connected" error in Graphedit until I disconnect the video path and just process audio. If I reboot, it starts working again... for a while.

     AVIVO being an ATI product, this does not surprise me at all. 

     Now the other problem: I Re-read the howto on explicit graphs, and I see my snafu in the XML editing. That will teach me to RTFM a little more carefully.

    I had a similar problem with the encoder, but releasing the graph always fixed it; I didn't need to reboot... it could be an issue with graphedit although ati doesn't have the best record for producing quality sw :)

    let me know if you need any assistance with explicit graphs, I know it's pretty complex and the documentation could be lacking in some areas. 

  • 03-28-2007 8:09 AM In reply to

    • Coyote
    • Top 10 Contributor
    • Joined on 10-11-2006
    • Maryland
    • Posts 233

    Re: Adding transcoded videos to iTunes

    The whole action is working great now that I built the explicit XML the right way. Those AVIVO filters will turn out an ipod compatible h.264 at about 3x-4x speed
     

Page 1 of 7 (98 items) 1 2 3 4 5 Next > ... Last »
@2008 andy vt
Powered by Community Server (Non-Commercial Edition), by Telligent Systems