commit ea06e107f2ab831de4f9c69c3917541b2fc52e1a parent 476d314bb48a643a6123e9dcb11943dbd00048db Author: Kévin Le Gouguec <kevin.legouguec@gmail.com> Date: Tue, 23 Mar 2021 22:23:48 +0100 Use Pierre's re-tinted photos Diffstat:
| A | admin/prep-quartet-photos.sh | | | 31 | +++++++++++++++++++++++++++++++ |
| M | images/david/full.png | | | 0 | |
| M | images/enguerrand/full.png | | | 0 | |
| M | images/hervé/full.png | | | 0 | |
| M | images/sophie/full.png | | | 0 |
5 files changed, 31 insertions(+), 0 deletions(-)
diff --git a/admin/prep-quartet-photos.sh b/admin/prep-quartet-photos.sh @@ -0,0 +1,31 @@ +#!/bin/bash + +set -euxo pipefail + +declare -A heights=( + [sophie]=1100 + [hervé]=1125 + [enguerrand]=1175 + [david]=1200 +) + +processimg () +{ + local src=$1 + local name=$(basename "${src}") + name="${name%% *}" + name=${name,} + local dst=../images/${name}/full.png + local height=${heights[${name}]} + + magick "${src}" -trim ${dst} + magick ${dst} -scale x${height} ${dst} + magick ${dst} -background none -gravity north -splice 0x$((1200-height)) ${dst} +} + +for img in "$@" +do + processimg "${img}" & +done + +wait diff --git a/images/david/full.png b/images/david/full.png Binary files differ. diff --git a/images/enguerrand/full.png b/images/enguerrand/full.png Binary files differ. diff --git a/images/hervé/full.png b/images/hervé/full.png Binary files differ. diff --git a/images/sophie/full.png b/images/sophie/full.png Binary files differ.