49 #define AV_PIX_FMT_NAME_MAXSIZE 32
54 const char *cur, *sep;
56 int pix_fmt_name_len,
ret;
60 for (cur = s->
pix_fmts; cur; cur = sep ? sep + 1 : NULL) {
61 if (!(sep = strchr(cur,
'|')))
62 pix_fmt_name_len = strlen(cur);
64 pix_fmt_name_len = sep - cur;
70 memcpy(pix_fmt_name, cur, pix_fmt_name_len);
71 pix_fmt_name[pix_fmt_name_len] = 0;
99 #define OFFSET(x) offsetof(FormatContext, x)
105 #if CONFIG_FORMAT_FILTER
112 #define format_options options
115 static const AVFilterPad avfilter_vf_format_inputs[] = {
124 static const AVFilterPad avfilter_vf_format_outputs[] = {
134 .description =
NULL_IF_CONFIG_SMALL(
"Convert the input video to one of the specified pixel formats."),
138 .query_formats = query_formats_format,
141 .priv_class = &format_class,
143 .
inputs = avfilter_vf_format_inputs,
144 .
outputs = avfilter_vf_format_outputs,
148 #if CONFIG_NOFORMAT_FILTER
155 #define noformat_options options
158 static const AVFilterPad avfilter_vf_noformat_inputs[] = {
167 static const AVFilterPad avfilter_vf_noformat_outputs[] = {
177 .description =
NULL_IF_CONFIG_SMALL(
"Force libavfilter not to use any of the specified pixel formats for the input to the next filter."),
181 .query_formats = query_formats_noformat,
184 .priv_class = &noformat_class,
186 .
inputs = avfilter_vf_noformat_inputs,
187 .
outputs = avfilter_vf_noformat_outputs,