PDA

View Full Version : Extract WMA audio from MKV


You Know
22nd November 2006, 13:05
I had muxer with GraphEdit ("Matroska Muxer filter") a wmv and a 2 wma file into an mkv.

There is no way to extract wma file correctly.

AVI MUX GUI 1.17.7 crash during operation
MKVextract GUI doesn't work no file producted
command line mkvextract tracks infile --fullraw 2:audio1.wma produce an inusable file

I have try to remux mkv through mkvmerge (mkvtoolnix)
mkvmerge v1.8.0 ('Wise Up') built on Nov 19 2006 17:15:08
'G:\Mux\013.mkv': Using the Matroska demultiplexer.
'G:\Mux\013.mkv' track 1: Using the video output module.
'G:\Mux\013.mkv' track 2: Using the passthrough output module for this audio track.
'G:\Mux\013.mkv' track 3: Using the passthrough output module for this audio track.
The file 'e:\013.mkv' has been opened for writing.
The cue entries (the index) are being written...
Muxing took 12 seconds.

With above method of extraction, same result.

When mkextract o mkmerge will support wma file???


WMV track is easy to extract, all above method work, but audio WMA track not WHY?

foxyshadis
22nd November 2006, 14:14
You can try using directshow instead, through graphedit. I guess mkvextract doesn't have an asf muxer, but DS sure does.

You Know
22nd November 2006, 14:34
I have already try using graphedit to extract wma track but all combination filter can't be connected output pin to file writer filter, only video can.

witch directshow filter combination should I use to extract wma file??

the main question is why mkv merge and mkv extract doesn't support wma track?

foxyshadis
22nd November 2006, 19:04
Technically, it can, but nothing will read it because it doesn't mux the raw wma into an asf stream, which is different than just extracting the raw stream.

You should be able to use this filter to do so:
http://www.solveigmm.com/files/SMMASF_2005_06_01.zip

Haali
22nd November 2006, 19:59
the main question is why mkv merge and mkv extract doesn't support wma track?
Some parts of asf/wmv are patented by microsoft, and it requested to remove asf support from VDub earlier. So mkvmerge/mkvextract don't have any wmv/asf support to avoid legal problems.

XmSurfer
23rd November 2006, 12:08
1. Convert the MKV file to an asf file using VLC.
2. Extract the audio part of the stream using AsfBin.

Note: I couldn't play the asf file created by step 1 using a directshow player. However, I could play the audio only asf file created by step 2. Tell me how it works for you.

You Know
23rd November 2006, 12:15
@foxyshadis
that filter is a multiplexer not a de-multiplex (splitter)

possible solution without rencode??
extract track with virtualDubMod using Save Wave and Direct stream copy setting
result is the wma file encapsulate in a wav container.

VDM Demux mode produce an usable file, i thing that wma container is lost by Matroska Muxer filter.

How can convert this wav container into wma container?

You Know
23rd November 2006, 12:20
xmsurfer may be good trick, explain me how save with VLC (Video Lan Player?)

You Know
23rd November 2006, 12:39
cut............

XmSurfer
23rd November 2006, 13:04
xmsurfer may be good trick, explain me how save with VLC (Video Lan Player?)

Open VLC media player. Then....

1. File --> Open File
2. Click "Browse"
3. Select Your File
4. Under "Advanced options" Select "Stream/Save" Option (Note: You can choose to enable "Caching" if you desire.)
5. Click Settings
6. Under "Outputs" Select "File" Option
7. Type in your output location in the "Filename" box (example: F:\test.wmv) or by using the "Browse" button next to the "Filename" box
8. Select ASF under "Encapsulation Method"
9. Click "OK"
10. Click "OK" again
11. Magic Happens

foxyshadis
23rd November 2006, 20:55
You Know, of course it's a muxer, the demuxer is your MKV splitter. Haali's and gabest's both work. Just for grins, a used graphedit to remux a wmv into a mkv, and then used solveig's testmux app to remux it back into an asf. It plays perfectly, and you can disable the video portion easily. (You can do it all in graphedit as well, but textmuxer is simpler.)

Oh, and apparently they have an update for audio-only remuxing: http://solveigmm.com/?Downloads

Still, if vlc works, that's another good method.

You Know
16th December 2006, 16:02
@XMSurfer
VLC produces a 0 byte file because VLC can't play any of these MKV file

@foxyshadis
solveig's when start process show "Fails to start DirectShow filter graph"

remux MKV file producted by graphedit with mkvtoolnix->mkvmergeGUI.

now VLC produce a file not proper muxer because Windows Media Stream Editor show only video track in the audience, no audio (WMA track)

solveig's testmux same error

Yong
16th December 2006, 18:17
Try mencoder/ffmpeg, :)

First direct stream copy with mencoder(must have video stream else mencoder will complain),
mencoder.exe urfile.mkv -oac copy -ovc copy -o urfile.avi
use "-aid x" to select audio track.

Second, use ffmpeg direct stream copy again:rolleyes:
ffmpeg.exe -i urfile.avi -acodec copy -vn urfile.wma

Done:cool: .(hopefully)