zshrc: correct ffdiff colors

this avoids having the gray background for no motion
This commit is contained in:
xfnw 2023-12-28 21:47:38 -05:00
parent 64084403fa
commit 8069cfcdf2
1 changed files with 1 additions and 1 deletions

2
.zshrc
View File

@ -7,7 +7,7 @@ calcpi() { echo "scale=$1; 16*a(1/5)-4*a(1/239)" | bc -l ; }
calcbd() { echo "h=sqrt($1*2*l(2))+1; scale=0; h/1" | bc -l ; }
vhsify() { ffmpeg -i "$1" -vf fps=24,scale="(iw*sar)*max(640/(iw*sar)\,480/ih):ih*max(640/(iw*sar)\,480/ih)",crop=640:480,setsar=1:1,convolution="-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2:-2 -1 0 -1 1 1 0 1 2",curves="0/0 0.5/0.58 1/1",rgbashift=rh=-1:gh=1 -preset veryfast -c:a copy "$2" ; }
deshake() { ffmpeg -i "$1" -vf "format=rgb24,split[a][b];[a]deshake=rx=64:ry=64:edge=0,colorkey=0x008000:blend=0:similarity=.2[a];[b]drawbox=color=black:t=fill[b];[b][a]overlay" -c:a copy "$2" ; }
ffdiff() { ffmpeg -i "$1" -c:a "${3:-copy}" -filter_complex "tblend=all_mode=${4:-grainextract},setsar=1" -vsync vfr "$2" ; }
ffdiff() { ffmpeg -i "$1" -c:a "${3:-copy}" -filter_complex "tblend=all_mode=${4:-grainextract},curves=all=0/1 .5/0 1/1,setsar=1" -vsync vfr "$2" ; }
datamosh() { ffmpeg -i "$1" -c copy -bsf:v noise=drop='gt(pts/tb\,30)*key' "$2" ; }
dither() { convert "$1" -filter box -resize 700 -ordered-dither o4x4,2 "$2" ; }
ditherc() { convert "$1" -colorspace RGB -filter box -resize 700 -ordered-dither o4x4,2 -colorspace sRGB "$2" ; }