Chapters inside MP4 file

Archive of historical feature requests.
Please use the GitHub link above to report issues.
Forum rules
*******************************
Please be aware we are now using GitHub for issue tracking and feature requests.
- This section of the forum is now closed to new topics.

*******************************
Vidar
Posts: 4
Joined: Tue Feb 06, 2007 12:08 am

Chapters inside MP4 file

Post by Vidar »

I have been using HandBrake for around a year now, and have found it to be the best solution that I have tried for ripping TV shows to my Mac Mini, to watch on my connected HDTV. Many thanks go out to all of you that have been working very hard on bring the masses an updated version.

There is one feature that I have not seen requested yet, and I'm not sure if it is something that is possible or not. I would love to be able to rip a title from a DVD, and have it preserve the chapter inside of it. I got this idea from working on a freelance movie project. I exported a quicktime file from iMovie, and it preserved all the chapter markers. When playing back in quicktime, I was able to chapter skip.

I would love this feature to be incorporated, because that would enable me to skip over the 25, 35, or even 45 second intros in most TV shows, instantly. If you guys can make this work, that would be fantastic. But like I said, I don't know if this is something that can even be accomplished, so I will be happy with a response saying it can't be done.

Thanks for your time, and keep up the good work.

-Vidar
ItsInTheCave
Posts: 15
Joined: Sun Feb 04, 2007 1:01 am

Post by ItsInTheCave »

Chapter functionality is part of the MPEG-4 format and can be implemented by some programs.

I too would like to see this feature as it would make the resulting files even more similiar to the original DVD.
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Post by jbrjake »

I created a Trac ticket for this last month:
http://mediafork.dynalias.com/trac/ticket/22

I arbitrarily placed it under MediaFork 1.0 because no one's working on it or, to my knowledge, even planning to.

Anyone is, of course, welcome to pick up the Trac ticket and implement it sooner...
Vidar
Posts: 4
Joined: Tue Feb 06, 2007 12:08 am

Post by Vidar »

Thank you guys so much for your fast replies. I apprechiate you creating a ticket for this feature, and look forward to one day having it implemented. I would love to help out on the coding, but I know absolutely nothing in that area. If you need your Mac fixed, I could do that blindfolded, but not coding.

Thanks again, and keep up the good work.

-Vidar
ikeaboy
Posts: 2
Joined: Fri Feb 16, 2007 5:37 am

Ditto

Post by ikeaboy »

I think you guys are right, preserving chapters is a great idea. Especially since movies downloaded from iTunes use chapter markers, and the iPod/apple TV work so well with them.

I wish I could give your trac ticket a thumbs up or something.
JAL
Posts: 1
Joined: Fri Feb 16, 2007 10:57 am

Post by JAL »

Hi everyone

First, MediaFork is really a great application. Love it and use it almost daily!


I would like to have chapters info extraction too.

So far I searched everywhere in the Mac world and wasn't able to find an application that allows the extraction of the chapter info from a DVD's .IFO file (IFO = InFOrmation). Only app I found is an Windows app (ChapterXtractor) which does its job. It extracts the chapter info into different formats, eg the one used by OGM. I use this OGG chapter info then to include the chapters into a MKV file (which leads me to second the request for MKV support... ;-) ). MKV understands OGG or xml chapter information.


So a cool feature for MediaFork would be to automatically include the chapter information into mp4/OGG containers (not sure if AVIs can use them) and to optionally save the information to a text file for use with other apps (MkvMerge). :D


Again, thank you for this great piece of software!
JAL

EDIT: Oh - and yep, I am aware of the fact that this is already a ticket, but from the info text of the ticket it sounds a little bit limited. Therefore the additional infos in my post :D
laser
Posts: 1
Joined: Sat Feb 17, 2007 10:53 pm

Post by laser »

There is an application for Mac able to extract chapters straight from DVDs. It's called Metadata Hootenanny and has the source code available too! Unfortunately for PowePC only.

http://www.applesolutions.com/bantha/MH.html

Source code: http://www.applesolutions.com/bantha/Hootenanny11.zip

Having chapters embedded will be truly great. Cheers.
ikeaboy
Posts: 2
Joined: Fri Feb 16, 2007 5:37 am

Post by ikeaboy »

Thank you laser for pointing out Metadata Hootenanny, its a great app. With it I have been able to create chapter markers by hand, which is awesome. What I would like to do is extract the chapters (just the chapter number and timecode would do) from the DVD, I haven't been able to figure out how I would do that with MH, can you poin me in the right direction? Thanks.

