#include "libavutil/rational.h"
#include "avcodec.h"
Go to the source code of this file.
Data Structures | |
struct | AVOption |
AVOption. More... | |
Defines | |
#define | AV_OPT_FLAG_ENCODING_PARAM 1 |
a generic parameter which can be set by the user for muxing or encoding | |
#define | AV_OPT_FLAG_DECODING_PARAM 2 |
a generic parameter which can be set by the user for demuxing or decoding | |
#define | AV_OPT_FLAG_METADATA 4 |
some data extracted or inserted into the file like title, comment, ... | |
#define | AV_OPT_FLAG_AUDIO_PARAM 8 |
#define | AV_OPT_FLAG_VIDEO_PARAM 16 |
#define | AV_OPT_FLAG_SUBTITLE_PARAM 32 |
Enumerations | |
enum | AVOptionType { FF_OPT_TYPE_FLAGS, FF_OPT_TYPE_INT, FF_OPT_TYPE_INT64, FF_OPT_TYPE_DOUBLE, FF_OPT_TYPE_FLOAT, FF_OPT_TYPE_STRING, FF_OPT_TYPE_RATIONAL, FF_OPT_TYPE_BINARY, FF_OPT_TYPE_CONST = 128 } |
Functions | |
const AVOption * | av_find_opt (void *obj, const char *name, const char *unit, int mask, int flags) |
Looks for an option in obj . | |
attribute_deprecated const AVOption * | av_set_string (void *obj, const char *name, const char *val) |
attribute_deprecated const AVOption * | av_set_string2 (void *obj, const char *name, const char *val, int alloc) |
int | av_set_string3 (void *obj, const char *name, const char *val, int alloc, const AVOption **o_out) |
Sets the field of obj with the given name to value. | |
const AVOption * | av_set_double (void *obj, const char *name, double n) |
const AVOption * | av_set_q (void *obj, const char *name, AVRational n) |
const AVOption * | av_set_int (void *obj, const char *name, int64_t n) |
double | av_get_double (void *obj, const char *name, const AVOption **o_out) |
AVRational | av_get_q (void *obj, const char *name, const AVOption **o_out) |
int64_t | av_get_int (void *obj, const char *name, const AVOption **o_out) |
const char * | av_get_string (void *obj, const char *name, const AVOption **o_out, char *buf, int buf_len) |
const AVOption * | av_next_option (void *obj, const AVOption *last) |
int | av_opt_show (void *obj, void *av_log_obj) |
void | av_opt_set_defaults (void *s) |
void | av_opt_set_defaults2 (void *s, int mask, int flags) |
Set the values of the AVCodecContext or AVFormatContext structure. |
Definition in file opt.h.
#define AV_OPT_FLAG_AUDIO_PARAM 8 |
Definition at line 75 of file opt.h.
Referenced by avcodec_get_context_defaults2(), new_audio_stream(), opt_default(), opt_input_file(), opt_list(), and parse_ffconfig().
#define AV_OPT_FLAG_DECODING_PARAM 2 |
a generic parameter which can be set by the user for demuxing or decoding
Definition at line 73 of file opt.h.
Referenced by opt_input_file(), and opt_list().
#define AV_OPT_FLAG_ENCODING_PARAM 1 |
a generic parameter which can be set by the user for muxing or encoding
Definition at line 72 of file opt.h.
Referenced by new_audio_stream(), new_subtitle_stream(), new_video_stream(), opt_list(), opt_output_file(), and parse_ffconfig().
#define AV_OPT_FLAG_METADATA 4 |
#define AV_OPT_FLAG_SUBTITLE_PARAM 32 |
Definition at line 77 of file opt.h.
Referenced by avcodec_get_context_defaults2(), new_subtitle_stream(), opt_default(), and opt_list().
#define AV_OPT_FLAG_VIDEO_PARAM 16 |
Definition at line 76 of file opt.h.
Referenced by avcodec_get_context_defaults2(), new_video_stream(), opt_default(), opt_input_file(), opt_list(), and parse_ffconfig().
enum AVOptionType |
const AVOption* av_find_opt | ( | void * | obj, | |
const char * | name, | |||
const char * | unit, | |||
int | mask, | |||
int | flags | |||
) |
Looks for an option in obj
.
Looks only for the options which have the flags set as specified in mask
and flags
(that is, for which it is the case that opt->flags & mask == flags).
[in] | obj | a pointer to a struct whose first element is a pointer to an AVClass |
[in] | name | the name of the option to look for |
[in] | unit | the unit of the option to look for, or any if NULL |
Definition at line 33 of file opt.c.
Referenced by av_get_number(), av_get_string(), av_set_number2(), av_set_string3(), ffserver_opt_default(), and opt_default().
double av_get_double | ( | void * | obj, | |
const char * | name, | |||
const AVOption ** | o_out | |||
) |
int64_t av_get_int | ( | void * | obj, | |
const char * | name, | |||
const AVOption ** | o_out | |||
) |
Definition at line 313 of file opt.c.
Referenced by av_encode(), av_set_string3(), opt_bitrate(), and queue_picture().
AVRational av_get_q | ( | void * | obj, | |
const char * | name, | |||
const AVOption ** | o_out | |||
) |
const char* av_get_string | ( | void * | obj, | |
const char * | name, | |||
const AVOption ** | o_out, | |||
char * | buf, | |||
int | buf_len | |||
) |
buf | a buffer which is used for returning non string values as strings, can be NULL | |
buf_len | allocated length in bytes of buf |
Definition at line 235 of file opt.c.
Referenced by set_context_opts().
void av_opt_set_defaults | ( | void * | s | ) |
void av_opt_set_defaults2 | ( | void * | s, | |
int | mask, | |||
int | flags | |||
) |
Set the values of the AVCodecContext or AVFormatContext structure.
They are set to the defaults specified in the according AVOption options array default_val field.
s | AVCodecContext or AVFormatContext for which the defaults will be set |
Definition at line 408 of file opt.c.
Referenced by av_opt_set_defaults(), and avcodec_get_context_defaults2().
int av_opt_show | ( | void * | obj, | |
void * | av_log_obj | |||
) |
const AVOption* av_set_double | ( | void * | obj, | |
const char * | name, | |||
double | n | |||
) |
const AVOption* av_set_int | ( | void * | obj, | |
const char * | name, | |||
int64_t | n | |||
) |
const AVOption* av_set_q | ( | void * | obj, | |
const char * | name, | |||
AVRational | n | |||
) |
attribute_deprecated const AVOption* av_set_string | ( | void * | obj, | |
const char * | name, | |||
const char * | val | |||
) |
attribute_deprecated const AVOption* av_set_string2 | ( | void * | obj, | |
const char * | name, | |||
const char * | val, | |||
int | alloc | |||
) |
val
is not valid int av_set_string3 | ( | void * | obj, | |
const char * | name, | |||
const char * | val, | |||
int | alloc, | |||
const AVOption ** | o_out | |||
) |
Sets the field of obj with the given name to value.
[in] | obj | A struct whose first element is a pointer to an AVClass. |
[in] | name | the name of the field to set |
[in] | val | The value to set. If the field is not of a string type, then the given string is parsed. SI postfixes and some named scalars are supported. If the field is of a numeric type, it has to be a numeric or named scalar. Behavior with more than one scalar and +- infix operators is undefined. If the field is of a flags type, it has to be a sequence of numeric scalars or named flags separated by '+' or '-'. Prefixing a flag with '+' causes it to be set without affecting the other flags; similarly, '-' unsets a flag. |
[out] | o_out | if non-NULL put here a pointer to the AVOption found |
alloc | when 1 then the old value will be av_freed() and the new av_strduped() when 0 then no av_free() nor av_strdup() will be used |
val
is not valid Definition at line 110 of file opt.c.
Referenced by av_set_string(), av_set_string2(), ffserver_opt_default(), opt_default(), and set_context_opts().