summaryrefslogtreecommitdiff
path: root/libswscale/swscale.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-01-19 01:40:10 +0100
committerMichael Niedermayer <michaelni@gmx.at>2013-01-19 02:38:48 +0100
commit8045c0167dbe9779f75d1c23a97f501eca92d33e (patch)
tree25f2b221307934154d0b65eb511cba373c0432a0 /libswscale/swscale.c
parentca447592b18a196ea3fdf9d91e0fe031bfe8b737 (diff)
downloadffmpeg-8045c0167dbe9779f75d1c23a97f501eca92d33e.tar.gz
sws: Only reset dither state for bitexact mode
the output looks better with a random initial state than all 0 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libswscale/swscale.c')
-rw-r--r--libswscale/swscale.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libswscale/swscale.c b/libswscale/swscale.c
index dbe61c7a97..bf0c13013a 100644
--- a/libswscale/swscale.c
+++ b/libswscale/swscale.c
@@ -910,7 +910,7 @@ int attribute_align_arg sws_scale(struct SwsContext *c,
src2[0] = base;
}
- if (!srcSliceY && (c->flags & SWS_ERROR_DIFFUSION))
+ if (!srcSliceY && (c->flags & SWS_BITEXACT) && (c->flags & SWS_ERROR_DIFFUSION))
for (i = 0; i < 4; i++)
memset(c->dither_error[i], 0, sizeof(c->dither_error[0][0]) * (c->dstW+2));