Fix av_frame_alloc use based on libavcodec version

This commit is contained in:
2017-09-06 22:10:19 +01:00
parent d30dee19be
commit b97a406daa
+3 -3
View File
@@ -233,10 +233,10 @@ Bool StreamHandlerLibav::openHandler( String strFilename, Bool bInput )
return false;
}
#ifdef FF_USER_CODEC_PARAM
m_cFrame = av_frame_alloc();
#if( ( LIBAVCODEC_VERSION_MAJOR >= 56 ) && ( LIBAVCODEC_VERSION_MINOR >= 0 ) )
m_cFrame = av_frame_alloc();
#else
m_cFrame = avcodec_alloc_frame();
m_cFrame = avcodec_alloc_frame();
#endif
if( !m_cFrame )
{