PS. I can get the chapters from osex, but having them in a format that I could use with a applescript would be great.
whimpers
Experienced
Posts: 79
Joined: Mon Feb 19, 2007 1:03 pm

Post by whimpers »

Open Hootenanny, click on the book icon on the bottom right. Click 'read from DVD' and select the VIDEO_TS folder from a DVD (has te be decrypted I believe). Click 'save to text file' and you will have a text file that you can open in QuickTime Pro. Choose Select all and then Copy, open your movie in QuickTime Pro (leave the playhead at the beginning) and choose 'add to movie'. Choose 'Show Movie properties' and click on the text track, click the Other Settings tab. Next to 'chapters' select 'text track'. At that point you should get the chapters in the QuickTime player. Click on the Visual Settings tab and set the text track to layer 2 or higher (the chapter text indications should disappear under the movie). Save as a reference movie if you want to keep all the original assets, or a as a self-contained movie if you want all the tracks (audio, video, chapters...) included.
mbeach01
Posts: 2
Joined: Tue Mar 06, 2007 12:03 am

Post by mbeach01 »

Okay, I have done as you directed and it worked fine.....for a .MOV file. However when I export it to .MP4 The Chapters are not there. The whole idea here is to get chapters in an M4V file for use with iTunes. Any ideas?
rhester
Veteran User
Posts: 2888
Joined: Tue Apr 18, 2006 10:24 pm

Post by rhester »

mbeach01 wrote:Okay, I have done as you directed and it worked fine.....for a .MOV file. However when I export it to .MP4 The Chapters are not there. The whole idea here is to get chapters in an M4V file for use with iTunes. Any ideas?
This is not possible. iTunes/iPod only understand chapters in .mov wrappers, not .mp4.

Rodney
mbeach01
Posts: 2
Joined: Tue Mar 06, 2007 12:03 am

Post by mbeach01 »

Interesting. The movie I downloaded from iTunes in .m4v format has chapters. I can play the .mov files that I have added chapters to in iTunes, but it runs slow when I have the controls activated in full screen mode, but it is doable. Thanks.
rhester
Veteran User
Posts: 2888
Joined: Tue Apr 18, 2006 10:24 pm

Post by rhester »

Actually, if you look more closely, all iTunes movies are in .mov format with a .m4p extension.

Rodney
Thinine
Posts: 4
Joined: Wed Mar 07, 2007 12:30 am

Post by Thinine »

How so? They're all .m4v files for me.
rhester
Veteran User
Posts: 2888
Joined: Tue Apr 18, 2006 10:24 pm

Post by rhester »

How are you examining the container?

Rodney
dynaflash
Veteran User
Posts: 3820
Joined: Thu Nov 02, 2006 8:19 pm

Post by dynaflash »

Thinine wrote:How so? They're all .m4v files for me.
.m4v is just a file extension apple chose to tell OSX to open the file natively in iTunes instead of QuickTime. you can name either a .mp4 file or a .mov file .m4v and that is all it does. At least as far as I am aware. Doesnt change anything about the container itself.
Kurtz
Posts: 37
Joined: Wed Feb 21, 2007 6:52 pm

This may help

Post by Kurtz »

This is from a guide on doom9's forums at:

http://forum.doom9.org/showthread.php?s&threadid=62723

"8) How can i place Chapters in MP4 files?
chapters storage is possible by using advanced content (eg by creating a menu), but Nero uses a MP4 feature called "user space" (udta atom) which allows you to attach anything you want in MP4 (iTunes uses the udta atom for storing tags and cd/dvd-covers ("coverart") in MP4 for example).
atm you can place chapters in MP4 automatically during encoding with Nero Recode2 or, on existing files, with MP4Box and the MP4 directshow muxer filter coming with Recode2 (usable in graphedit)
As players, not knowing the info stored in udta, will simply ignore it, you need a player/filter that can handle this special chapters info (eg Gabest, Haali, Nero or 3ivx)"

Im currently playing with Mp4box with the YAMB front end on Windows which can add chapters to mp4/m4v. Ill report back if i have any luck. However OSX options (my main computer platform) seem few and far between. Looks like Apple has its own program for this sort of feature.

Also the Itunes store uses M4v files which are not MOVs. MP4 and M4v are practically the same container standard, that come from some of the standards in MOV. It is correct that M4v is the container that apple has chosen to tell itunes what to open when it comes to Video. However they are different in what they can do compared to MOVs.

