Browse Source

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>
tags/n1.2
Michael Niedermayer 12 years ago
parent
commit
8045c0167d
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libswscale/swscale.c

+ 1
- 1
libswscale/swscale.c View File

@@ -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));



Loading…
Cancel
Save