Unified · Split
| @@ -88,23 +88,6 @@ static const AVOption asoftclip_options[] = { · 87 unmodified lines | |||
| 88 | 88 | ||
| 89 | AVFILTER_DEFINE_CLASS(asoftclip); | 89 | AVFILTER_DEFINE_CLASS(asoftclip); |
| 90 | 90 | ||
| 91 | static int query_formats(AVFilterContext *ctx) | ||
| 92 | { | ||
| 93 | static const enum AVSampleFormat sample_fmts[] = { | ||
| 94 | AV_SAMPLE_FMT_FLTP, AV_SAMPLE_FMT_DBLP, | ||
| 95 | AV_SAMPLE_FMT_NONE | ||
| 96 | }; | ||
| 97 | int ret = ff_set_common_formats_from_list(ctx, sample_fmts); | ||
| 98 | if (ret < 0) | ||
| 99 | return ret; | ||
| 100 | |||
| 101 | ret = ff_set_common_all_channel_counts(ctx); | ||
| 102 | if (ret < 0) | ||
| 103 | return ret; | ||
| 104 | |||
| 105 | return ff_set_common_all_samplerates(ctx); | ||
| 106 | } | ||
| 107 | |||
| 108 | static void get_lowpass(Lowpass *s, | 91 | static void get_lowpass(Lowpass *s, |
| 109 | double frequency, | 92 | double frequency, |
| 110 | double sample_rate) | 93 | double sample_rate) |
| @@ -504,7 +487,7 @@ const AVFilter ff_af_asoftclip = { · 393 unmodified lines | |||
| 504 | .priv_class = &asoftclip_class, | 487 | .priv_class = &asoftclip_class, |
| 505 | FILTER_INPUTS(inputs), | 488 | FILTER_INPUTS(inputs), |
| 506 | FILTER_OUTPUTS(outputs), | 489 | FILTER_OUTPUTS(outputs), |
| 507 | FILTER_QUERY_FUNC(query_formats), | 490 | FILTER_SAMPLEFMTS(AV_SAMPLE_FMT_FLTP, AV_SAMPLE_FMT_DBLP), |
| 508 | .uninit = uninit, | 491 | .uninit = uninit, |
| 509 | .process_command = ff_filter_process_command, | 492 | .process_command = ff_filter_process_command, |
| 510 | .flags = AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC | | 493 | .flags = AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC | |