Fix av_frame_alloc use based on libavcodec version

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