What a worthless feature *facepalm*
Thank you for wasting 300 seconds life-time, M$-Devs*!
ps. I know this is a decision of design, so not to blame the devs but the designers ..
Procrasticoding: annotate animated GIFs (or even add a picture/watermark)
The sun rose, the cats were watching the birds on the windowsill and at first I just wanted to take a cute picture of them sitting soo close, but then I had another inspiration ..
0. Prepared the logo from some internetsearch; stripped of colors, converted to 3-color-GIF with transparency: all done by GIMP and some magic.
1. converted the video to GIF with greyscaling and resizing
2. merged the two pictures while optimizing the layers and applying some contrast
1 2 3 |
ffmpeg -i VID_20160420_061216.mp4 -vf scale=320:180 -strict -2 -vf format=gray video_gray.mp4 && \ ffmpeg -i video_gray.mp4 -t 3 -b:v 1024k -vf scale="320x180" gray320.gif && \ convert gray320.gif -contrast -coalesce -gravity SouthWest -draw 'image Over 0,0 0,0 "leben2.gif"' -layers Optimize combined320.gif |
BTW: sometimes empty phrase-error messages spark my fury … “convert.im6: non-conforming drawing primitive definition `image’ @ error/draw.c/DrawImage/3158.
” … and what does this tell me now?!?
But at least I am not the first one who understood nothing! Thank you.
doEis.sh: convert all negatives via negfix8
reason: too lazy to call the negfix8-script for each file itself. Because conversion is fast but even with an SSD writing the ~120 MiByte files takes some time. Precious time ..
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
#!/bin/bash # author: Marcel Petrick (mail@marcelpetrick.it) # date: 20160415 # license: GNU General Public License, version 2 ( http://www.gnu.org/licenses/old-licenses/gpl-2.0.en.html ) echo "############################ start of the script ############################" #handle the issue with filenames with spaces SAVEIFS=$IFS IFS=$(echo -en "\n\b") #needed for the call of negfix8 SKRIPTDIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) ALLFILES=`ls *.tif` #get all files inside the current folder which fit by suffix WORKINGDIR="negfix8Output" #todo: maybe add a check if the directory already existed .. mkdir $WORKINGDIR for FILE in $ALLFILES do CLEANEDNAME="${FILE// /_}" #also alter the original-input-name by replacing all spaces echo "will work now on #$FILE# and save as #$CLEANEDNAME#" #print current file name FULLPATH=$WORKINGDIR"/"$CLEANEDNAME".png" #convert /bin/bash $SKRIPTDIR/negfix8.sh -cs $FILE $FULLPATH done printf "############################ end of the script ############################\n" |
ps. ‘do eis’ is latin, not some german-english mumble jumble.
expert-systems: a working example
Most of the time I just add more rants using this tag. But for now I have found a really decent and hugely uselful example of an expert-system: determine plant names.
The examples presented in school and university were most of the time really stilted. You got the idea behind, but you doubted someone would really implement it this way ..
Video to *good* GIF
You can use a crappy app or some webservice … or DIY!
1 |
$ ffmpeg -t 3 -ss 00:00:04 -i INPUTVIDEO.mp4 -b:v 2048k -vf scale="500x281" OUTPUT.gif |
read: start at second 4 with length 3, use high quality-conversion, downscale (because scaling with ‘convert’ will result in artifacts because of the color-indexing), out-filename
If some rotation is needed (-vf “transpose=2” is also an option, but the quality suffered), add it afterwards via convert.
1 |
$ convert -rotate 270 OUTPUT.gif OUTPUT_rot.gif |