View Full Version : Post your favorite commercial skip method
AudioNutz
11-19-2008, 01:58 AM
This is my first post on the TiVo Community forum. I've been lurking around for a while, done quite a few searches, and see that there is a ton of old information still around. (I'm looking for current information)
So... An informal poll:
What is your favorite method for skipping commercials on shows that you have downloaded from your TiVo to your computer? I know there are several out there, but what is your favorite?
The reason I ask is this: I travel for a living. The only way for me to watch TV on a plane, or in an airport, is to pull the .TiVo show to my computer and then transfer it to my iPod. I've got my methods down pretty well, but I was hoping to improve this process by skipping over the commercials as I encode for my iPod.
Please don't discriminate about OS's in your responses. In this age of PC virtualization, I have access to Macs, Windows, and just about any Linux, so I've tried tons of stuff.
1. iTiVo - I like "iTiVo", but it's too quirky, and too slow. (for me) There's also a few features I think are missing, and I'm tempted to bother the writer with a few feature requests.
2. KMTTG - My current favorite is "KMTTG". I wish it ran on a Macintosh OS, but the functionality is all there, except for the iPod encoder, so I need to encode after it does the commercial skip. ALSO: I'm currently seeing artifacts or hiccups in the resulting video after the commercials have been removed, so I'm looking for something better. (quality)
I'm not above writing my own, or assigning command line statements to some hot-folders on a computer, but the command lines for these tools have proven VERY difficult for me to figure out. If anyone has any favorite command-line statements, please feel free to share...
Thanks everyone! (In advance)
-Bill
Honestly your question is incredibly broad. So I'll take a stab at some of the points:
kmTTG does encode for you. Just make sure you encode it as an h.264 file at 480x320 and you're done.
iTiVo and kmTTg use the same encoder library in their tools, and the same comskip. Exactly the same setting should be close to the same speed. What you're probably seeing is two different target conversions (it's the encoding that is generally the slow part). As for the hiccups in kmttg. Again that's a function of the encoder settings used.
The nice thing kmttg does that iTiVo doesn't is it can have one download going while another show is encoding (which if you are getting multiple shows, makes a big difference). And it has more features. If you're using a PC or Linux, just go with it (don't virutalize a mac!)
The nice thing iTiVo does is that it will fetch the show and put it in itunes and sync it to your iphone automatically. I generally just mark the shows I want and then leave it running with my iphone connected overnight. If you're using a mac, just go with it (don't virtualize windows).
As for your last question, this is the invocation that would be used by iTiVo if you wanted to download the shows yourself (I assume you have the source movie on your computer courtesy of connecting over the web)
I'll pretend you have iTiVo installed in /Applications/ and will refer to the tools and config files in there to make my life easier. I also assume that your source movie you downloaded from the tivo to your Desktop via a web browser. And renamed it to mymovie.tivo. <MAK> is your MAK
cd ~/Desktop
/Applications/iTiVo.app/Contents/Resources/tivodecode -n -m <MAK> -o "/tmp/mymovie.mpg" "mymovie.tivo"
/Applications/iTiVo.app/Contents/Resources/comskip --ini=/Applications/iTiVo.app/Contents/Resources/comskip.ini "/tmp/mymovie.mpg"
/Applications/iTiVo.app/Contents/Resources/mencoder -edl /tmp/mymovie.edl -of lavf -lavfopts format=ipod -ovc x264 -x264encopts nocabac:level_idc=30:bitrate=384:threads=auto:bframes=0:glob al_header -vf pp=lb,dsize=480:320:0,scale=-8:-8,harddup -af volume=13:1 -oac faac -faacopts mpeg=4:object=2:raw:br=128 -hr-edl-seek -o "mymovie.mp4" "/tmp/mymovie.mpg"
(This won't speed up anything, or make it pretty, but if you'd rather do it yourself.. there you are.)
TiVo_Rod
11-19-2008, 04:44 PM
Honestly your question is incredibly broad. So I'll take a stab at some of the points:
...
This is great! The OP didn't want to bother emailing the author of iTiVo, yet amazingly the first response to his post IS from the author of iTiVo.
:-)
AudioNutz
11-19-2008, 05:12 PM
...The OP didn't want to bother emailing the author of iTiVo, yet amazingly the first response to his post IS from the author of iTiVo...
:eek:
I'll admit that I certainly did not expect that! It is very difficult for me to tell how much interest each of these software authors has in supporting their product. If I was doing this as a hobby, I certainly wouldn't cater to every person out there...
...kmTTG does encode for you. Just make sure you encode it as an h.264 file at 480x320 and you're done...
I see that it does encode, but for some reason it gives me a file that cannot be played on my iPod5G. I'm playing around with the profiles, but have yet to have any success.
...iTiVo and kmTTg use the same encoder library in their tools, and the same comskip. Exactly the same setting should be close to the same speed...
I thought that would be the case too, and honestly I prefer to use a Macintosh, but my results are 6 hours of processing time to download, decode, comskip, and encode. (This is for a 30 minute show)
...The nice thing kmttg does that iTiVo doesn't is it can have one download going while another show is encoding (which if you are getting multiple shows, makes a big difference)...
I also like the capability to save the files at each step of the process. For example, with kmttg I can just download, decrypt, comskip, and save that file out to go back into my TiVo to watch on my regular TV. (Without commercials)
Since it appears to me that you're interested in this type of feedback (Hooray!) I'll hit you with a list of other ideas too. Would you prefer it to be presented to you publicly here on this forum so everyone else can comment, or would you prefer it on the "Issues" tab of your google page?
ALSO: I really appreciate the code that you put in the previous message. I may attempt to do some HotFolder process to make this run headless on my XServe.
Quick answers (easiest first):
If you have enhancement suggestions, the best place to submit them is on the google code page, under "issues". I will warn you ahead of time that I only have so much time to devote to the program, and can't make any promises (easy enhancements get added first). I'm also mostly focussing on bug fixes right now -- the code is still very broken.
I see you mention you have an ipod5G, not an iphone, so change the resolution to 320x240 (instead of 480x320 which is the iphone native one) in the instructions I sent you above.
I don't know for sure why the output of kmttg isn't playing on your ipod, but it's almost definitely because you didn't correctly encode it to an mpeg4 file that is compatible with your ipod (turns out there are a LOT of relevant values). There is a thread on this forum for kmttg (http://tivocommunity.com/tivo-vb/showthread.php?t=387725), and the author is very active on it, so you may want to post a question there.
As to iTiVo: 6 hours is INCREDIBLY long. If you're using comskip in iTiVo, you should be seeing how long the download, the commercial removal, and the encode is taking. Which is taking the long time? (a 30 minute high-quality show takes me about 15 minutes to download and about 20 minutes to encode to iphone resolution -- if you don't select commercial removal, it should take about 20 mins total since download and encoding is done in parallel). Are you trying to convert it to a different resolution than ipod? Do you have a particularly old/slow computer?
Although iTiVo doesn't let you save the intermediate files, if all you want is 'download, decrypt, comskip, and save, then you should use the 'MPEG2-TS' download format. If all you want is download and decrypt, then select the 'no encoding' format.
HOWEVER!!! comskipping with the mpeg2-ts will probably cause a CRAPLOAD of audio/video sync issues. Not my fault, but that's what you get when you try to clip transport streams at random locations.
TiVo_Rod
11-19-2008, 06:06 PM
I thought that would be the case too, and honestly I prefer to use a Macintosh, but my results are 6 hours of processing time to download, decode, comskip, and encode. (This is for a 30 minute show)
It takes me a long time to download, comskip, and encode with my PPC G5 iMac. I've been looking at buying a new iMac. For a 30 minute episode it takes a few hours. For a 2 hour show it takes around 12 hours.
A cheaper route that I am looking at is the Elgato Turbo.264 encode stick thing. Yoav mentioned that he may contact Elgato to see what options a developer has to write software against their encoder.
I hope he is successful.
AudioNutz
11-19-2008, 07:20 PM
...As to iTiVo: 6 hours is INCREDIBLY long. If you're using comskip in iTiVo, you should be seeing how long the download, the commercial removal, and the encode is taking. Which is taking the long time? (a 30 minute high-quality show takes me about 15 minutes to download and about 20 minutes to encode to iphone resolution -- if you don't select commercial removal, it should take about 20 mins total since download and encoding is done in parallel). Are you trying to convert it to a different resolution than ipod? Do you have a particularly old/slow computer?
I agree, 6 hours is a very long time, but it seems to approximate the performance that "TiVo_Rod" is getting above. I'm using a Dual 2Ghz G5 PowerMac with 2GB ram. Mine takes 6 hours, his takes 12. (I realize that length of the show is different, as is the machine)
The longest part of the process seems to be the final encoding process. The download is pretty quick. It seems to be no slower than when I use my browser to download the show, the commercial skip seems to only take minutes, but the rest of the encoding process takes the remainder of the 6 hours. (I'm guessing at the exact time, because I do not watch it for the entire time it's encoding)
Conversely, encoding the same 30 minute show on "Visual Hub" takes 21 minutes on the same computer.
...Although iTiVo doesn't let you save the intermediate files, if all you want is 'download, decrypt, comskip, and save, then you should use the 'MPEG2-TS' download format. If all you want is download and decrypt, then select the 'no encoding' format...
Good idea, but then I would also want the show encoded for my iPod5G, because I never quite know where I'm going to be watching it. (Home or airport)
It takes me a long time to download, comskip, and encode with my PPC G5 iMac. I've been looking at buying a new iMac. For a 30 minute episode it takes a few hours. For a 2 hour show it takes around 12 hours.
That's similar to the performance I'm seeing, but I really don't want to wait 12 hours just for a single show. Right now, when I travel I follow these steps:
With my MacBook Pro, I log into my home network via VPN.
I use Apple Remote Desktop to remotely control the G5 PowerMac on my home network.
I use Safari to download the show from the TiVo to a spot on the local hard drive that my AntiVirus software cannot scan. (I've had troubles with Symantec AntiVirus attempting to scan the downloads before they are done, corrupting them forever)
I use "TiVo Decoder" drag-n-drop AppleScript to decrypt.
I use "Visual Hub" to convert for the iPod. (I may do several shows at once, and I may let it run while I sleep at night)
Then (When I wake up the next morning) I ZIP the file, re-name it, and place it on my FTP server on my home network. (It's a Tiger XServe)
When I go into my office the next day, I will use an FTP client software, (Fetch) to queue up the shows to download to my laptop.
Once the show arrives at my laptop, I unzip, and place it on my iPod5G.
Now... (I can read your mind) You're asking yourself why I'm using FTP, why I'm ZIPing the show, and why I'm re-naming it.
I'm using FTP, because my office network security folks do not allow AFP or SMB protocol connections outside our network.
I'm ZIPing and then re-naming the files because I don't want the office network security folks to see the names of the shows I'm watching being transferred in the open via FTP. If I re-name them after I ZIP them, they will be properly named automagically when I un-ZIP them on my laptop.
I'm also guessing that you're thinking "Why not just buy a slingbox?", but that wouldn't help me when I'm actually aboard an airplane. (I'm also doing these conversions on my Home computers, rather than transferring the native TiVo shows over the internet, due to size/bandwidth differences, and also due to the fact that I have two Series 2 TiVo's on the home network, and a limited number of routing possibilities in my home router.)
So the goal of all of this activity is to be able to queue up the conversion and transfer of these files in the easiest way possible. iTiVo certainly comes very close to this functionality, and I'll be sending some suggestions very soon, and explaining "Why" a person would want it to work that way. What I do today does work... However I'm just looking for constant improvement. (Especially since Visual Hub is no longer being sold, and it doesn't have the capability to skip commercials)
AudioNutz
11-19-2008, 07:25 PM
Now that I've looked at the way you're caching files in the 'tmp' folder, I'm also wondering if I need to force my AntiVirus software to ignore this location as well. I wonder if this is what's causing it to take 6 hrs...
I'll give it a try...
Now that I've looked at the way you're caching files in the 'tmp' folder, I'm also wondering if I need to force my AntiVirus software to ignore this location as well. I wonder if this is what's causing it to take 6 hrs...
I'll give it a try...
I don't think it's your antivirus (unless it's literally intercepting every read/write). H264 is a VERY CPU intensive encode. And I'm doing a bunch of stuff to smooth out the interlace, so I'd blame the quality settings I'm using with mencoder (i suspect the altivec optimizations are not as fast as the SSE ones either).
Try the following. Select ipod as the download format, go into advanced, and replace the video encoder options with the following:
-of lavf -lavfopts format=ipod -ovc x264 -x264encopts subq=2:me=dia:nocabac:level_idc=30:bitrate=256:threads=auto: bframes=0:global_header -vf dsize=320:240:0,scale=-8:-8,harddup
I added a subq=2 and an me=dia option and removed the anti-aliasing (pp=lb). This *should* speed up the encoding, although will generate a significantly crappier encoded movie. Tell me how that works out for you.
AudioNutz
11-24-2008, 11:16 PM
...If you're using comskip in iTiVo, you should be seeing how long the download, the commercial removal, and the encode is taking. Which is taking the long time? (a 30 minute high-quality show takes me about 15 minutes to download and about 20 minutes to encode to iphone resolution -- if you don't select commercial removal, it should take about 20 mins total since download and encoding is done in parallel). Are you trying to convert it to a different resolution than ipod? Do you have a particularly old/slow computer?
I just got back to doing this again... Just downloading without the comskip, and then encoding (iPod setting) takes 4hrs, 10min with iTiVo. Is this expected? (30min show, basic quality, Series 2)
I've turned off virus software, and even made sure nothing else was running on the machine. (Dual G5 Processors, 2Ghz)
Conversely, JUST doing a download of the same show takes 10min. So I guess the 4hrs is for the encoding, compared to 21min with VisualHub.
As a side note, I've got KMTTG to run on my Mac... But I'm not sure I like the GUI.
I just got back to doing this again... Just downloading without the comskip, and then encoding (iPod setting) takes 4hrs, 10min with iTiVo. Is this expected? (30min show, basic quality, Series 2)
(Dual G5 Processors, 2Ghz)
IS this expected? I guess :). I don't own a G5 mac, but the acceleration code for altivec processors is different from the i386. What you'll need to do is find a video encode setting that is fast enough to please you, yet with enough quality to not piss you off .. (I'm using one of the dual-core imacs, and the encode in parallel with the download takes about 30 mins for a 30 min show).
Have you tried putting the video settings I sent above into your advanced video settings? It *should* run somewhat faster...
The other thing is I've started putting the time into getting the code to use the elgato turbo.264 stick. So if you're not finding any settings that work for you, and REALLY need this to work, you can probably pick one up for less than $100.. The stick supposedly will encode 640x480 in real-time...
BUT don't do it until you hear that it works.. So far it's preliminary code...
AudioNutz
11-25-2008, 12:23 AM
On the same machine, a Dual G5 Mac, I just ran the same exact show through the process using KMTTG. I'll admit that I'm using ffmpeg for the encoding here...
23 minutes for download, decrypt, comskip, comcut, and encode for iPod.
I'm just wondering why the performance would be so much different. This is kinda why I asked the original question "What's your favorite commercial skip method?" (Because I was seeing a performance gap when I ran KMTTG on my PeeCee also) I was thinking there were many ways to do this, but now I see that iTiVo and KMTTG are the two leading methods.
I'll try iTiVo on my intel-based Mac now, to see if your theory about the altivec vs. i386 code is right...
AudioNutz
11-25-2008, 12:51 AM
...I'll try iTiVo on my intel-based Mac now, to see if your theory about the altivec vs. i386 code is right...
...And there you have it... intel-based Mac, 14 minutes for download, decrypt, comskip, comcut, and encode for iPod. (same 30min show, basic quality)
...And there you have it... intel-based Mac, 14 minutes for download, decrypt, comskip, comcut, and encode for iPod. (same 30min show, basic quality)
It's not a lot of work for me to allow you to use ffmpeg instead of mencoder. They're both using the same library so it *shouldn't* cause such a gap if they are encoding with all the same values. I'd hazard a guess that kmttg isn't de-interlacing/smoothing the video as much (pp=lb slows encoding down a LOT). But if you try those video settings I sent and it's still slow, I'll add ffmpeg support..
...And there you have it... intel-based Mac, 14 minutes for download, decrypt, comskip, comcut, and encode for iPod. (same 30min show, basic quality)
Is the latest beta any faster on your powerPC mac?
(also, is it working on 1.4? I don't have any of these systems to test on...)
AudioNutz
11-28-2008, 02:43 PM
Is the latest beta any faster on your powerPC mac?
b7 is much faster. 61min for the same 30minute show to download, decrypt, comskip, and encode for iPod. Still not the performance I'm getting with KMTTG on this machine, but it's MUCH faster than it was!
(also, is it working on 1.4? I don't have any of these systems to test on...)
Do you mean Mac OS X 10.4 (Tiger) If that's what you mean, no, iTiVo doesn't seem to want to do any of the decrypt, encode stuff on Mac OS X 10.4.x. (I wish it would, because then I could run it on my XServe in my home network.)
b7 is much faster. 61min for the same 30minute show to download, decrypt, comskip, and encode for iPod. Still not the performance I'm getting with KMTTG on this machine, but it's MUCH faster than it was!
Do you mean Mac OS X 10.4 (Tiger) If that's what you mean, no, iTiVo doesn't seem to want to do any of the decrypt, encode stuff on Mac OS X 10.4.x. (I wish it would, because then I could run it on my XServe in my home network.)
Damn.. I was hoping that by compiling against the 10.4u SDK it would be 10.4 compatible (b7 or 1.5). Guess I'll just have to document that it's 10.5 only.
Can you tell me what it prints out when you run:
/Applications/iTiVo.app/Contents/Resources/mencoder
(I want to see if the error is helpful in figuring out what is missing).
AudioNutz
11-28-2008, 03:26 PM
Well, let me try again... I didn't try the latest beta on 10.4.x... I assumed that it wouldn't work because your 1.4 (released version wasn't playing well.)
Well, let me try again... I didn't try the latest beta on 10.4.x... I assumed that it wouldn't work because your 1.4 (released version wasn't playing well.)
Ah yes please.. try the latest (I manually forced it to use only stuff out of the 10.4u sdk) -- <crossing fingers>.
AudioNutz
11-28-2008, 03:53 PM
...Can you tell me what it prints out when you run:
/Applications/iTiVo.app/Contents/Resources/mencoder...
Bus Error.
AudioNutz
11-28-2008, 03:55 PM
Is there something you would like me to attempt to compile on a 10.4.x machine directly? I'm willing to give it a shot.
(I'm not a programmer, so you'll need to hit me with explicit step-by-step)
Is there something you would like me to attempt to compile on a 10.4.x machine directly? I'm willing to give it a shot.
(I'm not a programmer, so you'll need to hit me with explicit step-by-step)
Wow.. bus error :( yikes.
Well, unfortunately you'd need to compile mencoder, tivodecode, libfaac, libx264, and compskip -- as universal binaries. To even get ready to compile you'd need to install Xcode with all the developer tools. It's a headache :(
I guess for now I'll keep trying but mark it as 10.5 only... (at least it gets rid of the headache of having to use external SDKs).
AudioNutz
11-28-2008, 04:26 PM
I've already got the developer tools installed, and I'm ready to go. If you hit me with a step-by-step of compiling those tools, as well as the best place to find the source code, I'm ready to try.
I've already got the developer tools installed, and I'm ready to go. If you hit me with a step-by-step of compiling those tools, as well as the best place to find the source code, I'm ready to try.
Well, first thing to try is to find a copy of mencoder/tivodecode/comskip that work on 10.4 (just look on their homepages). Put them into /Applications/iTiVo.app/Contents/Resources
If you can't, or they don't work for you, I'm unlikely to want to follow up on problems if this fails though (or if this explanation is not making sense).
Get the latest source code for mplayer, libx264, mp3lame, libfaac, tivodecode (use google and svn, cvs, git, or whatnot). This is the script I use to build all the mess (you'll probably want to remove the -isysroot blahblah10.4u references).
SRCDIR=/Users/yoav/src
LAME=lame-398-2
cd $SRCDIR
mkdir binaries
export CFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -arch ppc"
export CPPFLAGS=""
export LDFLAGS="-arch i386 -arch ppc"
cd tivodecode-0.2pre4
make distclean
./configure --disable-dependency-tracking
make
cp tivodecode ../binaries/tivodecode
export CFLAGS='-isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386'
export CPPFLAGS='-arch i386'
export LDFLAGS='-arch i386'
cd $SRCDIR/x264
./configure
make clean
make
cd $SRCDIR/faac
./configure --without-mp4v2 --enable-shared=no --enable-static=yes
make clean
make
cd $SRCDIR/$LAME
./configure --disable-shared --disable-frontend
make clean
make
export CFLAGS='-isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386 -O2 -fomit-frame-pointer'
export CPPFLAGS='-arch i386'
export LDFLAGS='-arch i386'
cd $SRCDIR/mplayer
make distclean
rm ./uname
./configure --disable-png --enable-mp3lame --enable-x264 --disable-mplayer --enable-faac --enable-faad-internal --disable-freetype --with-extraincdir=$SRCDIR/faac/include/:$SRCDIR/x264:$SRCDIR/$LAME/include --with-extralibdir=$SRCDIR/faac/libfaac/.libs/:$SRCDIR/x264:$SRCDIR/$LAME/libmp3lame/.libs --extra-libs-mencoder="-lx264 $SRCDIR/faac/libfaac/.libs/libfaac.a"
make
cp ./mencoder ../binaries/mencoder-i386
export CFLAGS='-arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk'
export CPPFLAGS='-arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk'
export LDFLAGS='-arch ppc'
cd $SRCDIR/x264
make distclean
./configure --host=ppc-apple-darwin
make
cd $SRCDIR/faac
make distclean
./configure --host=ppc-apple-darwin --without-mp4v2 --enable-shared=no --enable-static=yes
make
cd $SRCDIR/$LAME
make distclean
./configure --host=ppc-apple-darwin --disable-shared --disable-frontend
make
cd $SRCDIR/mplayer
make distclean
export OPATH=$PATH
export PATH=.:$PATH
echo '#!/bin/sh
echo powerpc
' > uname
chmod a+rx uname
./configure --disable-png --enable-mp3lame --enable-x264 --disable-mplayer --enable-faac --enable-faad-internal --disable-freetype --with-extraincdir=$SRCDIR/faac/include/:$SRCDIR/x264:$SRCDIR/$LAME/include --with-extralibdir=$SRCDIR/faac/libfaac/.libs/:$SRCDIR/x264:$SRCDIR/$LAME/libmp3lame/.libs --extra-libs-mencoder="-lx264 $SRCDIR/faac/libfaac/.libs/libfaac.a"
export PATH=$OPATH
rm uname
make
cp ./mencoder ../binaries/mencoder-ppc
cd $SRCDIR/binaries
lipo -create mencoder-i386 mencoder-ppc -output mencoder
vBulletin® v3.6.8, Copyright ©2000-2012, Jelsoft Enterprises Ltd.