December 22, 2024
How to Mux and Demux Video Using MP4Box for Mac

How to Mux and Demux Video Using MP4Box for Mac

Posted August 25, 2010 at 12:36am by iClarified
Portuguese (Brazil)
These are instructions on how to mux and demux mp4 video using MP4Box for Mac. You may want to do this if you wish to replace the audio track of a video or movie without re-encoding.

Step One
Download MP4Box from here to your Desktop. It will be called "Pre-Compiled MP4Box (Mar 30, 2010)" and is in the downloads list on the right. Thanks to Penguin Software for compiling this.

Step Two
Double click the downloaded zip (MP4Box.zip) file to extract it.
How to Mux and Demux Video Using MP4Box for Mac


Step Three
Open a new Terminal window from the Applications:Utilities folder
How to Mux and Demux Video Using MP4Box for Mac

Step Four
Type cd ~/Desktop to navigate to your Desktop folder
How to Mux and Demux Video Using MP4Box for Mac

Step Five
Make sure the video file you would like to demux is on your desktop then execute the following terminal command to extract track1 (ie the video track).

./MP4Box -single 1 'Original Video.mp4'
How to Mux and Demux Video Using MP4Box for Mac
Note:* Replace the words "Original Video" with the name of your video file.

This will create a new video only file with "_track1" added to the end of its name.
How to Mux and Demux Video Using MP4Box for Mac

Step Six
Make sure the audio file you would like to mux with your video is on the desktop then execute the following terminal command to combine the tracks.

./MP4Box -add 'Original Video_track1.mp4' -add 'New Audio.mp3' 'New Video.mp4'
How to Mux and Demux Video Using MP4Box for Mac
Note* Replace the words "Original Video with the name of your video file. Replace the words "New Audio" with the name of your replacement audio file. Replace the words "New Video" with the desired output name for your newly muxed video.

This will create the new video file with the replaced audio track.
How to Mux and Demux Video Using MP4Box for Mac

Step Seven
MP4Box has many powerful capabilities. Execute ./MP4Box in the terminal window to get help on the program's many options.
How to Mux and Demux Video Using MP4Box for Mac
Add Comment
Would you like to be notified when someone replies or adds a new comment?
Yes (All Threads)
Yes (This Thread Only)
No
iClarified Icon
Notifications
Would you like to be notified when we post a new Apple news article or tutorial?
Yes
No
Comments (3)
You must login or register to add a comment...
JPT
JPT - October 11, 2013 at 3:23pm
doesn't work: "Wrong track ID 1 for file (null), Error: Bad Parameter" Which version did you use? I've got GPAC version 0.5.0-rev4065 How do you find out track ids?
adamlogan
adamlogan - April 21, 2012 at 4:59am
Thanks dude, this is exactly what I wanted. Bing bang done.
muxing
muxing - August 25, 2010 at 3:58am
yfugiu
Recent. Read the latest Apple News.
RECENT
Tutorials. Help is here.
TUTORIALS
Where to Download macOS Sequoia
Where to Download macOS Ventura
AppleTV Firmware Download Locations
Where To Download iPad Firmware Files From
Where To Download iPhone Firmware Files From
Deals. Save on Apple devices and accessories.
DEALS