VideoHelp Forum




Results 1 to 6 of 6
  1. I simply want to add a VBR MP3 audio track to an existing XVID. I tried the method here:

    http://www.ffmpegx.com/avi2audio.html

    However, it down-sampled the MP3 from basically V0 (200+ kbps ABR) to 128 CBR. I don't want that.

    I tried also adding the track with QuickTime Pro 7, and that's fine, but it winds up as a .mov file which I don't want either.

    I want an XVID with 2 tracks and no transcoding at all.

    Actually ideally I would like to switch the two sound tracks, make the one I'm adding the default and make the other one the alternate.

  2. ffmpegX would have been my suggestion, but since it down-sampled I guess that's out.

    avidemux, while not a native OSX app, will do what your looking for.
    Last edited by Meritocracy; 11th Jun 2010 at 17:14.
    What exactly is rotten in Denmark?

  3. thanks, i'll check out avidemux.

    edit: i tried and can't get it to save the secondary audio track. the original had 2 tracks and i can get rid of one. so i chose one of them for main track. Then selected external MP3 as Secondary track. Video & Audio set to Copy. I tried saving the result both as "AVI" and "AVI, dual audio". In first case I ended up with only (the selected one of) the original tracks. No secondary track from external. In the second case I wound up with a secondary track, but it was a silent 128 CBR MP3.
    Last edited by redrocklobster; 11th Jun 2010 at 23:30.

  4. Explorer Case's Avatar
    Join Date
    Feb 2004
    Location
    Middle Earth
    Search Comp PM
    Split you source AVI into separate video and audio. You could use D-Vision for this.
    You should then have original-video.avi and original-audio.mp3.

    Next, mux these with the additional audio, in the order you want.
    By using ffmpeg from the command line (Terminal), you may use all it can do, without the limitations of a GUI.
    Code:
    ffmpeg -i original-video.avi -vcodec copy -i additionalaudio.mp3 -acodec copy -i original-audio.mp3 -acodec copy -f avi output.avi -newaudio
    Replace the files in the command line with the full path, including the app, like:
    Code:
    /Applications/ffmpegX.app/Contents/Resources/ffmpeg -i /Users/username/Desktop/original-video.avi -vcodec copy -i /Users/username/Desktop/additionalaudio.mp3 -acodec copy -i /Users/username/Desktop/original-audio.mp3 -acodec copy -f avi /Users/username/Desktop/output.avi -newaudio
    Last edited by Case; 12th Jun 2010 at 09:37.

  5. Originally Posted by Case View Post
    Split you source AVI into separate video and audio. You could use D-Vision for this.
    You should then have original-video.avi and original-audio.mp3.
    Case, thanks a lot. that seemed very promising. But it didn't exactly work either. I managed to extract the .avi video file and the track #1 audio file from the original with d-vision 3. But the audio track #2 wouldn't extract. It said disabled. and when i set the settings for direct stream the dialog window would not dismiss. some kind of bug. in quicktime pro 7, that track in fact is "disabled" in the original.

    but never mind, even though i wanted the original track #2 (224 kbps AC3), I tried the terminal command with track #1 (192 kbps AC3).

    But this also re-encoded the new track #1 replacement ["additionalaudio.mp3", or here, "the Golem Live Joined (with 5 seconds intro silence)"] at 128 kbps! (note that the duration for that track is way off, even though it is actually right, 83 min @ LAME V0 VBR)

    Code:
    Input #0, avi, from '/Volumes/Video/The Golem- How he Came into the World (1920)/working/Paul.Wegener.1920.Der.Golem.wie.er.in.die.Welt.kam.DVDRip.XViD-KG(video track).avi':
      Duration: 01:24:52.8, start: 0.000000, bitrate: 2500 kb/s
      Stream #0.0, 20.00 fps(r): Video: mpeg4, yuv420p, 640x480
    Input #1, mp3, from '/Volumes/Video/The Golem- How he Came into the World (1920)/working/Black Francis - The Golem Live Joined (with 5 seconds intro silence).mp3':
      Duration: 02:32:27.0, start: 0.000000, bitrate: 127 kb/s
      Stream #1.0: Audio: mp3, 44100 Hz, stereo, 128 kb/s
    Input #2, ac3, from '/Volumes/Video/The Golem- How he Came into the World (1920)/working/Paul.Wegener.1920.Der.Golem.wie.er.in.die.Welt.kam.DVDRip.XViD-KG (audio-192).ac3':
      Duration: 01:24:52.8, start: 0.000000, bitrate: 192 kb/s
      Stream #2.0: Audio: ac3, 48000 Hz, stereo, 192 kb/s
    Output #0, avi, to '/Volumes/Video/The Golem- How he Came into the World (1920)/workingoutput.avi':
      Stream #0.0, 20.00 fps(c): Video: mpeg4, yuv420p, 640x480, q=2-31
      Stream #0.1: Audio: mp3, 44100 Hz, stereo, 128 kb/s
      Stream #0.2: Audio: mp2, 48000 Hz, stereo, 64 kb/s
    Stream mapping:
      Stream #0.0 -> #0.0
      Stream #1.0 -> #0.1
      Stream #2.0 -> #0.2
    Press [q] to stop encoding
    error, non monotone timestamps 57600 >= 57600 bitrate=2275.1kbits/s    
    error, non monotone timestamps 172799 >= 172799itrate=2721.1kbits/s    
    frame=130088 q=58315.9 Lsize= 2253054kB time=5028.0 bitrate=3670.8kbits/s    
    video:2056621kB audio:182709kB global headers:0kB muxing overhead 0.612859%
    PS: I also tried the "add audio track" function of D-Vision 3, and that produced a totally screwed up avi with a broken index and very bizarre sound tracks. The only thing that has come close to working so far is QuickTime Pro, but again I end with a .mov file. For now I can live with that, but I can't believe it's so hard to just assemble some audio/video tracks without re-encoding...
    Last edited by redrocklobster; 12th Jun 2010 at 10:10.

  6. Explorer Case's Avatar
    Join Date
    Feb 2004
    Location
    Middle Earth
    Search Comp PM
    1/ I also got weird result when muxing ac3 audio and mp3 audio. Maybe all the audio in an AVI file should have the same format? AVI is not as flexible as MOV or MKV.

    2/ QuickTime only enables one audio track by default. All other audio tracks are disabled. Note that this enable/disable state refers to playback of the track, so that you only hear one audio track at a time.

    3/ You could try using ffmpegX for extracting the second audio track, by using the "Movie File to MP3" or "Movie File to AC3" preset (depending on the format of that track) and setting the audio codec to passthrough, as well as changing the track number to "1" (as "0" is the first audio track). (Untested by me, though.)
    Last edited by Case; 12th Jun 2010 at 10:43.




Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!