[FFmpeg-cvslog] Fixing a stride issue in VP8 Alpha encode
Vignesh Venkatasubramanian
git at videolan.org
Wed Jul 17 13:58:20 CEST 2013
ffmpeg | branch: master | Vignesh Venkatasubramanian <vigneshv at google.com> | Tue Jul 16 13:44:56 2013 -0700| [33968c201cc8194864b2bb2bc7c3f0867d775e02] | committer: Michael Niedermayer
Fixing a stride issue in VP8 Alpha encode
When encoding alpha channel in libvpx, the stride isn't set
properly for the alpha encoder. Fixing it.
Signed-off-by: Vignesh Venkatasubramanian <vigneshv at google.com>
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=33968c201cc8194864b2bb2bc7c3f0867d775e02
---
libavcodec/libvpxenc.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/libavcodec/libvpxenc.c b/libavcodec/libvpxenc.c
index f5506f7..5f3c32a 100644
--- a/libavcodec/libvpxenc.c
+++ b/libavcodec/libvpxenc.c
@@ -667,6 +667,9 @@ static int vp8_encode(AVCodecContext *avctx, AVPacket *pkt,
v_plane = av_malloc(frame->linesize[2] * frame->height);
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_U] = frame->linesize[1];
+ rawimg_alpha->stride[VPX_PLANE_V] = frame->linesize[2];
}
timestamp = frame->pts;
if (frame->pict_type == AV_PICTURE_TYPE_I)
More information about the ffmpeg-cvslog
mailing list