]> git.sesse.net Git - ffmpeg/commitdiff
mpegvideo: Return correct coded frame sizes from parser
authorMark Thompson <sw@jkqxz.net>
Wed, 26 Oct 2016 19:28:18 +0000 (20:28 +0100)
committerMark Thompson <sw@jkqxz.net>
Mon, 31 Oct 2016 19:23:40 +0000 (19:23 +0000)
libavcodec/mpegvideo_parser.c

index 206f268a7857a6198d8e7514b9e86e70828e9276..de70cd5632da975c8e888535cff30697d0f559b6 100644 (file)
@@ -168,8 +168,10 @@ static void mpegvideo_extract_headers(AVCodecParserContext *s,
 
     if (pix_fmt != AV_PIX_FMT_NONE) {
         s->format = pix_fmt;
-        s->width  = s->coded_width  = pc->width;
-        s->height = s->coded_height = pc->height;
+        s->width  = pc->width;
+        s->height = pc->height;
+        s->coded_width  = FFALIGN(pc->width,  16);
+        s->coded_height = FFALIGN(pc->height, 16);
     }
 
 #if FF_API_AVCTX_TIMEBASE