aboutsummaryrefslogtreecommitdiffstats
path: root/cmdutils.h
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2011-07-28 16:47:38 +0200
committerAnton Khirnov <anton@khirnov.net>2011-08-12 18:35:12 +0200
commitd4863fc1a83ceab1d75469b406a2c67e5659b2a0 (patch)
tree6d8779fe01d8bda7e23473fc45da43467b072b1f /cmdutils.h
parentf60d13663742d1c695680ede83c4d646bc57d380 (diff)
downloadffmpeg-d4863fc1a83ceab1d75469b406a2c67e5659b2a0.tar.gz
cmdutils: allow precisely specifying a stream for AVOptions.
Diffstat (limited to 'cmdutils.h')
-rw-r--r--cmdutils.h16
1 files changed, 14 insertions, 2 deletions
diff --git a/cmdutils.h b/cmdutils.h
index 7769194b9c..48ea213bde 100644
--- a/cmdutils.h
+++ b/cmdutils.h
@@ -149,15 +149,27 @@ void parse_options(int argc, char **argv, const OptionDef *options,
void (* parse_arg_function)(const char*));
/**
+ * Check if the given stream matches a stream specifier.
+ *
+ * @param s Corresponding format context.
+ * @param st Stream from s to be checked.
+ * @param spec A stream specifier of the [v|a|s|d]:[<stream index>] form.
+ *
+ * @return 1 if the stream matches, 0 if it doesn't, <0 on error
+ */
+int check_stream_specifier(AVFormatContext *s, AVStream *st, const char *spec);
+
+/**
* Filter out options for given codec.
*
* Create a new options dictionary containing only the options from
* opts which apply to the codec with ID codec_id.
*
- * @param encoder if non-zero the codec is an encoder, otherwise is a decoder
+ * @param s Corresponding format context.
+ * @param st A stream from s for which the options should be filtered.
* @return a pointer to the created dictionary
*/
-AVDictionary *filter_codec_opts(AVDictionary *opts, enum CodecID codec_id, int encoder);
+AVDictionary *filter_codec_opts(AVDictionary *opts, enum CodecID codec_id, AVFormatContext *s, AVStream *st);
/**
* Setup AVCodecContext options for avformat_find_stream_info().