diff --git a/libavfilter/vf_colormatrix.c b/libavfilter/vf_colormatrix.c index 5ab175b65d..91ca057fd0 100644 --- a/libavfilter/vf_colormatrix.c +++ b/libavfilter/vf_colormatrix.c @@ -37,7 +37,7 @@ #include "libavutil/pixdesc.h" #include "libavutil/avstring.h" -#define NS(n) n < 0 ? (int)(n*65536.0-0.5+DBL_EPSILON) : (int)(n*65536.0+0.5) +#define NS(n) ((n) < 0 ? (int)((n)*65536.0-0.5+DBL_EPSILON) : (int)((n)*65536.0+0.5)) #define CB(n) av_clip_uint8(n) static const double yuv_coeff[4][3][3] = {