avfilter/vf_scdet: change threshold checking

Also allow score to match threshold thus allowing ==0.0 scores.
This commit is contained in:
Paul B Mahol 2023-01-17 18:01:02 +01:00
parent 11b02fc675
commit 07485a6975

View File

@ -163,7 +163,7 @@ static int activate(AVFilterContext *ctx)
snprintf(buf, sizeof(buf), "%0.3f", s->scene_score);
set_meta(s, frame, "lavfi.scd.score", buf);
if (s->scene_score > s->threshold) {
if (s->scene_score >= s->threshold) {
av_log(s, AV_LOG_INFO, "lavfi.scd.score: %.3f, lavfi.scd.time: %s\n",
s->scene_score, av_ts2timestr(frame->pts, &inlink->time_base));
set_meta(s, frame, "lavfi.scd.time",