In avfilter_config_links(), if the current channel layout is not specified, set the same value of the previous link in the filterchain. Consistent with the logic used to set the other link parameters.
Unified · Split
| @@ -277,6 +277,8 @@ int avfilter_config_links(AVFilterContext *filter) · 276 unmodified lines | |||
| 277 | link->sample_rate = inlink->sample_rate; | 277 | link->sample_rate = inlink->sample_rate; |
| 278 | if (!link->time_base.num && !link->time_base.den) | 278 | if (!link->time_base.num && !link->time_base.den) |
| 279 | link->time_base = inlink->time_base; | 279 | link->time_base = inlink->time_base; |
| 280 | if (!link->channel_layout) | ||
| 281 | link->channel_layout = inlink->channel_layout; | ||
| 280 | } else if (!link->sample_rate) { | 282 | } else if (!link->sample_rate) { |
| 281 | av_log(link->src, AV_LOG_ERROR, | 283 | av_log(link->src, AV_LOG_ERROR, |
| 282 | "Audio source filters must set their output link's " | 284 | "Audio source filters must set their output link's " |