239 #if FF_API_OLD_AVOPTIONS
285 #define AV_OPT_FLAG_ENCODING_PARAM 1
286 #define AV_OPT_FLAG_DECODING_PARAM 2
287 #if FF_API_OPT_TYPE_METADATA
288 #define AV_OPT_FLAG_METADATA 4
290 #define AV_OPT_FLAG_AUDIO_PARAM 8
291 #define AV_OPT_FLAG_VIDEO_PARAM 16
292 #define AV_OPT_FLAG_SUBTITLE_PARAM 32
296 #define AV_OPT_FLAG_EXPORT 64
301 #define AV_OPT_FLAG_READONLY 128
302 #define AV_OPT_FLAG_FILTERING_PARAM (1<<16)
303 //FIXME think about enc-audio, ... style flags
382 #if FF_API_OLD_AVOPTIONS
435 int av_opt_show2(
void *obj,
void *av_log_obj,
int req_flags,
int rej_flags);
473 const char *key_val_sep,
const char *pairs_sep);
503 const char *
const *shorthand,
504 const char *key_val_sep,
const char *pairs_sep);
574 const char *key_val_sep,
const char *pairs_sep,
576 char **rkey,
char **rval);
611 #define AV_OPT_SEARCH_CHILDREN 0x0001
619 #define AV_OPT_SEARCH_FAKE_OBJ 0x0002
626 #define AV_OPT_MULTI_COMPONENT_RANGE 0x1000
651 int opt_flags,
int search_flags);
675 int opt_flags,
int search_flags,
void **target_obj);
756 #define av_opt_set_int_list(obj, name, val, term, flags) \
757 (av_int_list_length(val, term) > INT_MAX / sizeof(*(val)) ? \
759 av_opt_set_bin(obj, name, (const uint8_t *)(val), \
760 av_int_list_length(val, term) * sizeof(*(val)), flags))
883 #define AV_OPT_SERIALIZE_SKIP_DEFAULTS 0x00000001
884 #define AV_OPT_SERIALIZE_OPT_FLAGS_EXACT 0x00000002
905 const char key_val_sep,
const char pairs_sep);
int av_opt_get_dict_val(void *obj, const char *name, int search_flags, AVDictionary **out_val)
const char const char void * val
offset must point to a pointer immediately followed by an int for the length
A single allowed range of values, or a single allowed value.
int av_opt_eval_float(void *obj, const AVOption *o, const char *val, float *float_out)
attribute_deprecated const AVOption * av_set_int(void *obj, const char *name, int64_t n)
int av_opt_set_q(void *obj, const char *name, AVRational val, int search_flags)
void * av_opt_child_next(void *obj, void *prev)
Iterate over AVOptions-enabled children of obj.
const AVClass * av_opt_child_class_next(const AVClass *parent, const AVClass *prev)
Iterate over potential AVOptions-enabled children of parent.
void av_opt_set_defaults(void *s)
Set the values of all AVOption fields to their default values.
int av_set_options_string(void *ctx, const char *opts, const char *key_val_sep, const char *pairs_sep)
Parse the key/value pairs list in opts.
int av_opt_set_bin(void *obj, const char *name, const uint8_t *val, int size, int search_flags)
int av_opt_get_q(void *obj, const char *name, int search_flags, AVRational *out_val)
int av_opt_serialize(void *obj, int opt_flags, int flags, char **buffer, const char key_val_sep, const char pairs_sep)
Serialize object's options.
int av_opt_set_dict_val(void *obj, const char *name, const AVDictionary *val, int search_flags)
int av_opt_is_set_to_default_by_name(void *obj, const char *name, int search_flags)
Check if given option is set to its default value.
attribute_deprecated const char * av_get_string(void *obj, const char *name, const AVOption **o_out, char *buf, int buf_len)
int av_opt_is_set_to_default(void *obj, const AVOption *o)
Check if given option is set to its default value.
int av_opt_get_video_rate(void *obj, const char *name, int search_flags, AVRational *out_val)
int av_opt_set_from_string(void *ctx, const char *opts, const char *const *shorthand, const char *key_val_sep, const char *pairs_sep)
Parse the key-value pairs list in opts.
AVOptionRange ** range
Array of option ranges.
Accept to parse a value without a key; the key will then be returned as NULL.
const char * help
short English help text
attribute_deprecated const AVOption * av_set_double(void *obj, const char *name, double n)
int av_opt_eval_int64(void *obj, const AVOption *o, const char *val, int64_t *int64_out)
int av_opt_set_double(void *obj, const char *name, double val, int search_flags)
attribute_deprecated AVRational av_get_q(void *obj, const char *name, const AVOption **o_out)
const OptionDef options[]
int av_opt_set_video_rate(void *obj, const char *name, AVRational val, int search_flags)
int av_opt_get_pixel_fmt(void *obj, const char *name, int search_flags, enum AVPixelFormat *out_fmt)
int av_opt_set_pixel_fmt(void *obj, const char *name, enum AVPixelFormat fmt, int search_flags)
void * av_opt_ptr(const AVClass *avclass, void *obj, const char *name)
Gets a pointer to the requested field in a struct.
static const uint16_t mask[17]
double max
maximum valid value for the option
int av_opt_eval_flags(void *obj, const AVOption *o, const char *val, int *flags_out)
int av_opt_set_int(void *obj, const char *name, int64_t val, int search_flags)
Libavutil version macros.
const AVOption * av_opt_find(void *obj, const char *name, const char *unit, int opt_flags, int search_flags)
Look for an option in an object.
int av_opt_eval_double(void *obj, const AVOption *o, const char *val, double *double_out)
int av_opt_get_sample_fmt(void *obj, const char *name, int search_flags, enum AVSampleFormat *out_fmt)
const AVOption * av_opt_next(FF_CONST_AVUTIL55 void *obj, const AVOption *prev)
Iterate over all AVOptions belonging to obj.
int av_opt_copy(void *dest, FF_CONST_AVUTIL55 void *src)
Copy options from src object into dest object.
const char * unit
The logical unit to which the option belongs.
double component_min
Value's component range.
int av_opt_eval_q(void *obj, const AVOption *o, const char *val, AVRational *q_out)
int av_opt_set_channel_layout(void *obj, const char *name, int64_t ch_layout, int search_flags)
double min
minimum valid value for the option
void av_opt_set_defaults2(void *s, int mask, int flags)
Set the values of all AVOption fields to their default values.
attribute_deprecated double av_get_double(void *obj, const char *name, const AVOption **o_out)
attribute_deprecated const AVOption * av_set_q(void *obj, const char *name, AVRational n)
int av_opt_set_dict2(void *obj, struct AVDictionary **options, int search_flags)
Set all the options from a given dictionary on an object.
offset must point to a pointer immediately followed by an int for the length
int av_opt_query_ranges_default(AVOptionRanges **, void *obj, const char *key, int flags)
Get a default list of allowed ranges for the given option.
int av_opt_get_int(void *obj, const char *name, int search_flags, int64_t *out_val)
void av_opt_freep_ranges(AVOptionRanges **ranges)
Free an AVOptionRanges struct and set it to NULL.
int offset
The offset relative to the context structure where the option value is stored.
AVSampleFormat
Audio sample formats.
union AVOption::@192 default_val
the default value for scalar options
int av_opt_set_dict(void *obj, struct AVDictionary **options)
Set all the options from a given dictionary on an object.
int av_opt_show2(void *obj, void *av_log_obj, int req_flags, int rej_flags)
Show the obj options.
attribute_deprecated int64_t av_get_int(void *obj, const char *name, const AVOption **o_out)
int av_opt_get_channel_layout(void *obj, const char *name, int search_flags, int64_t *ch_layout)
Describe the class of an AVClass context structure.
rational number numerator/denominator
offset must point to AVRational
int av_opt_eval_int(void *obj, const AVOption *o, const char *val, int *int_out)
offset must point to two consecutive integers
attribute_deprecated const AVOption * av_next_option(FF_CONST_AVUTIL55 void *obj, const AVOption *last)
#define attribute_deprecated
void av_opt_free(void *obj)
Free all allocated objects in obj.
int av_opt_query_ranges(AVOptionRanges **, void *obj, const char *key, int flags)
Get a list of allowed ranges for the given option.
double value_min
Value range.
int av_opt_get_double(void *obj, const char *name, int search_flags, double *out_val)
int nb_ranges
Number of ranges per component.
#define MKBETAG(a, b, c, d)
List of AVOptionRange structs.
attribute_deprecated int av_set_string3(void *obj, const char *name, const char *val, int alloc, const AVOption **o_out)
Set the field of obj with the given name to value.
int av_opt_get(void *obj, const char *name, int search_flags, uint8_t **out_val)
int av_opt_get_key_value(const char **ropts, const char *key_val_sep, const char *pairs_sep, unsigned flags, char **rkey, char **rval)
Extract a key-value pair from the beginning of a string.
int av_opt_flag_is_set(void *obj, const char *field_name, const char *flag_name)
Check whether a particular flag is set in a flags field.
#define FF_CONST_AVUTIL55
const AVOption * av_opt_find2(void *obj, const char *name, const char *unit, int opt_flags, int search_flags, void **target_obj)
Look for an option in an object.
int av_opt_set_sample_fmt(void *obj, const char *name, enum AVSampleFormat fmt, int search_flags)
AVPixelFormat
Pixel format.
int av_opt_set_image_size(void *obj, const char *name, int w, int h, int search_flags)
int av_opt_set(void *obj, const char *name, const char *val, int search_flags)
int nb_components
Number of componentes.
int av_opt_get_image_size(void *obj, const char *name, int search_flags, int *w_out, int *h_out)