1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

lavfi: implement ff_all_channel_counts().

This commit is contained in:
Nicolas George 2012-12-26 16:46:43 +01:00
parent b6afb2dde1
commit 7bb98b753b
2 changed files with 16 additions and 1 deletions

View File

@ -376,6 +376,15 @@ AVFilterChannelLayouts *ff_all_channel_layouts(void)
return ret;
}
AVFilterChannelLayouts *ff_all_channel_counts(void)
{
AVFilterChannelLayouts *ret = av_mallocz(sizeof(*ret));
if (!ret)
return NULL;
ret->all_layouts = ret->all_counts = 1;
return ret;
}
#define FORMATS_REF(f, ref) \
do { \
*ref = f; \

View File

@ -123,11 +123,17 @@ AVFilterFormats *ff_merge_samplerates(AVFilterFormats *a,
/**
* Construct an empty AVFilterChannelLayouts/AVFilterFormats struct --
* representing any channel layout/sample rate.
* representing any channel layout (with known disposition)/sample rate.
*/
AVFilterChannelLayouts *ff_all_channel_layouts(void);
AVFilterFormats *ff_all_samplerates(void);
/**
* Construct an AVFilterChannelLayouts coding for any channel layout, with
* known or unknown disposition.
*/
AVFilterChannelLayouts *ff_all_channel_counts(void);
AVFilterChannelLayouts *avfilter_make_format64_list(const int64_t *fmts);