Apple
July 31, 2012
As I’ve mentioned a couple of times before, one of my projects right now is ripping all the DVDs I own so that I can watch them on my AppleTV (or any AppleTV in the house).
Well, one of the problems I’ve run into a couple of times is longer movies that are distributed on two discs. This is usually movies like the Lord of the Rings Extended Edition or The Ten Commandments. Really, they’re one movie, but are distributed as two separate movies because of the restrictions of physical media.
Well, digital media imposes no such restrictions on us, so why have two separate movies listed on the AppleTV? So after much trial and error, I finally discovered a way to get everything play nicely together. Unfortunately, this is not an easy problem to solve and even involved me writing a small script that could merge chapter files together because every single method I could find would eliminate chapter markers.
So here, in abbreviated form, is the process for merging m4v files together and preserving chapter markers.
Note: This tutorial assumes some level of technical proficiency. This is not a point-and-click process (yet :P) and requires the use of multiple tools and the shell.
Tools you’ll need:
Handbrake or whatever tool you’re using for ripping your legally obtained DVDs.
MetaX and/or iDentify
Subler
remux
Quicktime, which is now built into Mac OS X.
chaptermerge, a script I wrote that merges chapter files together.
The proces:
Rip both movies from their individual DVDs using Handbrake or whatever other tool you’re using. Be sure that you’re adding chapter markers.
Load each movie into MetaX and download the chapter names. That’s really the only thing you need to add to the file. Save the files with chapter names.
Load each movie into Subler and extract the chapter files. To do this, select the chapter track and select File -> Export.
Now, open the first movie in Quicktime.
Drag the second movie on top of the first one. Quicktime will add the two together.
Save the movie for use on an AppleTV. Get a beer or 6, because this takes awhile.
While the movie is saving, use chaptermerge to merge the chapter files together. See the docs on how it works.
Once the file has finished saving as a Quicktime MOV (it’s actually still h.264 inside the file), fire up remux and convert the merged file back into an m4v. Drag the file into remux, set the output to m4v, and save. Should be pretty quick - a matter of minutes.
Load the merged file back into Subler and add the merged chapter track. Drag the chapter file into the Subler window. Save the file.
Load the merged file into a tool such as iDentify or MetaX and add the remaining metadata.
That’s it! You now have a merged file with both parts of the movie, accurate chapter markers and full metadata, ready to be copied to iTunes and viewed on your AppleTV.
Read More