I received the file “transparent flame video.mov”. This has the codec Quicktime Animation (qtrle in FFmpeg). It appears to have alpha premultiplied against the RGB color components. I could make it work better by adding code to MLT to un-premultiply, but I have to add a test if the pixel format contains alpha and preferably whether it is premultiplied or straight. While working on that, I came across the AVPixFmtDescriptor API, which has a flag to indicate if alpha is available. However, the docs for that flag say “The alpha is always straight, never pre-multiplied.” There is nothing else in FFmpeg APIs to read whether alpha is premultiplied or straight.
While searching the Web about this issue, it seems programs like After Effects give people the option to choose premultiplied or straight at render/export time. However, it is not clear there is any signaling for this in the bitstream or mov file based on information provided by MediaInfo, Quicktime player’s info dialog, or reading mov.c and qtrle.c source code in FFmpeg. The qtrle code simply uncompresses the bytes and supplies them as-is. Therefore, it is not correct to assume it is premutiplied and to un-premultiply whenever there is alpha. In fact, I have a PNG MOV with alpha, and PNG is always supposed to be straight alpha. Therefore, the only solution for video files is to add an un-premultiply filter that a user can add.