diff --git a/rc_shared.sh b/rc_shared.sh index ea8d5e3..9e0a5cd 100644 --- a/rc_shared.sh +++ b/rc_shared.sh @@ -1163,6 +1163,8 @@ function pv3 { out="$2" echo "Processing '$org' to '$out' using AV1 and OPUS." + vrt="$3" + ## Versions ## # v0 @@ -1216,11 +1218,17 @@ function pv3 { ## Main ## + if [[ -n "$vrt" ]]; then + scale=720:-1 + echo "Using a vertial orientation,. $scale" + fi + echo -e "\n * Original File * \n" ffprobe -i "$org" echo -e "\n * Starting Processing *\n" date + start=$SECONDS set -x ffmpeg -nostdin -hide_banner -loglevel level+warning \ -i "$org" \ @@ -1235,6 +1243,7 @@ function pv3 { "$out" status="$?" set +x + end=$SECONDS # -crf $crf \ if [[ "$status" != 0 || ! -s "$out" ]]; then @@ -1243,8 +1252,17 @@ function pv3 { return $status fi - echo -e "\n * Success! *" + seconds=(( end - start )) + h=$(( seconds / 60 / 60 )) + m=$(( seconds / 60 % 60 )) + s=$(( seconds % 60 )) + + echo -e "\n * Success! Took ${h}h${m}m${s}s. *" } +function pv3s { + pv3 "$1" "$2" y +} +alias pvs3="pv3s" # 20260915 - Stack 2 videos for comparing quality. TBD: Move to Ansible? function vcompare {