# Tivo's native HD format, and pytivo



## adessmith (Oct 5, 2007)

I've looked over these forums and I cant find exactally what I am looking for.

I know that standard definition .tivo files are basically MPEG-2 files.
I can rip a DVD and convert the VOB to a MPG file and the tivo handles it natively without any transcoding with pytivo. This keeps the original quality of the video and the multi-channel sound in tact at the expense of large file sizes.

Im just wondering, if I want to send a HD file to the tivo, what format does it need to be for the tivo, and pytivo, to treat it as a 'tivo friendly' and not transcode it? If I were to rip a blu-ray disc to transfer to the tivo natively, what format would it need to be in?
I believe the standard BD format is m2ts.
I know DVD's are .VOB (which is a container for MPEG-2)
Is the m2ts format a container, and if so what does it contain (MPEG-4 maybe?)

Also,
Copy protection aside, can anyone recomend a program that will rip a BD disc to an HD format that tivo handles natively?

Thanks for any help you guys can give me.


----------



## wmcbrine (Aug 2, 2003)

What the TiVo wants for HD is the same as what it wants for SD: MPEG-2 program streams. The exception is if you're using the "push" feature; in that case, you can also send MP4 files with H.264 video and AAC or AC3 audio, or WMV files with VC1 video and WMA2 audio. There are restrictions on the specs; somewhere there's a chart, I forget where...

MPEG-2 program streams aren't actually the "native" format, BTW -- the TiVo remuxes them coming in and going out -- but they're what we have to work with.


----------



## swezey (Nov 28, 2008)

I kind of have this same question... I think... I ripped a bunch of the kids videos (mostly Disney animated stuff) to mp4 H.264. They are really small (like 500MB - awesome!!) but how do I get them back to the Tivo? What is the "PUSH" feature exactly and how so I use it? Thanks!


----------



## swezey (Nov 28, 2008)

OK let me actually be more specific:

What I'd like to do is:

a) Bring recorded material from the TiVo to the PC, edit out the commercials, compress to mp4 and send BACK to the TiVo with all the metadata... AND....

b) Rip my DVD's to mp4 and send them to the TiVo.

I have TiVo Desktop 2.7 (but not the PLUS upgrade), VideRedo TV Suite, AnyDVD, HandBrake, etc. but I'm still not even sure this can be done or the best way to go about it. I also have the latest version of DIVX PRO if that is a better format for what I want to do. I DO NOT have PyTiVo and honestly I've read some of the threads and it looks a little to complicated for me. I'm not a computer geek - I just want to download, edit, compress and re-upload to save the space and not have to skip the commercials. Oh, and while we are on this subject, I have the latest kmttg - the one built on Java - it worked fine enough but the ad detection was miserable. VRD is much better - almost perfect in fact. So then I found TVAP and was so happy I almost cried but... guess what??? The results using TVAP and the results using the VRD GUI on the ad detect ARE DIFFERENT!!?? I know they shouldn't be but I'm telling you they are. TVAP was cutting out several minute long intros to shows that VRD never did - I don't know why. So I'm back to manual editing.

Anyway, thanks for reading this long winded post. As usual, this is a great forum and I appreciate all the help I've gotten here. I still have so much to learn... Thanks to all!

- Bill


----------



## wmcbrine (Aug 2, 2003)

You can't do it without TiVo Desktop Plus or pyTivo.

Not to mention, this thread has "pyTivo" in the title...


----------



## dlfl (Jul 6, 2006)

swezey said:


> ........ VRD is much better - almost perfect in fact. So then I found TVAP and was so happy I almost cried but... guess what??? The results using TVAP and the results using the VRD GUI on the ad detect ARE DIFFERENT!!?? I know they shouldn't be but I'm telling you they are. TVAP was cutting out several minute long intros to shows that VRD never did - I don't know why. So I'm back to manual editing.
> ......


As the author of TVAP (link in signature) I am surprised by this too! My understanding was that TVAP would use whatever Ad Detective settings you had set in TVSuite. I've started a thread in the VideoReDo forums questioning this.

Do you by chance have VideoReDo Plus ALSO installed? One quirk of TVAP is that is uses the COM interface to whichever version of VRD (Plus or TVSuite) that you last used. I've not been able to find a way to control this. The Ad Detective parameters are kept in the Windows Registry according to how you set them in the VRD program(s). The only way I can conceive that you get different results is if you are actually using different settings that were made in the Plus version (if it is installed).

