AVFilterLink.frame_count is supposed to count the number of frames
that were passed on the link, but with min_samples, that number is
not always the same for the source and destination filters.
With the addition of a FIFO on the link, the difference will become
more significant.
Split the variable in two: frame_count_in counts the number of
frames that entered the link, frame_count_out counts the number
of frames that were sent to the destination filter.
av_log(ctx,AV_LOG_ERROR,"Out of range frames %"PRId64" and/or %"PRId64" on line %"PRId64" for %"PRId64". input frame.\n",tf,bf,s->line,inlink->frame_count);
av_log(ctx,AV_LOG_ERROR,"Out of range frames %"PRId64" and/or %"PRId64" on line %"PRId64" for %"PRId64". input frame.\n",tf,bf,s->line,inlink->frame_count_out);
returnAVERROR_INVALIDDATA;
}
break;
case1:
if(tf>1||tf<-1||
bf>1||bf<-1){
av_log(ctx,AV_LOG_ERROR,"Out of range %"PRId64" and/or %"PRId64" on line %"PRId64" for %"PRId64". input frame.\n",tf,bf,s->line,inlink->frame_count);
av_log(ctx,AV_LOG_ERROR,"Out of range %"PRId64" and/or %"PRId64" on line %"PRId64" for %"PRId64". input frame.\n",tf,bf,s->line,inlink->frame_count_out);
returnAVERROR_INVALIDDATA;
}
};
break;
}else{
av_log(ctx,AV_LOG_ERROR,"Missing entry for %"PRId64". input frame.\n",inlink->frame_count);
av_log(ctx,AV_LOG_ERROR,"Missing entry for %"PRId64". input frame.\n",inlink->frame_count_out);
returnAVERROR_INVALIDDATA;
}
}
@ -174,8 +174,8 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)