valgrind caught that AVFORMAT_NEW_STREAM() could be leaking pointers
when calling avcodec_alloc_context3(), if there's an existing context
already assigned. So we check and free it first, if necessary.
The audio_codec and video_codec vars have type AVCodecContext.
Renaming them to reflect that makes the code easier to follow.
A couple of places in FFmpegUtilities macros that also used
context variables named _codec got the same fix.
- Drop any FFmpeg version checks for versions older than 2.6
- Remove code that was only used in FFmpeg 2.4 or lower
- Add human-readable version comments to checks for
LIBFOO_VERSION_MAJOR. etc.
- Eliminate fprintf(stderr...) and non-threadsafe std::cerr
- Replace with thread-safe std:clog or ZeroMQ calls
- Clean up some formatting & ZeroMQ logging
- The new ordering (with the frame rate AFTER width and height) doesn't
match the other signature, but it *is* consistent with the Timeline
constructor, and it just feels more natural
- Added overloaded-function notes to doxygen strings in FFmpegWriter.h
- Also added a warning about the argument order mismatch above