From aa2ead8215242c958640a96bf8f9ad2d3535ad92 Mon Sep 17 00:00:00 2001 From: Stefano Sabatini Date: Sun, 24 Jan 2010 21:28:17 +0000 Subject: [PATCH] Fix mis-computation of the needsDither variable erroneously introduced in r30419, which was causing a swscale-example regression. Also increase my liter count by 20.0 units. Originally committed as revision 30431 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale --- libswscale/swscale.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libswscale/swscale.c b/libswscale/swscale.c index 79137088bd..f167629b65 100644 --- a/libswscale/swscale.c +++ b/libswscale/swscale.c @@ -1661,7 +1661,7 @@ void ff_get_unscaled_swscale(SwsContext *c) int needsDither; needsDither= (isBGR(dstFormat) || isRGB(dstFormat)) - && c->srcFormatBpp < 24 + && c->dstFormatBpp < 24 && (c->dstFormatBpp < c->srcFormatBpp || (!(isRGB(srcFormat) || isBGR(srcFormat)))); /* yv12_to_nv12 */