Avidemux Forum

Avidemux => Main version 2.6 => Topic started by: AndrewSmith on November 06, 2022, 10:39:40 AM

Title: Combining separate audio and video files together
Post by: AndrewSmith on November 06, 2022, 10:39:40 AM
Sometimes the only way to download a video is to use an app such as JDownloader and obtain separate audio and video file components of what gets sent through to the player.

What would be really neat is if we could point the Avidemux app to both files and have it mux them both together into the one container format.  That would be a very cool thing to have, and I haven't seen anything else be able to do it. 

(tappity-tap: just did some google-fu before hitting the 'post' button and found a "Video & Audio Muxer" extension that does it within a chrome browser.  Still, I'd rather have it inside the app.)

I'll just leave this with you guys.
Title: Re: Combining separate audio and video files together
Post by: RocketJet on November 06, 2022, 11:30:31 PM
AviDemux can load audio from a separate file.
First load the video file, then:
MENU - Audio - Select Track
Put a tick on the enable box for the first audio track.
Click in the adjacent box and select "Add audio track".
The rest of the process should be self explanatory.
Title: Re: Combining separate audio and video files together
Post by: eumagga0x2a on November 07, 2022, 01:44:58 AM
Quote from: RocketJet on November 06, 2022, 11:30:31 PMAviDemux can load audio from a separate file.
First load the video file, then:
MENU - Audio - Select Track

Not applicable for the task.

@AndrewSmith:

No need for any browser extensions, use yt-dlp with ffmpeg executable in $PATH or specified via the --ffmpeg-location option.

Avidemux supports only raw audio streams (WAV, MP2, MP3, AC3, EAC3, DTS and AAC) while separate audio streams are delivered by online video platforms in containers (MP4 or WebM) or as MPEG-TS.
Title: Re: Combining separate audio and video files together
Post by: AndrewSmith on November 08, 2022, 01:52:41 AM
Quote from: RocketJet on November 06, 2022, 11:30:31 PMNo need for any browser extensions, use yt-dlp with ffmpeg executable in $PATH or specified via the --ffmpeg-location option.

I believe that requires typing rather than GUI point and click?  :-)

Title: Re: Combining separate audio and video files together
Post by: Blues on November 08, 2022, 03:39:17 AM
You need to achieve enlightenment. (http://catb.org/~esr/writings/unix-koans/gui-programmer.html)
Title: Re: Combining separate audio and video files together
Post by: Elstar` on November 11, 2022, 08:15:36 PM
You can also use

ffmpeg -i infile.mp4 -i infile.m4a -codec copy -o outfile.mp4

if you don't want to redownload. You can losslessly convert m4a to aac with it too,

ffmpeg -i infile.m4a -codec copy -o outfile.aac

(download latest ffmpeg from http://ffmpeg.org/download.html - it's pretty stable)


I wonder, is it that hard to implement direct import of aac in mp4 container (m4a) though...