Appletax
Well-Known Member
- Reaction score
- 396
- Location
- Northern Michigan
If you have MKV videos and only the video plays and not the audio, you can:
1. On PC/Mac, use VLC Media Player as it supports many video & audio codecs.
2. Stream the video from your PC to your device using Plex Media Server.
3. Convert the audio to a different codec (see below).
Typical issue: the MKV's audio is DTS (usually, but not always). The device (e.g. Roku) does not decode DTS - it does "passthrough" - it passes the audio to your TV, which (if you have the equipment), will send the audio stream to your surround sound system or soundbar.
No DTS speaker, no audio.
One solution: use a video converter program, such as Handbrake.
Problem: the program will re-encode the video and the audio (you just need to re-encode the audio), which results in a very time consuming and inefficient procedure. Re-encoding video requires serious CPU power.
Best solution: use FFmpeg, a free, complete, cross-platform solution to record, convert and stream audio and video.
Reason: simple, super fast, very powerful/customizable. It will copy the video (no re-encoding) and re-encode the audio only.
** How to Use FFmpeg to Convert MKV Audio for Compatibility **
1) Download FFmpeg [choose: release build (bottom option) + your architecture + static]
2) Inside the zip file you'll find a folder called 'bin' and a file in there called 'ffmpeg.exe'. Copy that file somewhere in your path where your videos are.
3) Open the command prompt (cmd) and work your way to the directory containing the videos.
E.g.: cd \Users\<your username>\Videos
4) Use the command: ffmpeg -i input.mkv -c:v copy -c:a aac -ac 2 -b:a 256K output.mp4
Example:
ffmpeg -i "National Treasure.mkv" -c:v copy -c:a aac -ac 2 -b:a 256K "National Treasure.mp4"
How the command works:
- ffmpeg - use the program
- i - input something
- input.mkv - input file (your video)
- c:v copy - [codec:video] copy - copies the video stream (no quality change) and does not re-encode it - makes this process very fast
- c:a aac - [codec:audio] - switches to the audio stream and re-encodes in the AAC codec, which Roku can decode
- ac 2 - set # of audio channels to 2 (stereo)
- b:a 256K- sets audio bitrate to 256
- output.mp4 - your output video name; switches container type to MP4
Misc:
> You can see video information by using ffmpeg -i movie.mkv. It shows you the audio codec used. MKV container + AAC audio will work fine.
> Roku audio and video support.
> This command uses a small amount of CPU processing time and a lot of disk time. Only way to speed this process up is to do this on an SSD.
1. On PC/Mac, use VLC Media Player as it supports many video & audio codecs.
2. Stream the video from your PC to your device using Plex Media Server.
3. Convert the audio to a different codec (see below).
Typical issue: the MKV's audio is DTS (usually, but not always). The device (e.g. Roku) does not decode DTS - it does "passthrough" - it passes the audio to your TV, which (if you have the equipment), will send the audio stream to your surround sound system or soundbar.
No DTS speaker, no audio.
One solution: use a video converter program, such as Handbrake.
Problem: the program will re-encode the video and the audio (you just need to re-encode the audio), which results in a very time consuming and inefficient procedure. Re-encoding video requires serious CPU power.
Best solution: use FFmpeg, a free, complete, cross-platform solution to record, convert and stream audio and video.
Reason: simple, super fast, very powerful/customizable. It will copy the video (no re-encoding) and re-encode the audio only.
** How to Use FFmpeg to Convert MKV Audio for Compatibility **
1) Download FFmpeg [choose: release build (bottom option) + your architecture + static]
2) Inside the zip file you'll find a folder called 'bin' and a file in there called 'ffmpeg.exe'. Copy that file somewhere in your path where your videos are.
3) Open the command prompt (cmd) and work your way to the directory containing the videos.
E.g.: cd \Users\<your username>\Videos
4) Use the command: ffmpeg -i input.mkv -c:v copy -c:a aac -ac 2 -b:a 256K output.mp4
Example:
ffmpeg -i "National Treasure.mkv" -c:v copy -c:a aac -ac 2 -b:a 256K "National Treasure.mp4"
How the command works:
- ffmpeg - use the program
- i - input something
- input.mkv - input file (your video)
- c:v copy - [codec:video] copy - copies the video stream (no quality change) and does not re-encode it - makes this process very fast
- c:a aac - [codec:audio] - switches to the audio stream and re-encodes in the AAC codec, which Roku can decode
- ac 2 - set # of audio channels to 2 (stereo)
- b:a 256K- sets audio bitrate to 256
- output.mp4 - your output video name; switches container type to MP4
Misc:
> You can see video information by using ffmpeg -i movie.mkv. It shows you the audio codec used. MKV container + AAC audio will work fine.
> Roku audio and video support.
> This command uses a small amount of CPU processing time and a lot of disk time. Only way to speed this process up is to do this on an SSD.
Last edited: