Log in

View Full Version : Replace a track with mp4box


beto
12th March 2014, 19:46
I have a m4v file that comprises 5 tracks.

TrackID 1: H.264 video
TrackID 2: aac audio
TrackID 3: ac3 audio
TrackID 4: srt subtitle
TrackID 5: chapters

I want to replace track number 4 with a new srt subtitle track. For that i use mp4box and the -rem switch to remove trackID 4. That works ok and the track is removed successfully.

I then use the -add switch to add the new srt subtitle track to the file and it also works ok, however the new subtitle track has trackID 6 and I end up with the following track distribution in my file:

TrackID 1: H.264 video
TrackID 2: aac audio
TrackID 3: ac3 audio
TrackID 5: chapters
TrackID 6: srt subtitle

Question is if is there any way to force mp4box, when adding this new subtitle track, to use trackID 4 for it instead of trackID 6? If not is there any problem playbackwise in AppleTV keeping the file the way it is (skipping trackID 4)?

Thanks in advance.

Guest
12th March 2014, 19:51
The extension 'm4v' indicates an elementary video stream. Where did you get this file?

beto
12th March 2014, 20:16
The extension 'm4v' indicates an elementary video stream. Where did you get this file?

I made it myself. It was created with mp4box using meGUI and the AppleTV option using the MP4 muxer, but I do not understand how this is related to my original question.

Guest
12th March 2014, 21:55
In PM, you explained that you made this from a DVD.

Why can't you simply demux and remux the streams as needed? Or repeat the process with the correct SRT file?

beto
12th March 2014, 22:15
Thank you for reopening this thread and sorry again for the confusion. I'll be more careful from now on.

To answer your question it is easier to just remove one track and add the new one when you have to do this on several files through a batch file.

That was not clear in my original post and for that I apologize.

Demuxing everything and remuxing works but takes much more time and effort since I have to do this on several files I created from my DVDs and am using a batch approach.

Hope this clarifies a little bit more.

Guest
12th March 2014, 22:41
Maybe some MP4 expert can help you.

If it was me, I would fix my process so that the original files are made with the correct SRTs?

beto
12th March 2014, 23:45
Maybe some MP4 expert can help you.

I hope so!

If it was me, I would fix my process so that the original files are made with the correct SRTs

That is the best approach and I am doing this now, however I have a bunch of legacy files that I intend to fix now. :)

Kurtnoise
13th March 2014, 20:39
Question is if is there any way to force mp4box, when adding this new subtitle track, to use trackID 4 for it instead of trackID 6?
Not possible...

If not is there any problem playbackwise in AppleTV keeping the file the way it is (skipping trackID 4)?

if you use the m4v extension during the remux, I don't think so...

beto
14th March 2014, 02:59
Thank you Kurtnoise. Regards.