Author Topic: Issue with playing mkv files?  (Read 5330 times)

nosebreaker

  • Guru
  • ****
  • Posts: 202
    • View Profile
Issue with playing mkv files?
« on: March 27, 2009, 03:51:48 pm »
I have a bunch of mkv files that LMCE won't play at all (just dumps back to the main screen).  I know it will play mkv files in general, because I have another movie that it plays, but won't read the subtitles on that one (known bug).  Any ideas?  Could it be a codec or something?

donpaul

  • Guru
  • ****
  • Posts: 300
    • View Profile
Re: Issue with playing mkv files?
« Reply #1 on: March 27, 2009, 04:14:27 pm »
Will it play the files if you change the extension to m2ts?

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: Issue with playing mkv files?
« Reply #2 on: March 27, 2009, 08:34:12 pm »
I have a bunch of mkv files that LMCE won't play at all (just dumps back to the main screen).  I know it will play mkv files in general, because I have another movie that it plays, but won't read the subtitles on that one (known bug).  Any ideas?  Could it be a codec or something?

It could easily be a codec, yes, but you don't mention what codec it uses. If it is a bit exotic, then it might not be included in LMCE... generally I don't have any issues (although there is a known issue with the mkv containers and xinelib that causes a sporadic green veil to appear from the left of the screen)

nosebreaker

  • Guru
  • ****
  • Posts: 202
    • View Profile
Re: Issue with playing mkv files?
« Reply #3 on: March 31, 2009, 03:25:34 am »
It plays fine on other systems, I think they just have the regular divx codecs on them.  VLC says:

Stream 0:
Codec: avc1
Language: Video
Resolution: 1280x720

Stream 1:
Codec: a52
Language: English
Type: Audio
Channels: 2
Sample Rate: 48000 Hz


donpaul

  • Guru
  • ****
  • Posts: 300
    • View Profile
Re: Issue with playing mkv files?
« Reply #4 on: March 31, 2009, 03:40:03 am »
Change the extension to .m2ts, so mplayer is used. mplayer should handle avc1 with ease.

Some good reading:
http://ubuntuforums.org/showthread.php?t=77329&highlight=mplayer

tschak909

  • LinuxMCE God
  • ****
  • Posts: 5549
  • DOES work for LinuxMCE.
    • View Profile
Re: Issue with playing mkv files?
« Reply #5 on: March 31, 2009, 03:54:46 am »
I play avc1 stuff with xine just fine. Please do not use the mplayer player, it was a stop-gap for blu-ray and hd-dvd playback, and suffers from severe deficiencies in integration inherent to a lacking comms interface in mplayer itself.

-Thom

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: Issue with playing mkv files?
« Reply #6 on: March 31, 2009, 06:54:26 am »
If you are able to play other "avc" media files, then the only thing I can think of is perhaps either the file is corrupted (some players may play certain types of corruption, others may not) or perhaps it is a particular profile of H264 that xine doesn't support. H264(AVC) has lots of different profiles, and not necessarily all of them will be supported. I couldn't find anything that implied that xine (ffmpeg) doesn't support them all, but you never know I guess.... http://en.wikipedia.org/wiki/H.264/MPEG-4_AVC

nosebreaker

  • Guru
  • ****
  • Posts: 202
    • View Profile
Re: Issue with playing mkv files?
« Reply #7 on: March 31, 2009, 09:17:35 pm »
If I rename it to m2ts the video seems to work, but no audio.  It stopped playing after a couple minutes and dumped to the main screen though.

donpaul

  • Guru
  • ****
  • Posts: 300
    • View Profile
Re: Issue with playing mkv files?
« Reply #8 on: March 31, 2009, 11:26:49 pm »
I noticed that same behavior with some divx videos I created. You'll probably want to convert the video to a different format. Try AVS Video Converter.

nosebreaker

  • Guru
  • ****
  • Posts: 202
    • View Profile
Re: Issue with playing mkv files?
« Reply #9 on: April 18, 2009, 06:54:06 pm »
Where is the option to change file associations?  I can't find it in the admin screen.  I wish to set .mkv to use VLC or mplayer instead of xine as they seem to work fine with the video.

nosebreaker

  • Guru
  • ****
  • Posts: 202
    • View Profile
Re: Issue with playing mkv files?
« Reply #10 on: April 21, 2009, 10:33:41 pm »
Well I found the file associations in KDE, but this doesn't seem to make any difference.  Can someone please point me to where this is on the admin site?  I went through everything and somehow I missed it.

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: Issue with playing mkv files?
« Reply #11 on: April 22, 2009, 12:50:10 am »
There are no file associations as such ... the system isn't actually using the paradigm of files and media player applications at all. Each piece of media that is active, is abstracted through a "media stream" object. The players are actually DCE "devices" that must integrate with the DCE Router protocols and accept stream objects for play back. So any "association" that exists, such as it is, happens within the Media Plugin when it is creating the stream and sending the MH Play message to a playback DCE device... and this is hardcoded... so you will have to grab the source code, make the modifications you want to change the "association" and recompile it, then replace the Media Plugin with your code.

Better yet, you could pull out the hardcoding into some Device Data entries and provide the association mapping you are looking for, as that could potentially be useful for others.
« Last Edit: April 22, 2009, 12:52:07 am by colinjones »

nosebreaker

  • Guru
  • ****
  • Posts: 202
    • View Profile
Re: Issue with playing mkv files?
« Reply #12 on: April 23, 2009, 09:21:58 pm »
Thanks very much for the reply colin, right now I'm just booting into Vista and using VLC since that works with these mkv files, I'll let you know if I ever get around to changing it but I'll probably just wait until 810 and see if that fixes it.