Commit 1f1ef843 authored by Michael Niedermayer's avatar Michael Niedermayer

avfilter/vf_perspective: Use av_clip_uint8()

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 6660c598
......@@ -320,7 +320,7 @@ static int resample_cubic(AVFilterContext *ctx, void *arg,
}
sum = (sum + (1<<(COEFF_BITS * 2 - 1))) >> (COEFF_BITS * 2);
sum = av_clip(sum, 0, 255);
sum = av_clip_uint8(sum);
dst[x + y * dst_linesize] = sum;
}
}
......@@ -395,7 +395,7 @@ static int resample_linear(AVFilterContext *ctx, void *arg,
}
}
sum = av_clip(sum, 0, 255);
sum = av_clip_uint8(sum);
dst[x + y * dst_linesize] = sum;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment