Skip to content

Commit

Permalink
Adding parsers to most builds
Browse files Browse the repository at this point in the history
FFmpeg has "parsers" for reading packet information. They're usually not
used, because each decoder has its own parser, but, they're necessary on
seek for it to skip the intervening packets. This change is essentially
mandatory for seeking to work with most codecs.
  • Loading branch information
Yahweasel committed Nov 7, 2023
1 parent fbe5b07 commit 80017f1
Show file tree
Hide file tree
Showing 19 changed files with 85 additions and 17 deletions.
4 changes: 4 additions & 0 deletions configs/all-audio-cli/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,22 @@
--enable-muxer=ogg
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=mov
--enable-muxer=ipod
--enable-parser=aac
--enable-decoder=aac
--enable-encoder=aac
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-parser=vorbis
--enable-libvorbis
--enable-decoder=libvorbis
--enable-encoder=libvorbis
Expand Down
12 changes: 12 additions & 0 deletions configs/all/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,19 @@
--enable-muxer=ogg
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=mov
--enable-muxer=ipod
--enable-parser=aac
--enable-decoder=aac
--enable-encoder=aac
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-decoder=pcm_s16le --enable-decoder=pcm_s24le
Expand All @@ -27,6 +30,7 @@
--enable-filter=bandpass --enable-filter=bandreject --enable-filter=dynaudnorm
--enable-filter=equalizer --enable-filter=loudnorm --enable-filter=pan
--enable-filter=amix --enable-filter=volume --enable-filter=anull
--enable-parser=vorbis
--enable-libvorbis
--enable-decoder=libvorbis
--enable-encoder=libvorbis
Expand All @@ -47,18 +51,22 @@
--enable-encoder=pcm_f32le
--enable-ffmpeg --enable-ffprobe
--enable-filter=scale
--enable-parser=vp8
--enable-libvpx
--enable-decoder=libvpx_vp8
--enable-libvpx
--enable-encoder=libvpx_vp8
--enable-parser=h264
--enable-decoder=h264
--enable-bsf=h264_metadata
--enable-bsf=extract_extradata
--enable-parser=vp9
--enable-libvpx
--enable-decoder=libvpx_vp9
--enable-bsf=vp9_metadata
--enable-libvpx
--enable-encoder=libvpx_vp9
--enable-parser=av1
--enable-libaom
--enable-decoder=libaom_av1
--enable-bsf=av1_metadata
Expand All @@ -71,14 +79,18 @@
--enable-bsf=extract_extradata
--enable-bsf=vp9_metadata
--enable-bsf=h264_metadata
--enable-parser=hevc
--enable-bsf=hevc_metadata
--enable-bsf=av1_metadata
--enable-demuxer=image2
--enable-muxer=image2
--enable-parser=gif
--enable-decoder=gif
--enable-encoder=gif
--enable-parser=mjpeg
--enable-decoder=mjpeg
--enable-encoder=mjpeg
--enable-parser=png
--enable-zlib
--enable-decoder=png
--enable-encoder=png
Expand Down
3 changes: 3 additions & 0 deletions configs/default/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,19 @@
--enable-muxer=ogg
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=mov
--enable-muxer=ipod
--enable-parser=aac
--enable-decoder=aac
--enable-encoder=aac
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-decoder=pcm_s16le --enable-decoder=pcm_s24le
Expand Down
4 changes: 4 additions & 0 deletions configs/fat/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,22 @@
--enable-muxer=ogg
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=mov
--enable-muxer=ipod
--enable-parser=aac
--enable-decoder=aac
--enable-encoder=aac
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-parser=vorbis
--enable-libvorbis
--enable-decoder=libvorbis
--enable-encoder=libvorbis
Expand Down
1 change: 1 addition & 0 deletions configs/flac/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
--enable-filter=aresample
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
1 change: 1 addition & 0 deletions configs/h265/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-filter=scale
--enable-parser=hevc
--enable-decoder=hevc
--enable-bsf=hevc_metadata
--enable-bsf=extract_extradata
3 changes: 3 additions & 0 deletions configs/images/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,13 @@
--enable-muxer=matroska --enable-muxer=webm
--enable-demuxer=image2
--enable-muxer=image2
--enable-parser=gif
--enable-decoder=gif
--enable-encoder=gif
--enable-parser=mjpeg
--enable-decoder=mjpeg
--enable-encoder=mjpeg
--enable-parser=png
--enable-zlib
--enable-decoder=png
--enable-encoder=png
2 changes: 2 additions & 0 deletions configs/lite/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@
--enable-filter=aresample
--enable-demuxer=ogg
--enable-muxer=ogg
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-decoder=pcm_s16le --enable-decoder=pcm_s24le
Expand Down
5 changes: 5 additions & 0 deletions configs/mediarecorder-openh264/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,28 @@
--enable-muxer=ogg
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=mov
--enable-muxer=ipod
--enable-parser=aac
--enable-decoder=aac
--enable-encoder=aac
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-filter=scale
--enable-parser=vp8
--enable-libvpx
--enable-decoder=libvpx_vp8
--enable-libvpx
--enable-encoder=libvpx_vp8
--enable-parser=h264
--enable-decoder=h264
--enable-bsf=h264_metadata
--enable-bsf=extract_extradata
Expand Down
5 changes: 5 additions & 0 deletions configs/mediarecorder-transcoder/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,28 @@
--enable-muxer=ogg
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=mov
--enable-muxer=ipod
--enable-parser=aac
--enable-decoder=aac
--enable-encoder=aac
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-filter=scale
--enable-parser=vp8
--enable-libvpx
--enable-decoder=libvpx_vp8
--enable-libvpx
--enable-encoder=libvpx_vp8
--enable-parser=h264
--enable-decoder=h264
--enable-bsf=h264_metadata
--enable-bsf=extract_extradata
1 change: 1 addition & 0 deletions configs/mkconfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ function addFragment(out, part) {
res[1] === "decoder" ||
res[1] === "encoder" ||
res[1] === "filter" ||
res[1] === "parser" ||
res[1] === "bsf") {
// Just add the ffmpeg config directly
out["ffmpeg-config.txt"].write(
Expand Down
34 changes: 17 additions & 17 deletions configs/mkconfigs.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,33 +18,33 @@ const cproc = require("child_process");
const fs = require("fs");

const configs = [
["default", ["format-ogg", "format-webm", "codec-libopus", "format-mp4", "codec-aac", "format-flac", "codec-flac", "format-wav", "audio-filters"]],
["lite", ["format-ogg", "codec-libopus", "format-flac", "codec-flac", "format-wav", "audio-filters"]],
["fat", ["format-ogg", "format-webm", "codec-libopus", "format-mp4", "codec-aac", "format-flac", "codec-flac", "codec-libvorbis", "format-wavpack", "codec-alac", "format-wav", "audio-filters"]],
["obsolete", ["format-ogg", "format-webm", "codec-libopus", "format-mp4", "codec-aac", "format-flac", "codec-flac", "codec-libvorbis", "format-mp3", "decoder-mp3", "encoder-libmp3lame", "audio-filters"]],
["opus", ["format-ogg", "codec-libopus"]],
["flac", ["format-flac", "codec-flac"]],
["opus-flac", ["format-ogg", "codec-libopus", "format-flac", "codec-flac"]],
["all-audio-cli", ["format-ogg", "format-webm", "codec-libopus", "format-mp4", "codec-aac", "format-flac", "codec-flac", "codec-libvorbis", "format-mp3", "decoder-mp3", "encoder-libmp3lame", "format-wav", "format-pcm_f32le", "codec-pcm_f32le", "audio-filters", "cli", "workerfs"]],
["default", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-mp4", "parser-aac", "codec-aac", "format-flac", "parser-flac", "codec-flac", "format-wav", "audio-filters"]],
["lite", ["format-ogg", "parser-opus", "codec-libopus", "format-flac", "parser-flac", "codec-flac", "format-wav", "audio-filters"]],
["fat", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-mp4", "parser-aac", "codec-aac", "format-flac", "parser-flac", "codec-flac", "parser-vorbis", "codec-libvorbis", "format-wavpack", "codec-alac", "format-wav", "audio-filters"]],
["obsolete", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-mp4", "parser-aac", "codec-aac", "format-flac", "parser-flac", "codec-flac", "parser-vorbis", "codec-libvorbis", "format-mp3", "decoder-mp3", "encoder-libmp3lame", "audio-filters"]],
["opus", ["format-ogg", "parser-opus", "codec-libopus"]],
["flac", ["format-flac", "parser-flac", "codec-flac"]],
["opus-flac", ["format-ogg", "parser-opus", "codec-libopus", "format-flac", "parser-flac", "codec-flac"]],
["all-audio-cli", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-mp4", "parser-aac", "codec-aac", "format-flac", "parser-flac", "codec-flac", "parser-vorbis", "codec-libvorbis", "format-mp3", "decoder-mp3", "encoder-libmp3lame", "format-wav", "format-pcm_f32le", "codec-pcm_f32le", "audio-filters", "cli", "workerfs"]],

["webm", ["format-ogg", "format-webm", "codec-libopus", "format-mp4", "codec-aac", "format-flac", "codec-flac", "swscale", "libvpx", "codec-libvpx_vp8", "format-wav", "audio-filters"]],
["webm-opus-flac", ["format-ogg", "format-webm", "codec-libopus", "format-flac", "codec-flac", "swscale", "libvpx", "codec-libvpx_vp8"]],
["mediarecorder-transcoder", ["format-ogg", "format-webm", "codec-libopus", "format-mp4", "codec-aac", "format-flac", "codec-flac", "swscale", "libvpx", "codec-libvpx_vp8", "decoder-h264"]],
["open-media", ["format-ogg", "format-webm", "codec-libopus", "format-flac", "codec-flac", "codec-libvorbis", "swscale", "libvpx", "codec-libvpx_vp8", "codec-libvpx_vp9", "codec-libaom_av1"]],
["rawvideo", ["format-ogg", "format-webm", "codec-libopus", "format-mp4", "codec-aac", "format-flac", "codec-flac", "swscale", "libvpx", "codec-libvpx_vp8", "decoder-h264", "format-rawvideo", "codec-rawvideo"]],
["webm", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-mp4", "parser-aac", "codec-aac", "format-flac", "parser-flac", "codec-flac", "swscale", "libvpx", "parser-vp8", "codec-libvpx_vp8", "format-wav", "audio-filters"]],
["webm-opus-flac", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-flac", "parser-flac", "codec-flac", "swscale", "libvpx", "parser-vp8", "codec-libvpx_vp8"]],
["mediarecorder-transcoder", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-mp4", "parser-aac", "codec-aac", "format-flac", "parser-flac", "codec-flac", "swscale", "libvpx", "parser-vp8", "codec-libvpx_vp8", "parser-h264", "decoder-h264"]],
["open-media", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-flac", "parser-flac", "codec-flac", "parser-vorbis", "codec-libvorbis", "swscale", "libvpx", "parser-vp8", "codec-libvpx_vp8", "parser-vp9", "codec-libvpx_vp9", "parser-av1", "codec-libaom_av1"]],
["rawvideo", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-mp4", "parser-aac", "codec-aac", "format-flac", "parser-flac", "codec-flac", "swscale", "libvpx", "parser-vp8", "codec-libvpx_vp8", "parser-h264", "decoder-h264", "format-rawvideo", "codec-rawvideo"]],

["webcodecs", ["format-ogg", "format-webm", "format-mp4", "format-flac", "codec-libopus", "codec-aac", "codec-flac", "swscale", "libvpx", "codec-libvpx_vp8", "bsf-extract_extradata", "bsf-vp9_metadata", "bsf-h264_metadata", "bsf-hevc_metadata", "bsf-av1_metadata"]],
["webcodecs", ["format-ogg", "format-webm", "format-mp4", "format-flac", "parser-opus", "codec-libopus", "parser-aac", "codec-aac", "parser-flac", "codec-flac", "swscale", "libvpx", "parser-vp8", "codec-libvpx_vp8", "bsf-extract_extradata", "parser-vp9", "bsf-vp9_metadata", "parser-h264", "bsf-h264_metadata", "parser-hevc", "bsf-hevc_metadata", "bsf-av1_metadata"]],

// These are mainly here so that "all" will have them for testing
["images", ["format-webm", "format-image2", "codec-gif", "codec-mjpeg", "codec-png"]],
["h265", ["format-mp4", "format-webm", "swscale", "decoder-hevc"]],
["images", ["format-webm", "format-image2", "parser-gif", "codec-gif", "parser-mjpeg", "codec-mjpeg", "parser-png", "codec-png"]],
["h265", ["format-mp4", "format-webm", "swscale", "parser-hevc", "decoder-hevc"]],
["prores", ["format-mp4", "format-webm", "swscale", "codec-prores"]],
["qtrle", ["format-mov", "swscale", "codec-qtrle"]],
["jsfetch", ["protocol-jsfetch"]],
["hls", ["format-hls"]],

// Patent and/or license encumbered encoders
["mediarecorder-openh264", ["format-ogg", "format-webm", "codec-libopus", "format-mp4", "codec-aac", "format-flac", "codec-flac", "swscale", "libvpx", "codec-libvpx_vp8", "decoder-h264", "codec-libopenh264"]],
["mediarecorder-openh264", ["format-ogg", "format-webm", "parser-opus", "codec-libopus", "format-mp4", "parser-aac", "codec-aac", "format-flac", "parser-flac", "codec-flac", "swscale", "libvpx", "parser-vp8", "codec-libvpx_vp8", "parser-h264", "decoder-h264", "codec-libopenh264"]],

["empty", []],
["all", null]
Expand Down
4 changes: 4 additions & 0 deletions configs/obsolete/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,22 @@
--enable-muxer=ogg
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=mov
--enable-muxer=ipod
--enable-parser=aac
--enable-decoder=aac
--enable-encoder=aac
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-parser=vorbis
--enable-libvorbis
--enable-decoder=libvorbis
--enable-encoder=libvorbis
Expand Down
6 changes: 6 additions & 0 deletions configs/open-media/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,33 @@
--enable-muxer=ogg
--enable-demuxer=matroska
--enable-muxer=matroska --enable-muxer=webm
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
--enable-parser=vorbis
--enable-libvorbis
--enable-decoder=libvorbis
--enable-encoder=libvorbis
--enable-filter=scale
--enable-parser=vp8
--enable-libvpx
--enable-decoder=libvpx_vp8
--enable-libvpx
--enable-encoder=libvpx_vp8
--enable-parser=vp9
--enable-libvpx
--enable-decoder=libvpx_vp9
--enable-bsf=vp9_metadata
--enable-libvpx
--enable-encoder=libvpx_vp9
--enable-parser=av1
--enable-libaom
--enable-decoder=libaom_av1
--enable-bsf=av1_metadata
Expand Down
2 changes: 2 additions & 0 deletions configs/opus-flac/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,13 @@
--enable-filter=aresample
--enable-demuxer=ogg
--enable-muxer=ogg
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
--enable-encoder=libopus
--enable-demuxer=flac
--enable-muxer=flac
--enable-parser=flac
--enable-decoder=flac
--enable-encoder=flac
1 change: 1 addition & 0 deletions configs/opus/ffmpeg-config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
--enable-filter=aresample
--enable-demuxer=ogg
--enable-muxer=ogg
--enable-parser=opus
--enable-libopus
--enable-decoder=libopus
--enable-bsf=opus_metadata
Expand Down
Loading

0 comments on commit 80017f1

Please sign in to comment.