From f19938a0c25dfd4a74e0263401b2931aa6bc07f9 Mon Sep 17 00:00:00 2001 From: Ken Fallon Date: Fri, 4 Oct 2024 19:33:29 +0200 Subject: [PATCH] 2024-10-04_17-33-29Z_Friday --- bin/audio2image.bash | 18 +++++++++--------- bin/hprtranscode.bash | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/bin/audio2image.bash b/bin/audio2image.bash index 3331316..954cf82 100755 --- a/bin/audio2image.bash +++ b/bin/audio2image.bash @@ -54,20 +54,20 @@ trap 'cleanup_temp $TMP1' SIGHUP SIGINT SIGPIPE SIGTERM EXIT ffmpeg -v 0 -analyzeduration 900000000000 -probesize 200M -threads 2 -i "$AUDIO" \ -filter_complex aformat=channel_layouts=mono,showwavespic=colors=white:s=3200x800 \ -frames:v 1 -f apng - 2>/dev/null | \ - convert - -background black -alpha remove -alpha off "$TMP1" 2>/dev/null | cat > /dev/null 2>&1 + magick convert - -background black -alpha remove -alpha off "$TMP1" 2>/dev/null | cat > /dev/null 2>&1 # # Not clear what's being done to the image here, but it produces a useful end # result, or seems to! # -convert -background black "$TMP1" -gravity center -background black -transparent white - | \ - convert - -gravity South -background white -splice 0x5 -background black -splice 0x5 - | \ - convert - -trim - | \ - convert - -gravity South -chop 0x5 - | \ - convert - -gravity North -background white -splice 0x5 -background black -splice 0x5 - | \ - convert - -trim - | \ - convert - -gravity North -chop 0x5 - | \ - convert - -resize '800x200!' "$IMAGE" +magick convert -background black "$TMP1" -gravity center -background black -transparent white - | \ + magick convert - -gravity South -background white -splice 0x5 -background black -splice 0x5 - | \ + magick convert - -trim - | \ + magick convert - -gravity South -chop 0x5 - | \ + magick convert - -gravity North -background white -splice 0x5 -background black -splice 0x5 - | \ + magick convert - -trim - | \ + magick convert - -gravity North -chop 0x5 - | \ + magick convert - -resize '800x200!' "$IMAGE" # # The original renamed the temporary file to be the target image file, but diff --git a/bin/hprtranscode.bash b/bin/hprtranscode.bash index e9007ec..fa6fb1a 100755 --- a/bin/hprtranscode.bash +++ b/bin/hprtranscode.bash @@ -575,7 +575,7 @@ then # rsync -ave ssh --partial --progress --ignore-existing "${media_dir}/hpr${ep_num}.wav".txt hpr:www/eps/hpr${ep_num}/hpr${ep_num}.txt | tee -a ${fname}_tmp.log # # ssh hpr -t "ls -al /home/hpr/www/eps/hpr${ep_num}*" -# cp -v "${mediafile}" "${upload_dir}/hpr${ep_num}_source.${mediaextension}" + cp -v "${mediafile}" "${upload_dir}/hpr${ep_num}_source.${mediaextension}" #echo "Remove temp files" rm -v ~hpr${ep_num}_summary.wav ~~hpr${ep_num}_summary.wav silence.wav