1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

avcodec/mjpegdec: Fix chroma width rounding

Fixes vertical line at the right side
Fixes Ticket 3929

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Clément Bœsch 2014-09-13 20:25:27 +02:00 committed by Michael Niedermayer
parent ceb2fe027f
commit b96d864fd6

View File

@ -2127,7 +2127,7 @@ the_end:
if (!(s->upscale_v & (1<<p)))
continue;
if (p==1 || p==2)
w >>= hshift;
w = FF_CEIL_RSHIFT(w, hshift);
for (i = s->height - 1; i; i--) {
uint8_t *src1 = &((uint8_t *)s->picture_ptr->data[p])[i / 2 * s->linesize[p]];
uint8_t *src2 = &((uint8_t *)s->picture_ptr->data[p])[(i + 1) / 2 * s->linesize[p]];