There may be various codecs used, but for the file I needed to convert, Media Player Classic (my favorite movie player, installed with K-Lite Codec Pack) shows following information after selecting File > Properties: Now, each stream is encoded using some specific codec. Each format encapsulates a set of streams, usually one video and one audio stream. To understand this method, first you need to know that media file formats are just containers (for example, MKV is Matroska). The feature we need can be found in menu File > Remux Recordings. This is a free and open source app intended mostly for video recording and streaming. Important update : I found another way to quickly remux MKV to MP4 using OBS Studio. I keep it for reference, but it probably doesn't reflect my current knowledge and beliefs.ĭo you have a video in MKV file and you can't open it because some program (like Sony Vegas Pro) doesn't support this format? If so, you probably wonder how to convert it into some different format. See stream selection in the ffmpeg documentation for more info and an explanation of "best".Warning! Some information on this page is older than 6 years now. Add -map 0, as slhck mentioned, to override this default and include all streams from input 0 (the first input). libvo_aacenc only accepts -b:a.īy default ffmpeg will choose the "best" video, audio, and subtitle stream from your input resulting in an output with potentially one video, one audio stream, and one subtitle stream. If you must use libvo_aacenc you can add -ac 2 or use an audio filter to change the output to two channels.ĭeclaring a "quality" for your audio is probably easiest, such as -q:a 100 for libfaac or -vbr 5 for libfdk_aac, otherwise you can choose the audio bitrate with -b:a, but note that the bitrate will be shared among all channels so give it a higher value than you would for a stereo output. You can use aac (with -strict experimental), libfaac, or libfdk_aac (if your ffmpeg were configured to support it) to preserve your channels. Libvo_aacenc probably can not encode 5.1 channels and is a poor encoder in general. Output #0, mp4, to 'E:\iTunes\Automatically Add to iTunes\Pitch Perfect.mp4': Vpx -enable-libx264 -enable-libxavs -enable-libxvid -enable-zlib Ra -enable-libutvideo -enable-libvo-aacenc -enable-libvo-amrwbenc -enable-libvorbis -enable-lib Le-avisynth -enable-bzlib -enable-frei0r -enable-libass -enable-libopencore-amrnb -enable-libopĮncore-amrwb -enable-libfreetype -enable-libgsm -enable-libmp3lame -enable-libnut -enable-libopĮnjpeg -enable-libopus -enable-librtmp -enable-libschroedinger -enable-libspeex -enable-libtheo Here's the complete output: C:\Program Files\ffmpeg\bin>"C:\Program Files\ffmpeg\bin\ffmpeg.exe" -i "E:\movies\A film.mkv" -y -f mp4 -vcodec copy -acodec libvo_aacenc -ac 6 "E:\iTunes\Automatically Add to iTunes\A film.mp4"įfmpeg version N-47062-g26c531c Copyright (c) 2000-2012 the FFmpeg developersĬonfiguration: -enable-gpl -enable-version3 -disable-pthreads -enable-runtime-cpudetect -enab Here's what I have so far: ffmpeg -i "input.mkv" -y -f mp4 -vcodec copy -acodec libvo_aacenc -ac 6 "output.mp4"Įrror while opening encoder for output stream #0:1 - maybe incorrect parameters such as bit_rate, rate, width or height I want to remux all audio streams, or at the very least the english stream. However it only took the first audio stream regardless of language. I had a ffmpeg command that would successfully remux an mkv to a iTunes compatible mp4.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |