From b3dfbe8b70b870399dc335b8dcf028bb9a3955de Mon Sep 17 00:00:00 2001 From: Mitja Felicijan Date: Wed, 24 May 2023 05:57:50 +0200 Subject: Added notes as a separate type of content and moved the content --- content/notes/convert-mkv.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 content/notes/convert-mkv.md (limited to 'content/notes/convert-mkv.md') diff --git a/content/notes/convert-mkv.md b/content/notes/convert-mkv.md new file mode 100644 index 0000000..cca08d7 --- /dev/null +++ b/content/notes/convert-mkv.md @@ -0,0 +1,20 @@ +--- +title: Convert all MKV files into other formats +url: convert-mkv.html +date: 2023-05-14 +type: notes +draft: false +--- + +You will need `ffmpeg` installed on your system. This will convert all MKV files +into WebM format. + +```sh +# Convert all MKV files into WebM format. +find ./ -name '*.mkv' -exec bash -c 'ffmpeg -i "$0" -vcodec libvpx -acodec libvorbis -cpu-used 5 -threads 8 "${0%%.mp4}.webm"' {} \; +``` + +```sh +# Convert all MKV files into MP4 format. +find ./ -name '*.mkv' -exec bash -c 'ffmpeg -i "$0" c:a copy -c:v copy -cpu-used 5 -threads 8 "${0%%.mp4}.mp4"' {} \; +``` -- cgit v1.2.3