From: Stefano Sabatini Date: Sat, 16 Jan 2010 19:11:03 +0000 (+0000) Subject: Simplify code in sws_getContext() which logs if the destination format X-Git-Tag: v0.6~1891 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a9e2878c48005eea2d7e7e285af5101608b79b43;p=platform%2Fupstream%2Flibav.git Simplify code in sws_getContext() which logs if the destination format support dithering, remove the const char *dither variable and use a literal string instead. Originally committed as revision 30329 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale --- diff --git a/libswscale/swscale.c b/libswscale/swscale.c index 612b250..dc97389 100644 --- a/libswscale/swscale.c +++ b/libswscale/swscale.c @@ -2809,11 +2809,6 @@ SwsContext *sws_getContext(int srcW, int srcH, enum PixelFormat srcFormat, int d assert(c->chrDstH <= dstH); if (flags&SWS_PRINT_INFO) { -#ifdef DITHER1XBPP - const char *dither= " dithered"; -#else - const char *dither= ""; -#endif if (flags&SWS_FAST_BILINEAR) av_log(c, AV_LOG_INFO, "FAST_BILINEAR scaler, "); else if (flags&SWS_BILINEAR) @@ -2841,7 +2836,11 @@ SwsContext *sws_getContext(int srcW, int srcH, enum PixelFormat srcFormat, int d av_log(c, AV_LOG_INFO, "from %s to%s %s ", sws_format_name(srcFormat), - dstFormat == PIX_FMT_BGR555 || dstFormat == PIX_FMT_BGR565 ? dither : "", +#ifdef DITHER1XBPP + dstFormat == PIX_FMT_BGR555 || dstFormat == PIX_FMT_BGR565 ? " dithered" : "", +#else + "", +#endif sws_format_name(dstFormat)); if (flags & SWS_CPU_CAPS_MMX2)