diff options
| author | Kévin Le Gouguec <kevin.legouguec@gmail.com> | 2022-01-09 23:00:42 +0100 |
|---|---|---|
| committer | Kévin Le Gouguec <kevin.legouguec@gmail.com> | 2022-01-09 23:00:42 +0100 |
| commit | 5c8fb8533f611e0ce537f7b9c43052908a28219d (patch) | |
| tree | c936d4be2645926b8d483e8169e14d2f979ccf23 | |
| parent | 98fb7199eb02a3c46bd92943334132adb67f8507 (diff) | |
| download | memory-leaks-5c8fb8533f611e0ce537f7b9c43052908a28219d.tar.xz | |
Add ffmpeg recipes
| -rw-r--r-- | guides/ffmpeg.org | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/guides/ffmpeg.org b/guides/ffmpeg.org new file mode 100644 index 0000000..eded0e9 --- /dev/null +++ b/guides/ffmpeg.org @@ -0,0 +1,22 @@ +ffmpeg recipes I should stuff into config files or scripts, but +haven't yet. +* Extracting parts of videos +~-c copy -map 0~ ensures all streams (audio & subtitles) are kept. +The timestamp syntax is described in the "Time duration" section of +=ffmpeg-utils(1)=; =MM:SS= works fine. + +#+begin_src sh +ffmpeg -i $input -c copy -map 0 \ + -ss $tstart -to $tend \ + $output +#+end_src + +* Reduce file size +** with =-vf=: ~-vf "scale=iw/2:ih/2"~ +** with H.265 +openSUSE Tumbleweed's ffmpeg is not built with H.265 support AFAICT. + +1. Install =libx265-devel= +2. Clone =https://git.ffmpeg.org/ffmpeg.git= +3. ~./configure --enable-libx265 --enable-gpl~ +4. ~ffmpeg -i $input -vcodec libx265 -crf 28~ |
