50 #define OFFSET(x) offsetof(ASyncContext, x)
51 #define A AV_OPT_FLAG_AUDIO_PARAM
52 #define F AV_OPT_FLAG_FILTERING_PARAM
55 {
"min_delta",
"Minimum difference between timestamps and audio data "
56 "(in seconds) to trigger padding/trimmin the data.",
OFFSET(min_delta_sec),
AV_OPT_TYPE_FLOAT, { .dbl = 0.1 }, 0, INT_MAX,
A|
F },
57 {
"max_comp",
"Maximum compensation in samples per second.",
OFFSET(max_comp),
AV_OPT_TYPE_INT, { .i64 = 500 }, 0, INT_MAX,
A|
F },
153 buf->
linesize[0], nb_samples, NULL, 0, 0);
209 out_size = av_clipl_int32((int64_t)out_size + delta);
216 if (comp != s->
comp) {
237 int planes = planar ? nb_channels : 1;
244 nb_channels, buf->
format);
246 for (ch = 0; ch < planes; ch++)
251 for (ch = 0; ch < planes; ch++)
258 delta, nb_channels, buf->
format);
276 if (new_pts > s->
pts) {
320 .priv_class = &asyncts_class,
322 .
inputs = avfilter_af_asyncts_inputs,
323 .
outputs = avfilter_af_asyncts_outputs,