[FFmpeg-cvslog] avcodec/mjpegdec: use the AVFrame width/height for flipping

Michael Niedermayer git at videolan.org
Thu Jan 9 21:46:48 CET 2014


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Thu Jan  9 21:30:49 2014 +0100| [7c3700cd1d8683966b21fffbf02e326d0bd14e06] | committer: Michael Niedermayer

avcodec/mjpegdec: use the AVFrame width/height for flipping

This makes it possible to use the code with lowres

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=7c3700cd1d8683966b21fffbf02e326d0bd14e06
---

 libavcodec/mjpegdec.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c
index f7e0745..676f741 100644
--- a/libavcodec/mjpegdec.c
+++ b/libavcodec/mjpegdec.c
@@ -2005,8 +2005,8 @@ the_end:
         avcodec_get_chroma_sub_sample(s->avctx->pix_fmt, &hshift, &vshift);
         for (index=0; index<4; index++) {
             uint8_t *dst = s->picture_ptr->data[index];
-            int w = s->width;
-            int h = s->height;
+            int w = s->picture_ptr->width;
+            int h = s->picture_ptr->height;
             if(index && index<3){
                 w = FF_CEIL_RSHIFT(w, hshift);
                 h = FF_CEIL_RSHIFT(h, vshift);



More information about the ffmpeg-cvslog mailing list