+#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(59,24,100)
+ AVChannelLayout in_ch_layout;
+ AVFilterContext *fctx = ffilt->fctx;
+ AVFilterLink **links = !fctx->nb_outputs ? 0 : fctx->outputs;
+ av_channel_layout_copy(&in_ch_layout, &links[0]->ch_layout);
+#endif