summaryrefslogtreecommitdiff
path: root/libswscale/utils.c
diff options
context:
space:
mode:
authorRonald S. Bultje <rsbultje@gmail.com>2011-07-08 14:52:52 -0700
committerMichael Niedermayer <michaelni@gmx.at>2011-07-11 03:51:46 +0200
commitac9ac45aca7d3114dc790f794b49f066b4178827 (patch)
treec7cbdad529627429c8837dacc2488aae12b79681 /libswscale/utils.c
parent08b57574c6a1bde51576f42546b7b9f8c03f9297 (diff)
swscale: fix 16-bit scaling when output is 8-bits.
We would use the second half of the U plane buffer, rather than the V plane buffer, to output the V plane pixels.
Diffstat (limited to 'libswscale/utils.c')
-rw-r--r--libswscale/utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libswscale/utils.c b/libswscale/utils.c
index 3e1662716b..00bd89f78b 100644
--- a/libswscale/utils.c
+++ b/libswscale/utils.c
@@ -1052,7 +1052,7 @@ int sws_init_context(SwsContext *c, SwsFilter *srcFilter, SwsFilter *dstFilter)
for (i=0; i<c->vChrBufSize; i++) {
FF_ALLOC_OR_GOTO(c, c->chrUPixBuf[i+c->vChrBufSize], dst_stride*2+1, fail);
c->chrUPixBuf[i] = c->chrUPixBuf[i+c->vChrBufSize];
- c->chrVPixBuf[i] = c->chrVPixBuf[i+c->vChrBufSize] = c->chrUPixBuf[i] + (dst_stride>>1);
+ c->chrVPixBuf[i] = c->chrVPixBuf[i+c->vChrBufSize] = c->chrUPixBuf[i] + (dst_stride >> 1);
}
if (CONFIG_SWSCALE_ALPHA && c->alpPixBuf)
for (i=0; i<c->vLumBufSize; i++) {