converting a mkv to avi (or m4v) under ubuntu
Here's the problem I'm trying to solve. I have a .mkv video file that plays fine under vlc. I want to be able to watch it on my big screen tv via my xbox360 using ushare.
ushare works no problem for .m4v and .avi files. But .mkv is an unsupported container.
So I need to convert the .mkv file to a mpeg4 video file (.m4v) or a avi.
When I try ffmpeg it fails. The problem is ffmpeg can't figure out the audio track which is. The audio track is a52/ac3 and the video format is h263/avc1.
# mkvinfo foo.mkv |grep "Codec ID"
| + Codec ID: A_AC3
| + Codec ID: V_MPEG4/ISO/AVC
However back on my ubuntu box ffmpeg can't figure out what the audio track is for the .mkv file. It just says:
, matroska, from 'foo.mkv':
Duration: 00:20:45.1, bitrate: N/A
.0: Audio: 0x0000, 48000 Hz, stereo
.1: Video: h264, yuv420p, 640x480, 29.97 fps(r)
So ffmpeg can't convert it because it can't figure out the a52/ac3 audio format.
So I switch over to mencoder and try that and it just core dumps:
$ mencoder foo.mkv -oac mp3lame -aid 128 -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=1000 -bps -ofps 23.976 -o foo2.avi
MEncoder 2:1.0~rc1-0ubuntu13.2 (C) 2000-2006 MPlayer Team
CPU: Intel(R) Pentium(R) 4 CPU 2.66GHz (Family: 15, Model: 2, Stepping: 9)
CPUflags: Type: 15 MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.
success: format: 0 data: 0x0 - 0xb067be8
[mkv] Track ID 1: audio (A_AC3), -aid 0, -alang und
[mkv] Track ID 2: video (V_MPEG4/ISO/AVC), -vid 0
[mkv] Will play video track 2
Segmentation fault (core dumped)
... any help?Update
: Problem solved. Seehttp://jackal.livejournal.com/1811752.html