Browse Source

Merge pull request #709 from kkartaltepe/libff-allow-options

libff: Allow custom demuxer options
Jim 9 years ago
parent
commit
3869f6dbc2
2 changed files with 2 additions and 1 deletions
  1. 1 1
      deps/libff/libff/ff-demuxer.c
  2. 1 0
      deps/libff/libff/ff-demuxer.h

+ 1 - 1
deps/libff/libff/ff-demuxer.c

@@ -377,7 +377,7 @@ static bool open_input(struct ff_demuxer *demuxer,
 	}
 
 	if (avformat_open_input(format_context, demuxer->input,
-			input_format, NULL) != 0)
+			input_format, &demuxer->options.custom_options) != 0)
 		return false;
 
 	return avformat_find_stream_info(*format_context, NULL) >= 0;

+ 1 - 0
deps/libff/libff/ff-demuxer.h

@@ -40,6 +40,7 @@ struct ff_demuxer_options
 	bool is_hw_decoding;
 	bool is_looping;
 	enum AVDiscard frame_drop;
+	AVDictionary *custom_options;
 };
 
 typedef struct ff_demuxer_options ff_demuxer_options_t;