71 vfprintf(stdout, fmt, vl);
76#if HAVE_SETDLLDIRECTORY && defined(_WIN32)
90 error =
"Expected number for %s but found: %s\n";
91 else if (d < min || d >
max)
92 error =
"The value for %s was %s which is not within %f - %f\n";
94 error =
"Expected int64 for %s but found %s\n";
96 error =
"Expected int for %s but found %s\n";
116 if (((po->
flags & req_flags) != req_flags) ||
117 (po->
flags & rej_flags))
127 av_strlcat(buf,
"[:<stream_spec>]",
sizeof(buf));
169#if HAVE_COMMANDLINETOARGVW && defined(_WIN32)
172static char** win32_argv_utf8 =
NULL;
173static int win32_argc = 0;
186 int i, buffsize = 0,
offset = 0;
188 if (win32_argv_utf8) {
189 *argc_ptr = win32_argc;
190 *argv_ptr = win32_argv_utf8;
195 argv_w = CommandLineToArgvW(GetCommandLineW(), &win32_argc);
196 if (win32_argc <= 0 || !argv_w)
200 for (
i = 0;
i < win32_argc;
i++)
201 buffsize += WideCharToMultiByte(CP_UTF8, 0, argv_w[
i], -1,
204 win32_argv_utf8 =
av_mallocz(
sizeof(
char *) * (win32_argc + 1) + buffsize);
205 argstr_flat = (
char *)win32_argv_utf8 +
sizeof(
char *) * (win32_argc + 1);
206 if (!win32_argv_utf8) {
211 for (
i = 0;
i < win32_argc;
i++) {
212 win32_argv_utf8[
i] = &argstr_flat[
offset];
213 offset += WideCharToMultiByte(CP_UTF8, 0, argv_w[
i], -1,
217 win32_argv_utf8[
i] =
NULL;
220 *argc_ptr = win32_argc;
221 *argv_ptr = win32_argv_utf8;
246 char *arg_allocated =
NULL;
259 "Requested to load an argument from file for an option '%s'"
260 " which does not take an argument\n",
266 if (!arg_allocated) {
268 "Error reading the value for option '%s' from file: %s\n",
277 const char *p = strchr(opt,
':');
306 arg_allocated =
NULL;
349 *(
double *)
dst = num;
355 if ((strcmp(opt,
"init_hw_device") != 0) || (strcmp(
arg,
"list") != 0)) {
357 "Failed to set value '%s' for option '%s': %s\n",
383 .name =
"AVOption passthrough",
393 if (!po->
name && opt[0] ==
'n' && opt[1] ==
'o') {
420 int (*parse_arg_function)(
void *,
const char*))
423 int optindex, handleoptions = 1, ret;
430 while (optindex < argc) {
431 opt = argv[optindex++];
433 if (handleoptions && opt[0] ==
'-' && opt[1] !=
'\0') {
434 if (opt[1] ==
'-' && opt[2] ==
'\0') {
444 if (parse_arg_function) {
445 ret = parse_arg_function(optctx, opt);
460 g->group_def->name,
g->arg);
462 for (
i = 0;
i <
g->nb_opts;
i++) {
465 if (
g->group_def->flags &&
466 !(
g->group_def->flags & o->
opt->
flags)) {
468 "%s %s -- you are trying to apply an input option to an "
469 "output file or vice versa. Move this option before the "
470 "file it belongs to.\n", o->
key, o->
opt->
help,
471 g->group_def->name,
g->arg);
494 for (
i = 1;
i < argc;
i++) {
495 const char *cur_opt = argv[
i];
497 if (!(cur_opt[0] ==
'-' && cur_opt[1]))
502 if (!po->
name && cur_opt[0] ==
'n' && cur_opt[1] ==
'o')
505 if ((!po->
name && !strcmp(cur_opt, optname)) ||
506 (po->
name && !strcmp(optname, po->
name)))
517 const unsigned char *p;
520 if (!((*p >=
'+' && *p <=
':') || (*p >=
'@' && *p <=
'Z') ||
521 *p ==
'_' || (*p >=
'a' && *p <=
'z')))
528 for (p =
a; *p; p++) {
529 if (*p ==
'\\' || *p ==
'"' || *p ==
'$' || *p ==
'`')
531 else if (*p <
' ' || *p >
'~')
565 if (idx && argv[idx + 1])
575 for (
i = 0;
i < argc;
i++) {
589 int opt_flags,
int search_flags)
597#define FLAGS ((o->type == AV_OPT_TYPE_FLAGS && (arg[0]=='-' || arg[0]=='+')) ? AV_DICT_APPEND : 0)
602 char opt_stripped[128];
612 if (!strcmp(opt,
"debug") || !strcmp(opt,
"fdebug"))
615 if (!(p = strchr(opt,
':')))
616 p = opt + strlen(opt);
617 av_strlcpy(opt_stripped, opt,
FFMIN(
sizeof(opt_stripped), p - opt + 1));
621 ((opt[0] ==
'v' || opt[0] ==
'a' || opt[0] ==
's') &&
636 if (!strcmp(opt,
"srcw") || !strcmp(opt,
"srch") ||
637 !strcmp(opt,
"dstw") || !strcmp(opt,
"dsth") ||
638 !strcmp(opt,
"src_format") || !strcmp(opt,
"dst_format")) {
639 av_log(
NULL,
AV_LOG_ERROR,
"Directly using swscale dimensions/format options is not supported, please use the -s or -pix_fmt options\n");
647 if (!consumed && !strcmp(opt,
"sws_flags")) {
675 for (
i = 0;
i < nb_groups;
i++) {
677 if (p->sep && !strcmp(p->sep, opt))
725 const char *
key,
const char *
val)
735 g->opts[
g->nb_opts - 1].opt = opt;
736 g->opts[
g->nb_opts - 1].key =
key;
737 g->opts[
g->nb_opts - 1].val =
val;
748 memset(octx, 0,
sizeof(*octx));
806 while (optindex < argc) {
807 const char *opt = argv[optindex++], *
arg;
813 if (opt[0] ==
'-' && opt[1] ==
'-' && !opt[2]) {
818 if (opt[0] !=
'-' || !opt[1] || dashdash+1 == optindex) {
828#define GET_ARG(arg) \
830 arg = argv[optindex++]; \
832 av_log(NULL, AV_LOG_ERROR, "Missing argument for option '%s'.\n", opt);\
833 return AVERROR(EINVAL); \
839 if (group_idx >= 0) {
855 arg = argv[optindex++];
872 if (argv[optindex]) {
876 "argument '%s'.\n", opt, argv[optindex]);
881 "with argument '%s'.\n", opt, argv[optindex]);
887 if (opt[0] ==
'n' && opt[1] ==
'o' &&
890 ret =
add_opt(octx, po, opt,
"0");
895 "argument 0.\n", po->
name, po->
help);
905 "command: may be ignored.\n");
917 while (
c !=
'\n' &&
c != EOF)
924 const char *preset_name,
int is_path,
925 const char *codec_name)
929#if HAVE_GETMODULEHANDLE && defined(_WIN32)
930 char *datadir =
NULL;
933 char *env_ffmpeg_datadir =
getenv_utf8(
"FFMPEG_DATADIR");
934 const char *
base[3] = { env_ffmpeg_datadir,
939 av_strlcpy(filename, preset_name, filename_size);
942#if HAVE_GETMODULEHANDLE && defined(_WIN32)
943 wchar_t *datadir_w = get_module_filename(
NULL);
946 if (wchartoutf8(datadir_w, &datadir))
953 for (ls = datadir; *ls; ls++)
954 if (*ls ==
'\\') *ls =
'/';
956 if (ls = strrchr(datadir,
'/'))
958 ptrdiff_t datadir_len = ls - datadir;
959 size_t desired_size = datadir_len + strlen(
"/ffpresets") + 1;
961 datadir, desired_size,
sizeof *datadir);
963 datadir = new_datadir;
964 strcpy(datadir + datadir_len,
"/ffpresets");
970 for (
i = 0;
i < 3 && !
f;
i++) {
973 snprintf(filename, filename_size,
"%s%s/%s.ffpreset",
base[
i],
974 i != 1 ?
"" :
"/.ffmpeg", preset_name);
976 if (!
f && codec_name) {
977 snprintf(filename, filename_size,
978 "%s%s/%s-%s.ffpreset",
979 base[
i],
i != 1 ?
"" :
"/.ffmpeg", codec_name,
986#if HAVE_GETMODULEHANDLE && defined(_WIN32)
996 return (
c >=
'0' &&
c <=
'9') ||
997 (
c >=
'A' &&
c <=
'Z') ||
998 (
c >=
'a' &&
c <=
'z');
1007 memset(
ss, 0,
sizeof(*
ss));
1011 int allow_remainder,
void *logctx)
1016 memset(
ss, 0,
sizeof(*
ss));
1025 if (*spec <=
'9' && *spec >=
'0') {
1026 ss->idx = strtol(spec, &endptr, 0);
1032 "Parsed index: %d; remainder: %s\n",
ss->idx, spec);
1036 }
else if ((*spec ==
'v' || *spec ==
'a' || *spec ==
's' ||
1037 *spec ==
'd' || *spec ==
't' || *spec ==
'V') &&
1052 ss->no_apic = 1;
break;
1058 }
else if (*spec ==
'g' && *(spec + 1) ==
':') {
1060 goto multiple_stream_lists;
1063 if (*spec ==
'#' || (*spec ==
'i' && *(spec + 1) ==
':')) {
1066 spec += 1 + (*spec ==
'i');
1070 ss->list_id = strtol(spec, &endptr, 0);
1071 if (spec == endptr) {
1080 }
else if (*spec ==
'p' && *(spec + 1) ==
':') {
1082 goto multiple_stream_lists;
1087 ss->list_id = strtol(spec, &endptr, 0);
1088 if (spec == endptr) {
1096 "Parsed program ID: %"PRId64
"; remainder: %s\n",
ss->list_id, spec);
1097 }
else if (!strncmp(spec,
"disp:", 5)) {
1105 if (
ss->disposition) {
1114 spec[
len] ==
'_' || spec[
len] ==
'+';
len++)
1133 "Parsed disposition: 0x%x; remainder: %s\n",
ss->disposition, spec);
1134 }
else if (*spec ==
'#' ||
1135 (*spec ==
'i' && *(spec + 1) ==
':')) {
1137 goto multiple_stream_lists;
1141 spec += 1 + (*spec ==
'i');
1142 ss->list_id = strtol(spec, &endptr, 0);
1143 if (spec == endptr) {
1151 "Parsed stream ID: %"PRId64
"; remainder: %s\n",
ss->list_id, spec);
1155 }
else if (*spec ==
'm' && *(spec + 1) ==
':') {
1160 if (!
ss->meta_key) {
1167 if (!
ss->meta_val) {
1174 "Parsed metadata: %s:%s; remainder: %s",
ss->meta_key,
1175 ss->meta_val ?
ss->meta_val :
"<any value>", spec);
1179 }
else if (*spec ==
'u' && (*(spec + 1) ==
'\0' || *(spec + 1) ==
':')) {
1180 ss->usable_only = 1;
1194 if (!allow_remainder) {
1196 "Trailing garbage at the end of a stream specifier: %s\n",
1206 if (!
ss->remainder) {
1214multiple_stream_lists:
1216 "Cannot combine multiple program/group designators in a "
1217 "single stream specifier");
1234 switch (
ss->stream_list) {
1239 if (st->
id !=
ss->list_id)
1241 start_stream = st->
index;
1245 start_stream =
ss->idx >= 0 ? 0 : st->
index;
1249 for (
unsigned i = 0;
i <
s->nb_programs;
i++) {
1250 if (
s->programs[
i]->id ==
ss->list_id) {
1257 " stream specifier can never match\n",
ss->list_id);
1263 for (
unsigned i = 0;
i <
s->nb_stream_groups;
i++) {
1264 if (
ss->list_id ==
s->stream_groups[
i]->id) {
1265 g =
s->stream_groups[
i];
1272 ss->list_id >= 0 &&
ss->list_id <
s->nb_stream_groups)
1273 g =
s->stream_groups[
ss->list_id];
1277 PRId64
" exists, stream specifier can never match\n",
1288 const AVStream *candidate =
s->streams[
g ?
g->streams[
i]->index :
1289 p ? p->stream_index[
i] :
i];
1302 if (
ss->meta_val && strcmp(
tag->value,
ss->meta_val))
1306 if (
ss->usable_only) {
1324 if (
ss->disposition &&
1328 if (st == candidate)
1329 return ss->idx < 0 ||
ss->idx == nb_matched;
1355 int start_stream_group = 0, nb_stream_groups;
1361 switch (
ss->stream_list) {
1370 if (stg->
id !=
ss->list_id)
1372 start_stream_group = stg->
index;
1373 nb_stream_groups = stg->
index + 1;
1376 start_stream_group =
ss->list_id >= 0 ? 0 : stg->
index;
1377 nb_stream_groups = stg->
index + 1;
1382 for (
int i = start_stream_group;
i < nb_stream_groups;
i++) {
1391 if (
ss->meta_val && strcmp(
tag->value,
ss->meta_val))
1395 if (
ss->usable_only) {
1396 switch (candidate->
type) {
1409 if (
ss->disposition &&
1413 if (stg == candidate)
1414 return ss->list_id < 0 ||
ss->list_id == nb_matched;
1450 char *p = strchr(t->
key,
':');
1482 if (used && opts_used)
1506 for (
int i = 0;
i <
s->nb_streams;
i++) {
1515 for (
int i = 0;
i <
s->nb_streams;
i++)
1523 if (new_size >= INT_MAX / elem_size) {
1527 if (*
size < new_size) {
1531 memset(
tmp + *
size*elem_size, 0, (new_size-*
size) * elem_size);
1558 theta -= 360*
floor(theta/360 + 0.9/360);
1560 if (
fabs(theta - 90*
round(theta/90)) > 2)
1562 "If you want to help, upload a sample "
1563 "of this file to https://streams.videolan.org/upload/ "
1564 "and contact the ffmpeg-devel mailing list. (ffmpeg-devel@ffmpeg.org)");
1616 const char *
name,
const char *indent,
1626 const char *p =
tag->value;
1627 av_log(
ctx, log_level,
"%s %-16s: ", indent,
tag->key);
1629 size_t len = strcspn(p,
"\x8\xa\xb\xc\xd");
1632 if (*p == 0xd)
av_log(
ctx, log_level,
" ");
1633 if (*p == 0xa)
av_log(
ctx, log_level,
"\n%s %-16s: ", indent,
"");
uint8_t ptrdiff_t const uint8_t ptrdiff_t int intptr_t intptr_t int int16_t * dst
static double val(void *priv, double ch)
static AVFormatContext * ctx
static AVDictionary * opts
simple assert() macros that are a bit more flexible than ISO C assert().
#define av_assert0(cond)
assert() equivalent, that is always enabled.
int avio_open(AVIOContext **s, const char *filename, int flags)
Create and initialize a AVIOContext for accessing the resource indicated by url.
int avio_closep(AVIOContext **s)
Close the resource accessed by the AVIOContext *s, free it and set the pointer pointing to it to NULL...
#define AVIO_FLAG_READ
read-only
int avio_read_to_bprint(AVIOContext *h, struct AVBPrint *pb, size_t max_size)
Read contents of h into print buffer, up to max_size bytes, or up to EOF.
size_t av_strlcatf(char *dst, size_t size, const char *fmt,...)
void av_bprint_init(AVBPrint *buf, unsigned size_init, unsigned size_max)
#define AV_BPRINT_SIZE_UNLIMITED
#define flags(name, subs,...)
#define i(width, name, range_min, range_max)
#define ss(width, name, subs,...)
unsigned stream_group_specifier_match(const StreamSpecifier *ss, const AVFormatContext *s, const AVStreamGroup *stg, void *logctx)
static int match_group_separator(const OptionGroupDef *groups, int nb_groups, const char *opt)
int parse_optgroup(void *optctx, OptionGroup *g, const OptionDef *defs)
Parse an options group and write results into optctx.
static int opt_has_arg(const OptionDef *o)
void show_help_children(const AVClass *class, int flags)
Show help for all options with given flags in class and all its children.
static void prepare_app_arguments(int *argc_ptr, char ***argv_ptr)
void init_dynload(void)
Initialize dynamic library loading.
int parse_option(void *optctx, const char *opt, const char *arg, const OptionDef *options)
Parse one given option.
int opt_default(void *optctx, const char *opt, const char *arg)
Fallback for options that are not explicitly handled, these will be parsed through AVOptions.
int check_avoptions(AVDictionary *m)
void dump_dictionary(void *ctx, const AVDictionary *m, const char *name, const char *indent, int log_level)
This does the same as libavformat/dump.c corresponding function and should probably be kept in sync w...
int read_yesno(void)
Return a positive value if a line read from standard input starts with [yY], otherwise return 0.
int locate_option(int argc, char **argv, const OptionDef *options, const char *optname)
Return index of option opt in argv or 0 if not found.
static void dump_argument(FILE *report_file, const char *a)
static const AVOption * opt_find(void *obj, const char *name, const char *unit, int opt_flags, int search_flags)
int cmdutils_isalnum(char c)
int stream_specifier_parse(StreamSpecifier *ss, const char *spec, int allow_remainder, void *logctx)
Parse a stream specifier string into a form suitable for matching.
int check_stream_specifier(AVFormatContext *s, AVStream *st, const char *spec)
Check if the given stream matches a stream specifier.
void parse_loglevel(int argc, char **argv, const OptionDef *options)
Find the '-loglevel' option in the command line args and apply it.
static int add_opt(OptionParseContext *octx, const OptionDef *opt, const char *key, const char *val)
void show_help_options(const OptionDef *options, const char *msg, int req_flags, int rej_flags)
Print help for all options matching specified flags.
void uninit_parse_context(OptionParseContext *octx)
Free all allocated memory in an OptionParseContext.
int split_commandline(OptionParseContext *octx, int argc, char *argv[], const OptionDef *options, const OptionGroupDef *groups, int nb_groups)
Split the commandline into an intermediate form convenient for further processing.
void log_callback_help(void *ptr, int level, const char *fmt, va_list vl)
Trivial log callback.
void * allocate_array_elem(void *ptr, size_t elem_size, int *nb_elems)
Atomically add a new element to an array of pointers, i.e.
AVDictionary * format_opts
int parse_options(void *optctx, int argc, char **argv, const OptionDef *options, int(*parse_arg_function)(void *, const char *))
Parse the command line arguments.
int filter_codec_opts(const AVDictionary *opts, enum AVCodecID codec_id, AVFormatContext *s, AVStream *st, const AVCodec *codec, AVDictionary **dst, AVDictionary **opts_used)
Filter out options for given codec.
char * read_file_to_string(const char *filename)
void remove_avoptions(AVDictionary **a, AVDictionary *b)
AVDictionary * codec_opts
FILE * get_preset_file(char *filename, size_t filename_size, const char *preset_name, int is_path, const char *codec_name)
Get a file corresponding to a preset file.
static int finish_group(OptionParseContext *octx, int group_idx, const char *arg)
unsigned stream_specifier_match(const StreamSpecifier *ss, const AVFormatContext *s, const AVStream *st, void *logctx)
void uninit_opts(void)
Uninitialize the cmdutils option system, in particular free the *_opts contexts and their contents.
double get_rotation(const int32_t *displaymatrix)
int setup_find_stream_info_opts(AVFormatContext *s, AVDictionary *local_codec_opts, AVDictionary ***dst)
Setup AVCodecContext options for avformat_find_stream_info().
static const OptionDef * find_option(const OptionDef *po, const char *name)
int grow_array(void **array, int elem_size, int *size, int new_size)
Realloc array to hold new_size elements of elem_size.
static int write_option(void *optctx, const OptionDef *po, const char *opt, const char *arg, const OptionDef *defs)
int parse_number(const char *context, const char *numstr, enum OptionType type, double min, double max, double *dst)
Parse a string and return its corresponding value as a double.
void stream_specifier_uninit(StreamSpecifier *ss)
static void check_options(const OptionDef *po)
static int init_parse_context(OptionParseContext *octx, const OptionGroupDef *groups, int nb_groups)
#define GROW_ARRAY(array, nb_elems)
#define OPT_FLAG_PERSTREAM
__device__ int printf(const char *,...)
static __device__ float fabs(float a)
static __device__ float floor(float a)
static const uint16_t fc[]
double av_strtod(const char *numstr, char **tail)
Parse the string in numstr and return its value as a double.
simple arithmetic expression evaluator
static const OptionGroupDef groups[]
static unsigned int nb_streams
static FILE * fopen_utf8(const char *path, const char *mode)
static char * getenv_utf8(const char *varname)
static void freeenv_utf8(char *var)
#define AV_OPT_FLAG_AUDIO_PARAM
#define AV_OPT_FLAG_DECODING_PARAM
A generic parameter which can be set by the user for demuxing or decoding.
#define AV_OPT_FLAG_VIDEO_PARAM
#define AV_OPT_FLAG_ENCODING_PARAM
A generic parameter which can be set by the user for muxing or encoding.
#define AV_OPT_FLAG_SUBTITLE_PARAM
const AVClass * avcodec_get_class(void)
Get the AVClass for AVCodecContext.
AVCodecID
Identify the syntax and semantics of the bitstream.
const AVClass * av_stream_get_class(void)
Get the AVClass for AVStream.
const AVClass * avformat_get_class(void)
Get the AVClass for AVFormatContext.
int av_bprint_finalize(AVBPrint *buf, char **ret_str)
Finalize a print buffer.
void av_dict_free(AVDictionary **pm)
Free all the memory allocated for an AVDictionary struct and all keys and values.
AVDictionaryEntry * av_dict_get(const AVDictionary *m, const char *key, const AVDictionaryEntry *prev, int flags)
Get a dictionary entry with matching key.
const AVDictionaryEntry * av_dict_iterate(const AVDictionary *m, const AVDictionaryEntry *prev)
Iterate over a dictionary.
int av_dict_set(AVDictionary **pm, const char *key, const char *value, int flags)
Set the given entry in *pm, overwriting an existing entry.
#define AV_DICT_MATCH_CASE
Only get an entry with exact-case key match.
#define AVERROR_EXIT
Immediate exit was requested; the called function should not be restarted.
#define av_err2str(errnum)
Convenience macro, the return value should be used only directly in function arguments but never stan...
#define AVERROR_OPTION_NOT_FOUND
Option not found.
#define AV_LOG_TRACE
Extremely verbose debugging, useful for libav* development.
#define AV_LOG_DEBUG
Stuff which is only useful for libav* developers.
#define AV_LOG_WARNING
Something somehow does not look correct.
#define AV_LOG_FATAL
Something went wrong and recovery is not possible.
#define AV_LOG_VERBOSE
Detailed information.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
void av_log_set_level(int level)
Set the log level.
int av_dynarray_add_nofree(void *tab_ptr, int *nb_ptr, void *elem)
Add an element to a dynamic array.
char * av_strndup(const char *s, size_t len)
Duplicate a substring of a string.
void * av_realloc_array(void *ptr, size_t nmemb, size_t size)
const char * av_get_media_type_string(enum AVMediaType media_type)
Return a string describing the media_type enum, NULL if media_type is unknown.
@ AVMEDIA_TYPE_ATTACHMENT
Opaque data information usually sparse.
@ AVMEDIA_TYPE_DATA
Opaque data information usually continuous.
@ AVMEDIA_TYPE_UNKNOWN
Usually treated as AVMEDIA_TYPE_DATA.
size_t av_strlcat(char *dst, const char *src, size_t size)
Append the string src to the string dst, but to a total length of no more than size - 1 bytes,...
int av_strstart(const char *str, const char *pfx, const char **ptr)
Return non-zero if pfx is a prefix of str.
size_t av_strlcpy(char *dst, const char *src, size_t size)
Copy the string src to dst, but no more than size - 1 bytes, and null-terminate dst.
char * av_get_token(const char **buf, const char *term)
Unescape the given string until a non escaped terminating char, and return the token corresponding to...
static av_const int av_toupper(int c)
Locale-independent conversion of ASCII characters to uppercase.
double av_display_rotation_get(const int32_t matrix[9])
Extract the rotation component of the transformation matrix.
const AVClass * sws_get_class(void)
Get the AVClass for SwsContext.
const AVClass * swr_get_class(void)
Get the AVClass for SwrContext.
int av_opt_eval_flags(void *obj, const AVOption *o, const char *val, int *flags_out)
const AVClass * av_opt_child_class_iterate(const AVClass *parent, void **iter)
Iterate over potential AVOptions-enabled children of parent.
#define AV_OPT_SEARCH_CHILDREN
Search in possible children of the given object first.
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.
#define AV_OPT_SEARCH_FAKE_OBJ
The obj passed to av_opt_find() or av_opt_set() is fake – only a double pointer to AVClass instead of...
int av_opt_show2(void *obj, void *av_log_obj, int req_flags, int rej_flags)
Show the obj options.
Replacements for frequently missing libm functions.
static av_always_inline av_const double round(double x)
void * av_calloc(size_t nmemb, size_t size)
Memory handling functions.
int opt_loglevel(void *optctx, const char *opt, const char *arg)
Set the libav* libraries log level.
static FILE * report_file
int init_report(const char *env, FILE **file)
int av_parse_time(int64_t *timeval, const char *timestr, int duration)
Parse timestr and return in *time a corresponding number of microseconds.
int nb_channels
Number of channels in this layout.
Describe the class of an AVClass context structure.
This struct describes the properties of an encoded stream.
int height
The height of the video frame in pixels.
AVChannelLayout ch_layout
The channel layout and number of channels.
int width
The width of the video frame in pixels.
enum AVMediaType codec_type
General type of the encoded data.
int sample_rate
The number of audio samples per second.
const AVClass * priv_class
AVClass for the private context.
int flags
A combination of AV_OPT_FLAG_*.
New fields can be added to the end with minor version bumps.
AVStreamGroupTileGrid holds information on how to combine several independent images on a single canv...
int width
Width of the final image for presentation.
int height
Height of the final image for presentation.
int coded_width
Width of the canvas.
struct AVStreamGroupTileGrid::@036353327352337314037001273105074056331305251354 * offsets
An nb_tiles sized array of offsets in pixels from the topleft edge of the canvas, indicating where ea...
unsigned int nb_tiles
Amount of tiles in the grid.
int coded_height
Width of the canvas.
union AVStreamGroup::@166361102046003066253145020066347265153020354020 params
Group type-specific parameters.
enum AVStreamGroupParamsType type
Group type.
struct AVStreamGroupTileGrid * tile_grid
AVDictionary * metadata
Metadata that applies to the whole group.
unsigned int index
Group index in AVFormatContext.
int disposition
Stream group disposition - a combination of AV_DISPOSITION_* flags.
int64_t id
Group type-specific group ID.
AVCodecParameters * codecpar
Codec parameters associated with this stream.
int id
Format-specific stream ID.
int index
stream index in AVFormatContext
int disposition
Stream disposition - a combination of AV_DISPOSITION_* flags.
union OptionDef::@124325020351351046145113015057017340133060321367 u
union OptionDef::@302341376237271032103161277113207234376351006005 u1
int(* func_arg)(void *, const char *, const char *)
A list of option groups that all have the same group type (e.g.
const OptionGroupDef * group_def
const OptionGroupDef * group_def
AVDictionary * codec_opts
AVDictionary * format_opts
An option extracted from the commandline.
const struct OptionDef * opt_canon
StreamSpecifier stream_spec
union SpecifierOpt::@356325016025214271156003270003007057215065005026 u
libswresample public header
static void error(const char *err)
static int array[MAX_W *MAX_W]