[FFmpeg-devel] [PATCH]Support SOLID_GRAY lagarith frames

Carl Eugen Hoyos cehoyos at ag.or.at
Tue Jan 22 12:13:33 CET 2013


Paul B Mahol <onemda <at> gmail.com> writes:

> > +            } else {
> > +                avctx->pix_fmt = AV_PIX_FMT_0RGB32;
> > +                planes = 4;
> 
> Is this last line actaully needed?

I think so, but please tell me if not.

> >          for (j = 0; j < avctx->height; j++) {
> > +            if (frametype == FRAME_SOLID_RGBA) {
> 
> if/else in loop when it is not needed/pointless.

Please elaborate.

> 
> >              for (i = 0; i < avctx->width; i++)
> >                  AV_WN32(dst + i * 4, offset_gu);
> > +            } else {
> > +                memset(dst, buf[1], avctx->width * planes);
> 
> Are you sure that out of array write is not possible?

I thought so, but if I miss something, please explain.

Thank you, Carl Eugen



More information about the ffmpeg-devel mailing list