243 lines
4.5 KiB
Bash
Executable File
243 lines
4.5 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
set -e ; set -u
|
|
|
|
source tools/config.sh
|
|
|
|
IDX=0
|
|
SPOOL="frames/Spool"
|
|
SEQNAME="none"
|
|
TMP="WS/lf-tmp.png"
|
|
FONTE="FreeSerif-Bold"
|
|
BSLVL=0 # bullshit level
|
|
|
|
source tools/fonctions.sh
|
|
|
|
# =======================================================
|
|
# /!\ this function just copy the
|
|
# file to the spool dir, so
|
|
# you can use it for tmp pics.
|
|
#
|
|
copy_a_file ()
|
|
{
|
|
src="$1"
|
|
dstname=$(printf "%s/%05d.png" $SPOOL $IDX)
|
|
# echo "$src -> $dstname"
|
|
# ln --force --symbolic $src $dstname
|
|
cp -f $src $dstname
|
|
IDX=$(( IDX + 1 ))
|
|
}
|
|
# =======================================================
|
|
intersequence ()
|
|
{
|
|
local nombre=$1
|
|
local blabla=$2
|
|
|
|
echo "Inter Sequence : $nombre [$blabla]"
|
|
|
|
# --- preparation du fond
|
|
local TGA="/dev/shm/lnkfrm-hexa-inter-A.tga"
|
|
local IMG="/dev/shm/lnkfrm-hexa-inter-B.png
|
|
"
|
|
tga_tools mk_hgrad $TGA $Img_Width $Img_Height
|
|
tga_effects $TGA noise $TGA 60
|
|
tga_television $TGA gruud $TGA 0
|
|
|
|
for foo in $(seq 0 $nombre)
|
|
do
|
|
local txt=$( printf "bslvl: 0x%06x" $accu )
|
|
convert $TGA \
|
|
-font Courier-Regular \
|
|
-pointsize 64 \
|
|
-fill $INFOCOL \
|
|
-annotate +50+160 "$txt" \
|
|
-annotate +50+300 "$blabla" \
|
|
$IMG
|
|
copy_a_file ${IMG}
|
|
copy_a_file ${IMG}
|
|
copy_a_file ${IMG}
|
|
BSLVL=$(( BSLVL + $RANDOM + $RANDOM ))
|
|
done
|
|
|
|
}
|
|
# =======================================================
|
|
#
|
|
# c'est ici qu'on insère une séquence dans le film
|
|
#
|
|
linkfarm ()
|
|
{
|
|
SRC="frames/$1"
|
|
echo "linkfarm $SRC" # XXX | tee -a WS/log
|
|
|
|
local INTER="/dev/shm/tmp-intertitre.png"
|
|
tools/plot-timing.sh $1
|
|
local NBRE=42
|
|
|
|
convert "WS/negatif.png" \
|
|
-gravity center \
|
|
-font $FONTE \
|
|
-pointsize 110 \
|
|
-kerning 15 \
|
|
-fill $TEXTCOL \
|
|
-strokewidth 2 -stroke $STROKOL \
|
|
-annotate +0+0 "$1" \
|
|
${INTER}
|
|
|
|
for foo in $(seq 0 $(( $NBRE * 2)) )
|
|
do
|
|
copy_a_file $INTER
|
|
# :
|
|
done
|
|
|
|
for foo in $(seq 0 $NBRE)
|
|
do
|
|
copy_a_file "$SRC/00000.png"
|
|
done
|
|
|
|
sleep 15
|
|
|
|
for src in "$SRC"/*
|
|
do
|
|
copy_a_file $src
|
|
done
|
|
|
|
PIC=$( printf "%s/%05d.png" $SRC $((NBFRAMES-1)) )
|
|
# echo "Endpic $PIC" >> WS/log
|
|
for foo in $(seq 0 $NBRE)
|
|
do
|
|
copy_a_file "$PIC"
|
|
done
|
|
}
|
|
# =======================================================
|
|
faire_le_titre ()
|
|
{
|
|
echo "faire le titre"
|
|
|
|
local NBRE=320
|
|
local SRC="frames/hexatube/00451.png"
|
|
local GRAY="/dev/shm/tmp-titre.png"
|
|
|
|
intersequence 33 "loading..."
|
|
intersequence 8 "LOADED !!!"
|
|
|
|
for foo in $(seq 1 15)
|
|
do
|
|
K=$(( foo * 3 ))
|
|
convert -colorspace gray -colors 8 \
|
|
-blur ${K}x${K} $SRC $GRAY
|
|
copy_a_file "$GRAY"
|
|
done
|
|
|
|
# --- le titre du flim (at 11 ?)
|
|
convert -colorspace gray -colors 42 $SRC $GRAY
|
|
Ypos=-25
|
|
Psiz=65
|
|
|
|
txt="La vie\nde la\nfamille\nHexaCone"
|
|
|
|
for foo in $(seq 0 $NBRE)
|
|
do
|
|
convert ${GRAY} \
|
|
-gravity South \
|
|
-font $FONTE \
|
|
-pointsize $Psiz \
|
|
-kerning 6 \
|
|
-fill $TEXTCOL \
|
|
-strokewidth 3 -stroke $STROKOL \
|
|
-annotate +0+${Ypos} "$txt" \
|
|
${TMP}
|
|
|
|
copy_a_file ${TMP}
|
|
Ypos=$(( Ypos + 2 ))
|
|
Psiz=$(( Psiz + 1 ))
|
|
printf "."
|
|
done
|
|
echo
|
|
}
|
|
# =======================================================
|
|
faire_la_fin ()
|
|
{
|
|
local NBRE=190
|
|
datetime=$(LANG=fr date -u +"%Y/%m/%d %H:%M" | tr "01" "ol" )
|
|
echo " $datetime" | tee -a WS/log
|
|
|
|
local SRC="frames/around/00586.png"
|
|
local GRAY="/dev/shm/tmp-fin.png"
|
|
convert -dither none -colorspace gray -colors 24 $SRC $GRAY
|
|
|
|
for foo in $(seq 0 $NBRE)
|
|
do
|
|
Ypos=$(( foo + 28 ))
|
|
convert ${GRAY} \
|
|
-gravity north \
|
|
-font $FONTE \
|
|
-pointsize 90 \
|
|
-kerning 8 \
|
|
-fill $TEXTCOL \
|
|
-strokewidth 2 -stroke $STROKOL \
|
|
-annotate +0+${Ypos} \
|
|
"un film de\ntTh des Bourtoulots" \
|
|
-font Courier-Bold \
|
|
-pointsize 48 \
|
|
-kerning 1 \
|
|
-strokewidth 1 \
|
|
-gravity south \
|
|
-annotate +0+110 "${datetime}" \
|
|
${TMP}
|
|
# identify ${TMP}
|
|
copy_a_file ${TMP}
|
|
|
|
printf "."
|
|
done
|
|
intersequence 35 "unloading"
|
|
intersequence 5 "unloaded!"
|
|
|
|
echo
|
|
}
|
|
# =======================================================
|
|
|
|
figlet "Link farmer"
|
|
|
|
rm -f frames/Spool/*.png
|
|
|
|
faire_le_titre
|
|
|
|
linkfarm approche
|
|
linkfarm hexacone
|
|
linkfarm hexabenz
|
|
linkfarm hexawood
|
|
linkfarm around # new 26 jan 2026
|
|
|
|
# linkfarm escadrille
|
|
# linkfarm cutoff
|
|
# linkfarm topview
|
|
# linkfarm trident
|
|
# linkfarm scene
|
|
# linkfarm carto
|
|
# linkfarm bubblecut
|
|
# linkfarm orbite
|
|
|
|
intersequence 60 "entering danger zone..."
|
|
linkfarm circular
|
|
linkfarm escadrille
|
|
linkfarm patrouille # new St Valentine 2026
|
|
linkfarm remote
|
|
linkfarm panoramic
|
|
linkfarm hexatube
|
|
linkfarm passage
|
|
linkfarm survol
|
|
intersequence 10 "Use Futur;"
|
|
linkfarm essai
|
|
|
|
faire_la_fin
|
|
|
|
ff_encodage Spool the-hexacone-family.mp4
|
|
|
|
nb=$(( $IDX - 1 ))
|
|
echo "linkfarmed $nb files" | tee -a WS/log
|
|
|
|
|
|
|
|
|
|
|