avio: add avio_open2, taking an interrupt callback and options

The interrupt callback has to be passed in during opening (setting it
after opening isn't enough), since a blocking open couldn't be
interrupted otherwise.

Options are passed down to procotols and also need to be available
during open() in most cases.

Signed-off-by: Anton Khirnov <anton@khirnov.net>
This commit is contained in:
Martin Storsjö
2011-11-13 13:17:04 +01:00
committed by Anton Khirnov
parent ddffc2fdc3
commit 1dee0aca74
5 changed files with 83 additions and 3 deletions
+4
View File
@@ -23,6 +23,10 @@
#include "avio.h"
#include "url.h"
#include "libavutil/log.h"
extern const AVClass ffio_url_class;
int ffio_init_context(AVIOContext *s,
unsigned char *buffer,
int buffer_size,