mirror of
https://mirror.skon.top/https://github.com/FFmpeg/FFmpeg
synced 2026-04-21 13:21:55 +08:00
Photoshop documents can contain additional "auxiliary" channels that don't take part in layer compositing, therefore, using the channel count to determine the presence of an alpha channel in the merged image is incorrect. Instead, as per the PSD specification, use the sign of the layer count (present in the layers and masks section) to determine if there is an alpha channel, then determine the number of primary channels using both the presence of the alpha channel and the pixel format.
20 KiB
20 KiB