From 58b228f01c3ee64d5934428f416b4416d807b5c8 Mon Sep 17 00:00:00 2001 From: Hugo Villeneuve Date: Wed, 25 Oct 2023 16:32:57 -0400 Subject: [PATCH] Add record_max_nf() --- fgen.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/fgen.sh b/fgen.sh index b1bd4e2..5ffb9d7 100755 --- a/fgen.sh +++ b/fgen.sh @@ -160,6 +160,13 @@ function insert_empty_frames() done } +function record_max_nf() +{ + if [ ${nf} -gt ${max_nf} ]; then + max_nf="${nf}" + fi +} + function generate_video() { local png_files @@ -290,6 +297,7 @@ if [ ${trames} -eq 1 ]; then convert -size ${size} xc:none ${dest}/background.png nf="" + max_nf="0" oldnf="" files="" group="default" @@ -355,6 +363,7 @@ if [ ${trames} -eq 1 ]; then fi log_dbg "New frame ID: ${nf}" + record_max_nf fname=$(get_frame_name ${nf}) -- 2.20.1