[FFmpeg-devel] [PATCH] pictordec: decode 1bpp / 4bpp images when extra header marker is missing

Michael Niedermayer michaelni at gmx.at
Mon Oct 29 21:32:11 CET 2012


On Tue, Oct 30, 2012 at 06:08:24AM +1100, Peter Ross wrote:
> On Mon, Oct 29, 2012 at 06:43:42PM +0100, Piotr Bandurski wrote:
> > based on 56f6628bca66ef3b6a1028fcf0f52dbe01115d89
> > 
> > samples:
> > 
> > http://www.datafilehost.com/download-94b5bc1b.html
> 
> > diff --git a/libavcodec/pictordec.c b/libavcodec/pictordec.c
> > index ad8eae0..5c872c9 100644
> > --- a/libavcodec/pictordec.c
> > +++ b/libavcodec/pictordec.c
> > @@ -133,7 +133,7 @@ static int decode_frame(AVCodecContext *avctx,
> >          return AVERROR_INVALIDDATA;
> >      }
> >  
> > -    if (bytestream2_peek_byte(&s->g) == 0xFF || bpp == 8) {
> > +    if (bytestream2_peek_byte(&s->g) == 0xFF || bpp == 1 || bpp == 4 || bpp == 8) {
> >          bytestream2_skip(&s->g, 2);
> >          etype = bytestream2_get_le16(&s->g);
> >          esize = bytestream2_get_le16(&s->g);
> 
> Patch tested. Looks good.

applied

thanks

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The misfortune of the wise is better than the prosperity of the fool.
-- Epicurus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20121029/0e28e3d4/attachment.asc>


More information about the ffmpeg-devel mailing list