1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Extracting .avi (h264) from matroska .mkv

Discussion in 'Video - Software discussion' started by xenoni, Apr 22, 2006.

  1. xenoni

    xenoni Member

    Joined:
    Jun 27, 2003
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    11
    I have a matroska video file that contains a video track that is encoded with x264 and an audio track in AAC. So, I'd like to extract the h264-encoded video track only.

    Now I've tried to use VirtualDubMod (latest version, latest build), but it keeps giving me errors after the mkv parsing is done resulting in having only the audio track available in the stream list. So I figured that this doesn't work and tried mkvextract to extract the video from the matroska file. The resulting video file is corrupted(?) somehow, since it can't be played in any player (meaning BSplayer and VideoLAN).

    I also used AviSynth to get the .mkv file to open in VirtualDub. It worked fine, but I can't really extract the video that way, I'd have to encode it to make it work (since Direct Stream Copy seems to give me uncompressed video for which I don't have enough disc space (the video length is around 50min, so...)

    I know I should've asked this first on the matroska forums but for some reason it takes 5 days until I can post there and I'm kinda in a hurry. If there would be somekind of program I haven't used or little something to tweak on the AviSynth file, please let me know. I know you're smart so this shouldn't be a big problem for YOU :D
     
  2. celtic_d

    celtic_d Regular member

    Joined:
    Jan 23, 2005
    Messages:
    3,352
    Likes Received:
    0
    Trophy Points:
    46
    AVISynth serves raw video. So if you direct stream it, that is what you get. Chances are that your mkv contains native AVC. This can't be demuxed to an avi, what you get is a raw .264 AVC stream. Still I would have thought that VLC would be able to play it. I'm pretty sure that mplayer can.

    Why do you want it as an avi anyway?
     
  3. xenoni

    xenoni Member

    Joined:
    Jun 27, 2003
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    11
    Yea, I want to get the h264-stream demuxed into an avi file without recompressing it (if it's even possible).
     
  4. celtic_d

    celtic_d Regular member

    Joined:
    Jan 23, 2005
    Messages:
    3,352
    Likes Received:
    0
    Trophy Points:
    46
    It is possible, but why would you want to? The only advantage of avi is that windows comes with an avi splitter. Sounds like you already have a mkv splitter installed though, so that basically kills avi's only advantage.
     
  5. xenoni

    xenoni Member

    Joined:
    Jun 27, 2003
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    11
    I just want to know how to do this, I don't really have any use for it YET. But you never know... It just bugs me knowing that I don't know how to do this, so if you know how to do the demuxing properly please tell me, I'd be grateful :)
     
  6. Thotto

    Thotto Member

    Joined:
    Nov 12, 2005
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    11
    It is useful to demux a matroska file in DivX/XVid-AVI so that salon players can reproduce it.
     

Share This Page