[Libav-user] How to retrieve cover arts from mp4 or mkv files

cyril apan cyrilapan at yahoo.fr
Sat Aug 25 20:20:35 CEST 2012


Hi there,

Can anybody show me a sample on the best way to retrieve cover arts from mp4 or mkv files using libav?
I found out that the AVStream structure has a AVPacket attached_pic field, but also that the streams field of the AVFormatContext structure can contain a stream of type AVMEDIA_TYPE_ATTACHMENT.
I'm not sure to see what's the difference of use between both, but at the end I want to get a bitmap of the cover art or the pîcture in its original format and what is the format (if it's jpeg, gif, png or something else).

Thanks for the help.

Cyril.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20120825/6c7b5853/attachment.html>


More information about the Libav-user mailing list