]> git.sesse.net Git - ffmpeg/commitdiff
avcodec/libvpxenc: fix alpha stride
authorMarton Balint <cus@passwd.hu>
Sun, 27 Oct 2019 17:10:31 +0000 (18:10 +0100)
committerJames Zern <jzern@google.com>
Wed, 6 Nov 2019 07:14:24 +0000 (23:14 -0800)
Signed-off-by: Marton Balint <cus@passwd.hu>
Signed-off-by: James Zern <jzern@google.com>
libavcodec/libvpxenc.c

index 286baa14a78f39478d634640253faf73ed88db19..4c02315fd29b356b1d4a54b688481066e86bf463 100644 (file)
@@ -1326,7 +1326,7 @@ static int vpx_encode(AVCodecContext *avctx, AVPacket *pkt,
             rawimg_alpha->planes[VPX_PLANE_U] = u_plane;
             memset(v_plane, 0x80, frame->linesize[2] * frame->height);
             rawimg_alpha->planes[VPX_PLANE_V] = v_plane;
-            rawimg_alpha->stride[VPX_PLANE_Y] = frame->linesize[0];
+            rawimg_alpha->stride[VPX_PLANE_Y] = frame->linesize[3];
             rawimg_alpha->stride[VPX_PLANE_U] = frame->linesize[1];
             rawimg_alpha->stride[VPX_PLANE_V] = frame->linesize[2];
         }