summaryrefslogtreecommitdiff
path: root/libavfilter/vf_colormatrix.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavfilter/vf_colormatrix.c')
-rw-r--r--libavfilter/vf_colormatrix.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/vf_colormatrix.c b/libavfilter/vf_colormatrix.c
index cec0e3a96b..78d1bad217 100644
--- a/libavfilter/vf_colormatrix.c
+++ b/libavfilter/vf_colormatrix.c
@@ -416,7 +416,7 @@ static int filter_frame(AVFilterLink *link, AVFrame *in)
FFMIN(in->height, ctx->graph->nb_threads));
else if (in->format == AV_PIX_FMT_YUV420P)
ctx->internal->execute(ctx, process_slice_yuv420p, &td, NULL,
- FFMIN(in->height, ctx->graph->nb_threads));
+ FFMAX(1, FFMIN(in->height, ctx->graph->nb_threads) & ~1));
else
ctx->internal->execute(ctx, process_slice_uyvy422, &td, NULL,
FFMIN(in->height, ctx->graph->nb_threads));