#include "avfilter.h"Go to the source code of this file.
ff_all_*() lists. More... Encode a channel count as a channel layout.
FF_COUNT2LAYOUT(c) means any channel layout with c channels, with a known or unknown disposition. The result is only valid inside AVFilterChannelLayouts and immediately related functions.
Decode a channel count encoded as a channel layout.
Return 0 if the channel layout was a real one.
Construct an empty AVFilterChannelLayouts/AVFilterFormats struct – representing any channel layout (with known disposition)/sample rate.
Definition at line 612 of file formats.c.
Referenced by join_query_formats(), and query_formats().
Definition at line 606 of file formats.c.
Referenced by ff_set_common_all_samplerates(), and query_formats().
Construct an AVFilterChannelLayouts coding for any channel layout, with known or unknown disposition.
Definition at line 621 of file formats.c.
Referenced by aeval_query_formats(), asink_query_formats(), channelmap_query_formats(), ff_set_common_all_channel_counts(), and query_formats().
Definition at line 444 of file formats.c.
Referenced by ff_set_common_channel_layouts_from_list(), movie_query_formats(), and query_formats().
Construct an AVFilterFormats representing all possible color spaces.
Note: This list does not include AVCOL_SPC_RESERVED.
Definition at line 630 of file formats.c.
Referenced by ff_set_common_all_color_spaces(), init(), libplacebo_query_format(), and query_formats().
Construct an AVFilterFormats representing all possible color ranges.
Definition at line 646 of file formats.c.
Referenced by ff_set_common_all_color_ranges(), init(), libplacebo_query_format(), and query_formats().
Helpers for query_formats() which set all free audio links to the same list of channel layouts/sample rates.
If there are no links hooked to this list, the list is freed.
Definition at line 790 of file formats.c.
Referenced by asink_query_formats(), ff_set_common_all_channel_counts(), ff_set_common_channel_layouts_from_list(), and query_formats().
Equivalent to ff_set_common_channel_layouts(ctx, ff_make_channel_layout_list(fmts))
Definition at line 797 of file formats.c.
Referenced by query_formats().
Equivalent to ff_set_common_channel_layouts(ctx, ff_all_channel_counts())
Definition at line 803 of file formats.c.
Referenced by aeval_query_formats(), ff_default_query_formats(), and query_formats().
Definition at line 808 of file formats.c.
Referenced by asink_query_formats(), ff_set_common_all_samplerates(), ff_set_common_samplerates_from_list(), and query_formats().
Equivalent to ff_set_common_samplerates(ctx, ff_make_format_list(samplerates))
Definition at line 815 of file formats.c.
Referenced by query_formats().
Equivalent to ff_set_common_samplerates(ctx, ff_all_samplerates())
Definition at line 821 of file formats.c.
Referenced by aeval_query_formats(), channelmap_query_formats(), ff_default_query_formats(), join_query_formats(), and query_formats().
Definition at line 826 of file formats.c.
Referenced by ff_set_common_all_color_spaces(), ff_set_common_color_spaces_from_list(), query_formats(), and vsink_query_formats().
Equivalent to ff_set_common_color_spaces(ctx, ff_all_color_spaces())
Definition at line 839 of file formats.c.
Referenced by ff_default_query_formats(), and ff_vaapi_vpp_query_formats().
Definition at line 844 of file formats.c.
Referenced by ff_set_common_all_color_ranges(), ff_set_common_color_ranges_from_list(), query_formats(), and vsink_query_formats().
Equivalent to ff_set_common_color_ranges(ctx, ff_all_color_ranges())
Definition at line 857 of file formats.c.
Referenced by ff_default_query_formats(), and ff_vaapi_vpp_query_formats().
A helper for query_formats() which sets all links to the same list of formats.
If there are no links hooked to this filter, the list of formats is freed.
Definition at line 867 of file formats.c.
Referenced by asink_query_formats(), channelmap_query_formats(), ff_default_query_formats(), ff_set_common_formats_from_list(), join_query_formats(), qrencode_query_formats(), qrencodesrc_query_formats(), query_formats(), and vsink_query_formats().
Equivalent to ff_set_common_formats(ctx, ff_make_format_list(fmts))
Definition at line 873 of file formats.c.
Referenced by aeval_query_formats(), geq_query_formats(), qsv_stack_query_formats(), query_formats(), and vaapi_stack_query_formats().
Definition at line 521 of file formats.c.
Referenced by aeval_query_formats(), asink_query_formats(), channelmap_query_formats(), join_query_formats(), parse_channel_layouts(), query_formats(), and reduce_formats_on_filter().
Add *ref as a new reference to f.
Definition at line 673 of file formats.c.
Referenced by aeval_query_formats(), channelmap_query_formats(), ff_set_common_channel_layouts(), join_query_formats(), movie_query_formats(), and query_formats().
Remove a reference to a channel layouts list.
Definition at line 729 of file formats.c.
Referenced by ff_add_channel_layout(), ff_channel_layouts_ref(), ff_set_common_channel_layouts(), free_link(), pick_format(), and uninit().
Definition at line 747 of file formats.c.
Referenced by avfilter_insert_filter().
Sets all remaining unset filter lists for all inputs/outputs to their corresponding ff_all_*() lists.
Definition at line 878 of file formats.c.
Referenced by filter_query_formats(), and main().
Create a list of supported formats.
This is intended for use in AVFilter->query_formats().
Definition at line 435 of file formats.c.
Referenced by cudaupload_query_formats(), ff_default_query_formats(), ff_make_formats_list_singleton(), ff_set_common_color_ranges_from_list(), ff_set_common_color_spaces_from_list(), ff_set_common_formats_from_list(), ff_set_common_samplerates_from_list(), ff_vaapi_vpp_query_formats(), hwupload_query_formats(), movie_query_formats(), overlay_qsv_query_formats(), and query_formats().
Equivalent to ff_make_format_list({const int[]}{ fmt, -1 })
Definition at line 529 of file formats.c.
Referenced by ff_default_query_formats(), libplacebo_query_format(), and query_formats().
Add fmt to the list of media formats contained in *avff.
If *avff is NULL the function allocates the filter formats struct and puts its pointer in *avff.
Definition at line 504 of file formats.c.
Referenced by asink_query_formats(), ff_all_color_ranges(), ff_all_color_spaces(), ff_all_formats(), ff_draw_supported_pixel_formats(), ff_planar_sample_fmts(), hwupload_query_formats(), init(), libplacebo_query_format(), qrencodesrc_query_formats(), query_formats(), reduce_formats_on_filter(), and vsink_query_formats().
Return a list of all formats supported by FFmpeg for the given media type.
Definition at line 535 of file formats.c.
Referenced by ff_default_query_formats(), hwmap_query_formats(), init(), and query_formats().
Construct a formats list containing all pixel formats with certain properties.
Definition at line 553 of file formats.c.
Referenced by ff_all_formats(), hwdownload_query_formats(), and query_formats().
Construct a formats list containing all planar sample formats.
Definition at line 593 of file formats.c.
Referenced by channelmap_query_formats(), join_query_formats(), and query_formats().
Add *ref as a new reference to formats.
That is the pointers will point like in the ascii art below:
|formats |<-----—. | ____ | ____|___________________ | |refs| | | __|_ | |* * | | | | | | AVFilterLink | |* *------—>|*ref| | |____| | | |____| |________| |________________________
Definition at line 678 of file formats.c.
Referenced by cudaupload_query_formats(), ff_set_common_color_ranges(), ff_set_common_color_spaces(), ff_set_common_formats(), ff_set_common_samplerates(), ff_vaapi_vpp_query_formats(), hwdownload_query_formats(), hwmap_query_formats(), hwupload_query_formats(), init(), libplacebo_query_format(), movie_query_formats(), overlay_qsv_query_formats(), and query_formats().
If *ref is non-NULL, remove *ref as a reference to the format list it currently points to, deallocates that list if this was the last reference, and sets *ref to NULL.
Before After
________ ________ NULL |formats |<-----—. |formats | ^ | ____ | ____|________________ | ____ | ____|________________ | |refs| | | __|_ | |refs| | | __|_ | |* * | | | | | | AVFilterLink | |* * | | | | | | AVFilterLink | |* ------—>|*ref| | | | | | |*ref| | |____| | | |____| | |____| | | |____| |________| |_____________________ |________| |_____________________
Definition at line 717 of file formats.c.
Referenced by ff_add_format(), ff_formats_ref(), ff_set_common_color_ranges(), ff_set_common_color_spaces(), ff_set_common_formats(), ff_set_common_samplerates(), free_link(), invert_formats(), libplacebo_query_format(), pick_format(), and uninit().
Before After
|formats |<------—. |formats |<------—. | ____ | ___|___ | ____ | ___|___ | |refs| | | | | | |refs| | | | | NULL | |* ------—>|*oldref| | | ------—>|*newref| ^ | | * | | |_______| | |* * | | |_______| ___|___ | |____| | | |____| | | | | |________| |________| |*oldref| |_______|
Definition at line 753 of file formats.c.
Referenced by avfilter_insert_filter().
Check that fmts is a valid pixel formats list.
In particular, check for duplicates.
Definition at line 1010 of file formats.c.
Referenced by filter_link_check_formats().
Check that fmts is a valid sample formats list.
In particular, check for duplicates.
Definition at line 1015 of file formats.c.
Referenced by filter_link_check_formats().
Check that fmts is a valid sample rates list.
In particular, check for duplicates.
Definition at line 1020 of file formats.c.
Referenced by filter_link_check_formats().
Check that fmts is a valid channel layouts list.
In particular, check for duplicates.
Definition at line 1050 of file formats.c.
Referenced by filter_link_check_formats().
Check that fmts is a valid formats list for YUV colorspace metadata.
In particular, check for duplicates.
Definition at line 1027 of file formats.c.
Referenced by filter_link_check_formats().
Definition at line 1038 of file formats.c.
Referenced by filter_link_check_formats().
Definition at line 397 of file formats.c.
Referenced by query_formats().