I have some .avi files that have multiple audio tracks and the default audio track is in a foreign language. I'm not seeking to remove the other track, but merely change some default flag within it so that, when I open it, it plays track 2, or whatever.

I dont want to create any new files, I shouldn't have to do anything like that, and with .mkvs this was really simple.

So I'm wondering if it is also possible to [reasonably simply] modify the contents of an .avi


I used AVIdemux. It does it in seconds so it's not fully 'demuxing', only changing the preferred audio track (or simply deleting the one you don't want) and making the internal parts of the AVI container file mesh properly. It's a free program - http://sourceforge.net/projects/avidemux/?source=dlp

note: The program obviously has demuxing capabilities.

| improve this answer | |
  • I can't, for the life of me, remember what I'd done with that file. If there's a free downloadable .avi on the webs with multiple tracks send me a link to test it on (I tried searching for one) – Hashbrown Sep 21 '13 at 13:23
  • Alternative link: fixounet.free.fr/avidemux/download.html. Sourceforge one offers to download version 2.6 instead of latest 2.7 for some reason at the moment. – Ilya Kurnosov Mar 5 '18 at 19:17

I do not know how to change the header to designate a different default audio stream in the file. I have always used Virtual Dub to Remove the second stream and pick a specific stream for output. Or to load a seperate audio file in after processing in an audio program.

Virtual Dub mod though, was able to work with multiple audio streams more effectivly http://www.videohelp.com/tools/VirtualdubMOD With virtual Dub mod you can see and change the audio streams in the audio section.

In both programs there is no requirement to re-encode either the audio or the video. If you select Direct Stream it is just a matter of passing the whole video through and re-writing it. Takes a lot more time than changing a header, but it is quick enough.

This info is for windows systems, you did not list what system this is to be done on?

| improve this answer | |
  • I know there are heaps of ways to write a new file to the same effect (with or without re-encoding), I was just wondering whether .avis had a program that could edit their headers (I know this is simpler with .mkvs though because the specification is open). As for the system, I'll leave that open so as not to limit options. Thanks for your response! – Hashbrown Aug 4 '13 at 9:19
  • upvoted because of useful program reference – Hashbrown Aug 4 '13 at 9:27

Why can't you create new files? Just use ffmpeg

In command prompt:

ffmpeg -i input.avi -map 0:v:0 -map 0:a:1 -map 0:a:0 -c copy outputxxxxx.avi

ren *xxxxx.avi *.avi

I recommend Rapid Environment Editor in administrator mode to add the environment variable because the standard way simply does not work on Windows 7

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.