targets=(obelique_curves.0001 obelique_curves.0050 obelique_curves.0205 obelique_particles.0001 obelique_particles.0050 obelique_particles.0205)
color=white
for target in ${targets[@]}
do
    echo "convert $target.png to $target.jpg"
    
    convert $target.png -background $color -flatten -alpha off $target.jpg

    # ffmpeg -y -i $target$j.png -filter_complex "color=white,format=rgb24[c];[c][0]scale2ref[c][i];[c][i]overlay=format=auto:shortest=1,setsar=1" ${target}W$j.png
    # convert ${target}W$j.png ${target}.jpg
done