summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libavfilter/formats.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/libavfilter/formats.c b/libavfilter/formats.c
index 59ea966424..1d2a51c0af 100644
--- a/libavfilter/formats.c
+++ b/libavfilter/formats.c
@@ -435,11 +435,7 @@ AVFilterFormats *ff_all_formats(enum AVMediaType type)
AVFilterFormats *ret = NULL;
if (type == AVMEDIA_TYPE_VIDEO) {
- const AVPixFmtDescriptor *desc = NULL;
- while ((desc = av_pix_fmt_desc_next(desc))) {
- if (ff_add_format(&ret, av_pix_fmt_desc_get_id(desc)) < 0)
- return NULL;
- }
+ return ff_formats_pixdesc_filter(0, 0);
} else if (type == AVMEDIA_TYPE_AUDIO) {
enum AVSampleFormat fmt = 0;
while (av_get_sample_fmt_name(fmt)) {