optimize for bbq

This commit is contained in:
tTh 2024-01-30 13:32:43 +01:00
parent ad82a68039
commit 6eac66c818

View File

@ -7,10 +7,10 @@
INCFILE="WS/bloubs.inc" INCFILE="WS/bloubs.inc"
TMPPNG="/dev/shm/bloubs7.png" TMPPNG="/dev/shm/bloubs7.png"
POVOPT="+Q9 +a -v -d -W800 -H600 -WT2" POVOPT="+Q9 +a -v -d -W1024 -H768 -WT2"
DDIR="frames/a" DDIR="frames/a"
LOGERR="log.error" LOGERR="log.error"
TXTCOLOR="#db2080" TXTCOLOR="#db4090"
BLOUBDATAS="WS/bloubs.data" BLOUBDATAS="WS/bloubs.data"
BARYDATAS="WS/log.barycentres" BARYDATAS="WS/log.barycentres"
@ -34,12 +34,12 @@ printf "\n#declare NbImg = %d;\n" $NBIMG > WS/nbimg.inc
# first, we have to make a seminal buch of bloubs # first, we have to make a seminal buch of bloubs
# --> this function need to be parametrizable # --> this function need to be parametrizable
# #
./genbloubs ${BLBS_IN} 97 ./genbloubs ${BLBS_IN} 666
for idx in $(seq 0 $((NBIMG-1)) ) for idx in $(seq 0 $((NBIMG-1)) )
do do
echo "============== run passe $idx ====================" echo "================= run passe $idx ===================="
# make the bloubs's data readable by POVray # make the bloubs's data readable by POVray
# #
@ -55,21 +55,20 @@ do
sleep 90 sleep 90
fi fi
td=$(date -u +'%F %R:%S' | tr '01' 'ol') td=$(date -u +'%F %R' | tr '01' 'ol')
hi=$(printf "#%04d" $idx | tr '01' 'ol') hi=$(printf "#%04d" $idx | tr '01' 'ol')
count=$(tail -1 "WS/log.nb_bloubs") count=$(tail -1 "WS/log.nb_bloubs" | tr '01' 'ol')
PNG=$(printf "%s/%05d.png" ${DDIR} $idx) PNG=$(printf "%s/%05d.png" ${DDIR} $idx)
convert ${TMPPNG} \ convert ${TMPPNG} \
-font Courier-Bold \ -font Courier-Bold \
-pointsize 22 \ -pointsize 32 \
-fill "$TXTCOLOR" \ -fill "$TXTCOLOR" \
-gravity south-east \ -gravity south-east \
-annotate +25+5 "$td" \ -annotate +25+5 "$td" \
-gravity south-west \ -gravity south-west \
-annotate +25+5 "$hi" \ -annotate +25+5 "$hi" \
-pointsize 28 \
-gravity north-east \ -gravity north-east \
-annotate +45+5 "$count" \ -annotate +45+5 "$count" \
-gravity north-west \ -gravity north-west \
@ -83,7 +82,7 @@ do
# mv ${BLBS_OUT} ${BLBS_IN} # mv ${BLBS_OUT} ${BLBS_IN}
echo "### run done" echo "### run done"
sleep 10 sleep 5
done done