On 11/01/2019 06:17, Peter Ross wrote: > the same algorithm exists in libavcodec/mjpegdec.c, with alpha channel support. > i guess it is trivial enough to be duplicated here. Is it worth deduplicating? Plenty of image formats have CMYK. - Derek