diff options
author | Nicolas George <nicolas.george@normalesup.org> | 2013-03-14 19:52:59 +0100 |
---|---|---|
committer | Nicolas George <nicolas.george@normalesup.org> | 2013-03-17 11:59:51 +0100 |
commit | 3cd342636fa245185fce7f4d6709a7a954f05ef8 (patch) | |
tree | 064b777eff466b31378e39059ad9a7c6f137fb07 | |
parent | 9f95e355be16150a2bc00145d5a72e2a5e017b29 (diff) | |
download | ffmpeg-3cd342636fa245185fce7f4d6709a7a954f05ef8.tar.gz |
lavfi/buffersrc: set channel layout if it is known.
Introduced in 01649c7, lost in the API change.
-rw-r--r-- | libavfilter/buffersrc.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavfilter/buffersrc.c b/libavfilter/buffersrc.c index 54a58fe1e9..af66130255 100644 --- a/libavfilter/buffersrc.c +++ b/libavfilter/buffersrc.c @@ -134,6 +134,9 @@ static int attribute_align_arg av_buffersrc_add_frame_internal(AVFilterContext * frame->format); break; case AVMEDIA_TYPE_AUDIO: + /* For layouts unknown on input but known on link after negotiation. */ + if (!frame->channel_layout) + frame->channel_layout = s->channel_layout; CHECK_AUDIO_PARAM_CHANGE(ctx, s, frame->sample_rate, frame->channel_layout, frame->format); break; |