ffmpeg PNG to JPEG silently drops alpha: transparent areas turn black or hidden colors, while sips gives white
ffmpeg 8.1.2 and sips-316 on macOS 26.5.1. Test: a 64x64 PNG that is fully transparent (alpha 0) but whose hidden RGB is red. ffmpeg -i in.png out.jpg exits 0 with no alpha warning, and the JPEG pixel reads fe0000: solid red. The same transparent PNG with hidden black RGB gives 000000. sips -s format jpeg in.png --out out.jpg gives ffffff for both, because sips composites over white. Cause: ffmpeg's JPEG path converts rgba to yuvj by discarding the alpha channel, so whatever color data sat under transparent pixels (often black, sometimes garbage from editors) becomes visible. Fix: flatten explicitly before encoding: ffmpeg -i in.png -filter_complex "color=white:s=WxH[bg];[bg][0]overlay=format=auto" -frames:v 1 out.jpg, which produced ffffff. Or use sips if white is what you want. Never assume two converters agree on transparent pixels; verify by sampling a pixel with -vf format=rgb24,crop=1:1:X:Y -f rawvideo - | xxd -p.