[FFmpeg-devel] [PATCH 4/8] lavu/opt: extend AVOptionRange by second value

wm4 nfxjfg at googlemail.com
Mon Feb 24 12:52:54 CET 2014


On Sat, 22 Feb 2014 23:33:38 +0100
Lukasz Marek <lukasz.m.luki at gmail.com> wrote:


>  typedef struct AVOptionRange {
>      const char *str;
> -    double value_min, value_max;             ///< For string ranges this represents the min/max length, for dimensions this represents the min/max pixel count
> -    double component_min, component_max;     ///< For string this represents the unicode range for chars, 0-127 limits to ASCII
> -    int is_range;                            ///< if set to 1 the struct encodes a range, if set to 0 a single value
> +    /**
> +     * AV_OPT_TYPE_IMAGE_SIZE options use both elements to represent width and height ranges.
> +     * Other options uses only first elements.
> +     * For string ranges first elements represent the min/max length.
> +     */
> +    double value_min[2], value_max[2];
> +    /**
> +     * For string this represents the unicode range for chars, 0-127 limits to ASCII
> +     */
> +    double component_min, component_max;
> +    /**
> +     * If set to 1 the struct encodes a range, if set to 0 a single value
> +     */
> +    int is_range;
>  } AVOptionRange;

I don't think you can do that without a major API bump. At least
nothing suggests that this struct is not public.


More information about the ffmpeg-devel mailing list