EDIT:
Just found an OSX DVD Chapter extracter
Go to:
http://www.randomravings.com/freeware/
Hope this helps
starkos
Posts: 5
Joined: Sun Mar 11, 2007 1:35 pm

Willing to help on this

Post by starkos »

I just got an ipod and discovered HB - kudos to all involved, well done!

iPod compatible chapter markers are a killer feature for me, and I'm willing to help out with implementation. I've downloaded and built the HB code (which was easy, again nice job). But after much Googling I haven't had any luck figuring out how to get chapter markers into a video. It seems it must be possible, since the movies from Apple have chapters.

I've read through this topic and tried the ideas mentioned here, but I haven't had any luck. If anyone has any info they can throw my way, I'll try to make good use of it.

Thanks, and again great work everyone.
Kurtz
Posts: 37
Joined: Wed Feb 21, 2007 6:52 pm

How apple makes M4v's with chapters

Post by Kurtz »

Hi

After doing some intence google hunting and reading, I think ive found how apple adds chapters to its iTunes movies

Compressor 2 has the ability to pass through chapter makers.
Here is the statement in the Late breaking news manual:

Chapter Markers for iPod and QuickTime Output
In previous versions of Compressor, you could add and name chapter markers that
DVD Studio Pro would recognize in MPEG-1, MPEG-2, and H.264 for DVD Studio Pro
output files. Compressor 2.3 expands this feature for iPod video authoring and other
QuickTime authoring. Chapter markers are now passed through (transferred) to other
output files that can be recognized by QuickTime Player, iTunes (.m4v files),

Link to PDF
http://manuals.info.apple.com/en/Compre ... _lbn_z.pdf

This wont help us very much but at least we know.
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Post by jbrjake »

You're wasting your time.

You want to be looking at how the program mp4creator from the MPEG4IP project adds chapter markers, because HB uses its mp4 library, not QuickTime...

Anotherwords, you need to start learning your way around libmp4v2.

mp4creator source code:
http://mpeg4ip.cvs.sourceforge.net/mpeg ... p4creator/

libmp4v2 source code:
http://mpeg4ip.cvs.sourceforge.net/mpeg ... lib/mp4v2/
rhester
Veteran User
Posts: 2888
Joined: Tue Apr 18, 2006 10:24 pm

Post by rhester »

It doesn't matter. The only chapter format iPod/Apple TV/QuickTime supports is Apple-proprietary. Industry-standard tools can create chapters, but not the same sort Apple uses.

Rodney
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Post by jbrjake »

rhester wrote:It doesn't matter. The only chapter format iPod/Apple TV/QuickTime supports is Apple-proprietary. Industry-standard tools can create chapters, but not the same sort Apple uses.
Blah. Seriously? That is sooooo lame.

So...what does that mean? Using Atomic Parsley code? Can we even do that easily? This is looking like way more trouble than it's worth.
rhester
Veteran User
Posts: 2888
Joined: Tue Apr 18, 2006 10:24 pm

Post by rhester »

As far as I know, the only tools capable of creating Apple-friendly chapters are Apple tools (QT Pro and whatever their high-end video tool is), inside QuickTime containers only.

Rodney
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Post by jbrjake »

rhester wrote:As far as I know, the only tools capable of creating Apple-friendly chapters are Apple tools (QT Pro and whatever their high-end video tool is), inside QuickTime containers only.
=(

This whole time I'd been under the impression that tools like Metadata Hootenanny and AtomicParsley could make QT-friendly chapters....but I guess AtomicParsley can't do chapters, and Metadata Hootenanny can't do .mp4.

Some of the gruesome details of why Lostify doesn't do chapters is recounted here:
http://forums.3ivx.com/lofiversion/inde ... 82954.html

Well now...this request is definitely going on the back burner, eh?
Vidar
Posts: 4
Joined: Tue Feb 06, 2007 12:08 am

Post by Vidar »

Well, it looks like many of you put a lot of thought and time into my suggestion. I really aprechiate that. I was hoping that this would be a simple addition, but it appears to be totally the opposite. Thanks for taking the time to look into adding this feature. Hopefully someday it will be something that can be implemented.

Thanks for all the hard work you guys are putting into this software. I am a huge fan (and kinda bummed that I can fix anything hardware related to a Mac, but don't know a line of code).
Post Reply