diff options
author | Maciej Koman <m.koman@fibargroup.com> | 2016-10-18 13:45:57 +0200 |
---|---|---|
committer | Alfred E. Heggestad <alfred.heggestad@gmail.com> | 2016-10-18 13:45:57 +0200 |
commit | f3ce13ab74715f3dbe142312b9abc009c803ca4a (patch) | |
tree | 10306c62e03697d34be79e04cfe8531325daf73f /modules | |
parent | 93a4ba831a01fc1e7d9980a6a06e1ed314ce09ea (diff) |
avformat network initialization (#157)
* avformat network initialization
* avformat network deinitialization and version support checking
* formatting
Diffstat (limited to 'modules')
-rw-r--r-- | modules/avformat/avformat.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/modules/avformat/avformat.c b/modules/avformat/avformat.c index 41ee243..64f6a4f 100644 --- a/modules/avformat/avformat.c +++ b/modules/avformat/avformat.c @@ -346,6 +346,11 @@ static int module_init(void) /* register all codecs, demux and protocols */ avcodec_register_all(); avdevice_register_all(); + +#if LIBAVFORMAT_VERSION_INT >= ((53<<16) + (13<<8) + 0) + avformat_network_init(); +#endif + av_register_all(); return vidsrc_register(&mod_avf, "avformat", alloc, NULL); @@ -355,6 +360,11 @@ static int module_init(void) static int module_close(void) { mod_avf = mem_deref(mod_avf); + +#if LIBAVFORMAT_VERSION_INT >= ((53<<16) + (13<<8) + 0) + avformat_network_deinit(); +#endif + return 0; } |