I saw that FFmpeg can merge/blend two videos with alpha channel and can encode video with alpha channel using the qtrle
codec, but, It is possible to apply a PNG file mask, either a black and white or a PNG with an alpha channel to a video in order to have a video with the alpha channel of the PNG applied?
Here is the concept in images
PNG file with alpha channel, the "mask":
Or even a black and white image as a mask for alpha channel:
Any help would be appreciated, thank you!
Use the alphaextract
and alphamerge
filters:
ffmpeg -i video -vf "movie='image',alphaextract[a];[in][a]alphamerge" -c:v qtrle output.mov