mirror of https://git.ffmpeg.org/ffmpeg.git
swscale: exchange src & dst chroma pos
Found-by: wm4 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
24a4367ae9
commit
436616fd42
|
@ -299,7 +299,7 @@ static av_cold int initFilter(int16_t **outFilter, int32_t **filterPos,
|
|||
FF_ALLOC_OR_GOTO(NULL, filter,
|
||||
dstW * sizeof(*filter) * filterSize, fail);
|
||||
|
||||
xDstInSrc = ((srcPos*xInc)>>8) - ((dstPos*0x8000)>>7);
|
||||
xDstInSrc = ((dstPos*xInc)>>8) - ((srcPos*0x8000)>>7);
|
||||
for (i = 0; i < dstW; i++) {
|
||||
int xx = (xDstInSrc - ((filterSize - 1) << 15) + (1 << 15)) >> 16;
|
||||
|
||||
|
@ -315,7 +315,7 @@ static av_cold int initFilter(int16_t **outFilter, int32_t **filterPos,
|
|||
FF_ALLOC_OR_GOTO(NULL, filter,
|
||||
dstW * sizeof(*filter) * filterSize, fail);
|
||||
|
||||
xDstInSrc = ((srcPos*xInc)>>8) - ((dstPos*0x8000)>>7);
|
||||
xDstInSrc = ((dstPos*xInc)>>8) - ((srcPos*0x8000)>>7);
|
||||
for (i = 0; i < dstW; i++) {
|
||||
int xx = (xDstInSrc - ((filterSize - 1) << 15) + (1 << 15)) >> 16;
|
||||
int j;
|
||||
|
@ -366,7 +366,7 @@ static av_cold int initFilter(int16_t **outFilter, int32_t **filterPos,
|
|||
FF_ALLOC_OR_GOTO(NULL, filter,
|
||||
dstW * sizeof(*filter) * filterSize, fail);
|
||||
|
||||
xDstInSrc = ((srcPos*xInc)>>7) - ((dstPos*0x10000)>>7);
|
||||
xDstInSrc = ((dstPos*xInc)>>7) - ((srcPos*0x10000)>>7);
|
||||
for (i = 0; i < dstW; i++) {
|
||||
int xx = (xDstInSrc - ((filterSize - 2) << 16)) / (1 << 17);
|
||||
int j;
|
||||
|
|
Loading…
Reference in New Issue