Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

No sound while playing MKV with HTML5

I'm trying to play a .MKV file with HTML5. Video works fine but there is no sound, I can't unmute the video.

<video src="video.mkv" type='video/x-matroska' codecs='theora, vorbis'></video>

I'm using Chrome 24.

like image 295
user2092799 Avatar asked Feb 20 '13 19:02

user2092799


1 Answers

It's because of the audio codec that was used. Chrome probably doesn't support it. No, I don't know how to fix it other than to find out what audio codec it's using and either change it or get a browser extension that will support it. I will engage you to convert the video into different format like MP4/OGG.

<video width="500px" controls>
  <source src="yourvideo.mp4" type="video/mp4">
  <source src="yourvideo.ogg" type="video/ogg">
  Your browser does not support HTML video.
</video>

Your can VLC web plugin. It takes some few steps to configure and get it to work.

Read more about https://wiki.videolan.org/Documentation:WebPlugin#Input_object

<embed id="divxplayer" type="video/divx" width="1024" height="768" 
src ="path_to_file" autoPlay=\"true\" 
pluginspage=\"http://go.divx.com/plugin/download/\"></embed>

Other question related to this : How to playback MKV video in web browser

like image 167
Dhanuka Perera Avatar answered Oct 11 '22 14:10

Dhanuka Perera