diff options
| author | Comment <tim@gray.(none)> | 2013-07-30 16:05:44 +0100 |
|---|---|---|
| committer | Comment <tim@gray.(none)> | 2013-07-30 16:05:44 +0100 |
| commit | 01f53fe4485b3c96c0f553e1cade69f77081b078 (patch) | |
| tree | 5717695bbc7460ff7e41649c050c50ff6f786341 /rotord/src/libavwrapper.cpp | |
| parent | 7fd8fbbf69631a868b8274a25023023cde141a4c (diff) | |
| parent | c2237c2116ca551c0755821beadae3fac54547e7 (diff) | |
Merge branch 'master' of eclectronics.org@eclectronics.org:rotor
Diffstat (limited to 'rotord/src/libavwrapper.cpp')
| -rwxr-xr-x | rotord/src/libavwrapper.cpp | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/rotord/src/libavwrapper.cpp b/rotord/src/libavwrapper.cpp index a19e01a..673c2be 100755 --- a/rotord/src/libavwrapper.cpp +++ b/rotord/src/libavwrapper.cpp @@ -76,6 +76,18 @@ int64_t seekFunction(void* opaque, int64_t offset, int whence) } +void libav::maybeInitFFMpegLib() +{ + if (b_is_one_time_inited) + return; + av_register_all(); + avcodec_register_all(); + avformat_network_init(); + b_is_one_time_inited = true; +} + + + ///////////////////////////// // AVPacketWrapper methods // ///////////////////////////// @@ -484,15 +496,6 @@ void libav::decoder::initialize() maybeInitFFMpegLib(); } -void libav::maybeInitFFMpegLib() -{ - if (b_is_one_time_inited) - return; - av_register_all(); - avcodec_register_all(); - avformat_network_init(); - b_is_one_time_inited = true; -} bool libav::decoder::avtry(int result, const std::string& msg) { if ((result < 0) && (result != AVERROR_EOF)) { @@ -508,7 +511,6 @@ bool libav::decoder::avtry(int result, const std::string& msg) { - /////////////////////////// // encoder methods // /////////////////////////// |
