Fix H264 codec finding for libavcodec < 58.10.100 (#143)

This commit is contained in:
Gabi Alb 2020-01-15 20:09:11 +02:00 committed by Florian Märkl
commit 861c0dbaa3

View file

@ -23,6 +23,9 @@
VideoDecoder::VideoDecoder(ChiakiLog *log) : log(log)
{
#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(58, 10, 100)
avcodec_register_all();
#endif
codec = avcodec_find_decoder(AV_CODEC_ID_H264);
if(!codec)
throw VideoDecoderException("H264 Codec not available");