avutil/imgutils: do not ignore align parameter for pseudo-pal in av_image_get_buffer_...
authorMichael Niedermayer <michael@niedermayer.cc>
Sat, 13 Feb 2016 14:32:57 +0000 (15:32 +0100)
committerMichael Niedermayer <michael@niedermayer.cc>
Sat, 13 Feb 2016 15:22:45 +0000 (16:22 +0100)
Reviewed-by: Stefano Sabatini <stefasab@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavutil/imgutils.c

index 3320664..5c28703 100644 (file)
@@ -370,7 +370,7 @@ int av_image_get_buffer_size(enum AVPixelFormat pix_fmt,
 
     // do not include palette for these pseudo-paletted formats
     if (desc->flags & AV_PIX_FMT_FLAG_PSEUDOPAL)
-        return width * height;
+        return FFALIGN(width, align) * height;
 
     return av_image_fill_arrays(data, linesize, NULL, pix_fmt,
                                 width, height, align);