[Libav-user] Converting from one pixel format to another using the scale filter
Carl Eugen Hoyos
ceffmpeg at gmail.com
Wed Jun 13 12:27:28 EEST 2018
2018-06-11 13:19 GMT+02:00, Benjamin Pernot <benjamin.pernot at free.fr>:
> I would like to use the scale filter (based on swscale) to convert from one
> pixel format to another, which means that I would like to be able to
> specify to this filter the "dst_format" parameter (as well as "src_format"
> Unfortunately from what I can see in the source code (vf_scale.c), the
> "dst_format" parameter can not be configured but it is automatically set as
> such :
> enum AVPixelFormat outfmt = outlink->format;
> av_opt_set_int(*s, "dst_format", outfmt, 0);
> How can I override the "dst_format" parameter?
Do you want to use the scale filter?
In this case the src format is the one provided to the
filter chain / the input video, you cannot overwrite it.
Or do you want to use libswscale directly?
Then the file vf_scale has no relevance.
Look at either doc/examples/filtering_video.c or
More information about the Libav-user