History

avdevice/lavfi: convert to new channel layout API

James Almer committed 5 years ago

Commit 678c1951 parent 1c22a291 file · +5 −2Browse files

Showing the changes to libavdevice (1 of 1 file). Show all

Unified · Split

libavdevice/lavfi.c+5−2
@@ -332,9 +332,12 @@ av_cold static int lavfi_read_header(AVFormatContext *avctx) · 331 unmodified lines
332 st ->sample_aspect_ratio =332 st ->sample_aspect_ratio =
333 par->sample_aspect_ratio = av_buffersink_get_sample_aspect_ratio(sink);333 par->sample_aspect_ratio = av_buffersink_get_sample_aspect_ratio(sink);
334 } else if (par->codec_type == AVMEDIA_TYPE_AUDIO) {334 } else if (par->codec_type == AVMEDIA_TYPE_AUDIO) {
335 par->channels = av_buffersink_get_channels(sink);
336 par->sample_rate = av_buffersink_get_sample_rate(sink);335 par->sample_rate = av_buffersink_get_sample_rate(sink);
337 par->channel_layout = av_buffersink_get_channel_layout(sink);336 ret = av_channel_layout_from_mask(&par->ch_layout, av_buffersink_get_channel_layout(sink));
337 if (ret < 0) {
338 par->ch_layout.nb_channels = av_buffersink_get_channels(sink);
339 par->ch_layout.order = AV_CHANNEL_ORDER_UNSPEC;
340 }
338 par->format = av_buffersink_get_format(sink);341 par->format = av_buffersink_get_format(sink);
339 par->codec_id = av_get_pcm_codec(par->format, -1);342 par->codec_id = av_get_pcm_codec(par->format, -1);
340 if (par->codec_id == AV_CODEC_ID_NONE)343 if (par->codec_id == AV_CODEC_ID_NONE)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t