Also, to attempt to answer another question: "Push" is a feature in wmcbrine's version of pyTivo (see pyTivo link in his signature). It provides a Web interface where you can select videos in your pyTivo folders and send them to the Tivo (instead of selecting them on the Tivo NPL and "pulling" them, which is the default mode of operation of pyTivo).

I encourage you to plunge into pyTivo. You can get help either on the pyTivo forums  or in the pyTivo thread on this forum.


----------



## swezey (Nov 28, 2008)

wmcbrine said:


> You can't do it without TiVo Desktop Plus or pyTivo.
> 
> Not to mention, this thread has "pyTivo" in the title...


Sorry if this is in the wrong place - I think I did a search on H.264...


----------



## swezey (Nov 28, 2008)

dlfl said:


> As the author of TVAP (link in signature) I am surprised by this too! My understanding was that TVAP would use whatever Ad Detective settings you had set in TVSuite. I've started a thread in the VideoReDo forums questioning this.
> 
> Do you by chance have VideoReDo Plus ALSO installed? One quirk of TVAP is that is uses the COM interface to whichever version of VRD (Plus or TVSuite) that you last used. I've not been able to find a way to control this. The Ad Detective parameters are kept in the Windows Registry according to how you set them in the VRD program(s). The only way I can conceive that you get different results is if you are actually using different settings that were made in the Plus version (if it is installed).
> 
> ...


The ONLY version of VRD I have ever installed is TV Suite - I understood the operation to be exactly as you stated. I was quite confident that TVAP would produce the same results so I queued up 24 episodes of an hour long series that I record, only to find that many of them started in a few minutes... But, when I would manually process them using the GUI they would not do this. I'm at a loss as well. Maybe someone else with better troubleshooting skills has experienced this and can chime in.

I'll look into PyTivo - it really does sound great - but I have no idea about Python, Perl, tk, scripts, ffmpeg or anything else it seems to require. When I have an hour or two to kill (maybe in 2010 or 2011  ) I'll try to get it all sorted out. Until then, it sounds like I can't do what I am talking about without it - correct?? Thanks again for all your help!

P.S. But with TiVo DT PLUS and PyTivo I can "push" MP4 onto the TiVo internal drive and watch it right from there?? I'm not crazy about leaving a monster workstation with a 700 watt PS running 24 X 7 just so I can watch an episode of House whenever I have a free half hour. That's about $30 a month of electricity!


----------



## moyekj (Jan 24, 2006)

