diff --git a/motd.txt b/motd.txt index 889ee64..92ac523 100644 --- a/motd.txt +++ b/motd.txt @@ -1,5 +1,5 @@ -A new version of the wrapper was deployed (v2.6) fixing an issue with offline transcoding. -You can find the changelog here: https://github.com/AlexPresso/VideoStation-FFMPEG-Patcher/releases/tag/2.6 +A new version of the wrapper was deployed (v3.2) fixing an issue with video filters on ffmpeg7. +You can find the changelog here: https://github.com/AlexPresso/VideoStation-FFMPEG-Patcher/releases/tag/3.2 /!\ PLEASE FOLLOW THE UPDATE PROCEDURE IN THE CHANGELOG TO UPDATE /!\ diff --git a/wrappers/ffmpeg.sh b/wrappers/ffmpeg.sh index 8c23ebc..7c4a63f 100644 --- a/wrappers/ffmpeg.sh +++ b/wrappers/ffmpeg.sh @@ -5,6 +5,7 @@ ######################### ffmpeg_version=@ffmpeg_version@ +ffmpeg_major_version=$(echo "$ffmpeg_version" | grep -oE '[0-9]+') pid=$$ child="" stderrfile="/tmp/ffmpeg-$pid.stderr" @@ -92,6 +93,22 @@ fix_args() { args+=("-vf" "$arg") ;; + -vbsf) + shift + param="-vbsf" + arg="$1" + + if [[ "$ffmpeg_major_version" -gt 4 ]]; then + param="-bsf:v" + + if [[ "$arg" == *"repeatheader"* ]]; then + arg="${arg//repeatheader/repeat_header=1}" + fi + fi + + args+=("$param" "$arg") + ;; + -r) shift ;;