Lines Matching defs:aconvert
53 AVFILTER_DEFINE_CLASS(aconvert);
57 AConvertContext *aconvert = ctx->priv;
62 aconvert->out_sample_fmt = AV_SAMPLE_FMT_NONE;
63 aconvert->out_chlayout = 0;
65 if (aconvert->format_str && strcmp(aconvert->format_str, "auto") &&
66 (ret = ff_parse_sample_format(&aconvert->out_sample_fmt, aconvert->format_str, ctx)) < 0)
68 if (aconvert->channel_layout_str && strcmp(aconvert->channel_layout_str, "auto"))
69 return ff_parse_channel_layout(&aconvert->out_chlayout, NULL, aconvert->channel_layout_str, ctx);
75 AConvertContext *aconvert = ctx->priv;
76 swr_free(&aconvert->swr);
82 AConvertContext *aconvert = ctx->priv;
89 if (aconvert->out_sample_fmt != AV_SAMPLE_FMT_NONE) {
91 ff_add_format(&formats, aconvert->out_sample_fmt);
99 if (aconvert->out_chlayout != 0) {
101 ff_add_channel_layout(&layouts, aconvert->out_chlayout);
115 AConvertContext *aconvert = ctx->priv;
119 if (aconvert->out_sample_fmt == AV_SAMPLE_FMT_NONE)
120 aconvert->out_sample_fmt = outlink->format;
121 if (aconvert->out_chlayout == 0)
122 aconvert->out_chlayout = outlink->channel_layout;
124 aconvert->swr = swr_alloc_set_opts(aconvert->swr,
125 aconvert->out_chlayout, aconvert->out_sample_fmt, inlink->sample_rate,
128 if (!aconvert->swr)
130 ret = swr_init(aconvert->swr);
148 AConvertContext *aconvert = inlink->dst->priv;
156 swr_convert(aconvert->swr, outsamplesref->extended_data, n,
187 .name = "aconvert",