That's funny about VRD Ad Detect. I had the opposite experience - comskip worked much better, especially for HD sources. I actually do have code to use Ad Detect instead of comskip in kmttg, but since comskip worked much better in my trials that's what I enable by default. I could have an option to use Ad Detect instead and will probably add that for next release. But ultimately neither comskip or VRD Ad Detect are anywhere near perfect and I always advocate hand editing if you want perfect cuts, perhaps using VRD or comskip as a starting point (though to me I'd rather start from a clean slate for hand editing since it becomes a mess to fix comskip/VRD cut points when they are wrong).


----------



## swezey (Nov 28, 2008)

moyekj said:


> That's funny about VRD Ad Detect. I had the opposite experience - comskip worked much better, especially for HD sources. I actually do have code to use Ad Detect instead of comskip in kmttg, but since comskip worked much better in my trials that's what I enable by default. I could have an option to use Ad Detect instead and will probably add that for next release. But ultimately neither comskip or VRD Ad Detect are anywhere near perfect and I always advocate hand editing if you want perfect cuts, perhaps using VRD or comskip as a starting point (though to me I'd rather start from a clean slate for hand editing since it becomes a mess to fix comskip/VRD cut points when they are wrong).


I'm running 64 bit Vista with 4GB RAM if you think that might make any difference...  The 24 episodes I mentioned above I did all by hand and VRD was perfect - every one! If only I could automate it... But it really does go pretty quick. I was doing an hour show every three minutes. So I spent a little over an hour and fifteen minutes I'd say. Still, I'd rather do something else and let the computer do it.  Still looking for clarification on the OP... I need TiVo DT PLUS and PyTivo to "push" back H.264 mp4's to the TiVo HD but then they will play from there.... right??


----------



## moyekj (Jan 24, 2006)

swezey said:


> I need TiVo DT PLUS and PyTivo to "push" back H.264 mp4's to the TiVo HD but then they will play from there.... right??


 No you DO NOT need Tivo DT Plus. pyTivo is all you need. Streambaby can also do native H.264 pushes as another alternative and allows you to stream H.264 to your Tivo natively as well (as opposed to copying programs back to your Tivo).


----------



## dlfl (Jul 6, 2006)

I do know a possible explanation for different AdDetective results using TVAP:

When TVAP runs the adScan function via the COM interface there is a function argument that selects "fast" or "slow" AdDetective scan mode. This is currently hardwired to slow on the assumption slow is more accurate. But maybe you are using fast mode in your GUI processing and that could lead to different (in your case better) results. Would be interesting to see in your TVSuite GUI if fast mode is what you have been using. (Ad Detective menu, Set Ad Detective Parameters, Black Level Parameters Tab, Enable Fast Search Check Box.) If this is checked, it probably explains the differences.

If you're interested you can very quickly try TVAP with fast search by editing a small modification into the adScan.vbs file located in the install directory of TVAP (usually c:\Program Files\TVAP). (Save the original before editing just in case.)

Right click on adScan.vbs and select edit (or open if edit isn't offered). It will most likely open in NotePad, a simple text editor. Or you can select NotePad from a list of programs.

Find this line:


```
if NOT VideoReDo.StartAdScan(00000, autoscan, 00000 ) = 0 then
```
and change the first argument to 00001, resulting in:


```
if NOT VideoReDo.StartAdScan(00001, autoscan, 00000 ) = 0 then
```
Save the modified version and try a TVAP process chain on a test file and see if you get identical results to the GUI version. I'm very curious to know what happens.

BTW, I echo the comments of moyekj: Neither comskip nor AdDetective will give perfect results on all videos. I also use manual correction of my AdScan cuts. TVAP makes doing this about as easy as possible.


----------



## swezey (Nov 28, 2008)

moyekj said:


> No you DO NOT need Tivo DT Plus. pyTivo is all you need. Streambaby can also do native H.264 pushes as another alternative and allows you to stream H.264 to your Tivo natively as well (as opposed to copying programs back to your Tivo).


Streambaby...???  I still have so much to learn...


----------



## swezey (Nov 28, 2008)

dlfl said:


> I do know a possible explanation for different AdDetective results using TVAP:
> 
> When TVAP runs the adScan function via the COM interface there is a function argument that selects "fast" or "slow" AdDetective scan mode. This is currently hardwired to slow on the assumption slow is more accurate. But maybe you are using fast mode in your GUI processing and that could lead to different (in your case better) results. Would be interesting to see in your TVSuite GUI if fast mode is what you have been using. (Ad Detective menu, Set Ad Detective Parameters, Black Level Parameters Tab, Enable Fast Search Check Box.) If this is checked, it probably explains the differences.
> 
> ...


DLFL,

Interesting... I'll have to check this when I get home and let you know what I find out but.... I DO think I am running in FAST. I never saw a reason to use SLOW as FAST worked just great. I think the stats are it processes 6000 frames a second on my OC'd i7...  So an hour show takes about 18 seconds. Is that fast? Most of the 3 minutes to process a one hour show I mentioned it takes me is just me checking the cut selections (which always seem to be right). Sometimes I trim up the beginning and ending of a show to get it a little tighter... that's it. When I get home I'll check and update the post and let you know what I find....


----------



## dlfl (Jul 6, 2006)

swezey,

My experiments indicate the first argument in the StartAdScan function does *not* control the Ad Detective speed mode (although the documentation says it does). Rather it seems to be determined by how you had it set the last time you ran the TVSuite GUI program.

This is the expected behavior for all the other Ad Detective parameters but since the COM function provides a specific argument to set speed mode I expected it to work.

I've posted a question about this on the VideoReDo forum but, pending any clarification from them, the bottom line seems to be that the Ad Detective parameters used by TVAP will be whatever was last set in the GUI program.

Thus the only way to explain your different results with TVAP seems to be if you changed the Ad Detective parameters between processing the file in the GUI program and with TVAP (?).


----------

