[FFmpeg-devel] [PATCH]lavc/flicvideo: Implement padding in COPY chunks.

Reimar Döffinger Reimar.Doeffinger at gmx.de
Fri Mar 25 18:55:45 CET 2016


On Thu, Mar 24, 2016 at 01:40:07AM +0100, Carl Eugen Hoyos wrote:
> @@ -432,6 +432,8 @@ static int flic_decode_frame_8BPP(AVCodecContext *avctx,
>                       y_ptr += s->frame->linesize[0]) {
>                      bytestream2_get_buffer(&g2, &pixels[y_ptr],
>                                             s->avctx->width);
> +                    if (s->avctx->width & 3)
> +                        bytestream2_skip(&g2, 4 - (s->avctx->width & 3));

Maybe it's more reliable/clear to keep like that, but I think
this could also be written as
bytestream2_skip(&g2, -s->avctx->width & 3);
Should be fine otherwise I think.


More information about the ffmpeg-devel mailing list