#!/bin/bash

INTERPOL="$HOME/Prototype/FloatImg/Fonderie/interpolator"

GLOB='G/???[24680]0.fimg'
DDIR='OD'
FILTERS=" -E octotree:cos01 -F classtrial "
STEP=60
MP4="lkg94.mp4"

echo GLOB is "$GLOB"
echo $(ls -1 $GLOB | wc -l) files found

rm    $DDIR/*.png

time $INTERPOL -v -n $FILTERS -S 2 "$GLOB" "$DDIR" $STEP

echo ; echo "encodage de $MP4"

ffmpeg	-nostdin					\
	-loglevel error					\
	-y -r 30 -f image2 -i $DDIR/%05d.png	 	\
        -metadata artist='--[ tTh ]--'                  \
	-c:v libx264 -pix_fmt yuv420p			\
	$MP4

sync
