https://svnweb.freebsd.org/ports/head/multimedia/vdr-plugin-osdpip/files/patch-ffmpeg3?view=markup https://bugs.gentoo.org/show_bug.cgi?id=575100 --- decoder.c.orig 2016-06-11 10:45:23.850303000 +0200 +++ decoder.c 2016-06-11 10:50:57.243181000 +0200 @@ -28,7 +28,7 @@ int cDecoder::Open() { - m_Codec = avcodec_find_decoder(CODEC_ID_MPEG2VIDEO); + m_Codec = avcodec_find_decoder(AV_CODEC_ID_MPEG2VIDEO); if (!m_Codec) { printf("codec not found\n"); @@ -40,8 +40,8 @@ printf("could not open codec\n"); return -1; } - m_PicDecoded = avcodec_alloc_frame(); - m_PicResample = avcodec_alloc_frame(); + m_PicDecoded = av_frame_alloc(); + m_PicResample = av_frame_alloc(); m_BufferResample = new unsigned char[400 * 300 * 4]; // size for RGBA32 #ifndef USE_SWSCALE m_PicConvert = avcodec_alloc_frame(); @@ -99,7 +99,7 @@ AVPicture pic_crop; struct SwsContext * context; - av_picture_crop(&pic_crop, (AVPicture *) m_PicDecoded, PIX_FMT_YUV420P, OsdPipSetup.CropTop, OsdPipSetup.CropLeft); + av_picture_crop(&pic_crop, (AVPicture *) m_PicDecoded, AV_PIX_FMT_YUV420P, OsdPipSetup.CropTop, OsdPipSetup.CropLeft); #ifdef FF_API_SWS_GETCONTEXT if (!(context = sws_alloc_context())) { printf("Error initializing scale context.\n"); @@ -126,9 +126,9 @@ #else context = sws_getContext(m_Context->width - (OsdPipSetup.CropLeft + OsdPipSetup.CropRight), m_Context->height - (OsdPipSetup.CropTop + OsdPipSetup.CropBottom), - PIX_FMT_YUV420P, + AV_PIX_FMT_YUV420P, #ifdef USE_NEW_FFMPEG_HEADERS - m_Width, m_Height, ConvertToRGB ? PIX_FMT_RGB32 : PIX_FMT_YUV420P, + m_Width, m_Height, ConvertToRGB ? AV_PIX_FMT_RGB32 : AV_PIX_FMT_YUV420P, #else m_Width, m_Height, ConvertToRGB ? PIX_FMT_RGBA32 : PIX_FMT_YUV420P, #endif @@ -140,7 +140,7 @@ #endif avpicture_fill((AVPicture *) m_PicResample, m_BufferResample, #ifdef USE_NEW_FFMPEG_HEADERS - ConvertToRGB ? PIX_FMT_RGB32 : PIX_FMT_YUV420P, + ConvertToRGB ? AV_PIX_FMT_RGB32 : AV_PIX_FMT_YUV420P, #else ConvertToRGB ? PIX_FMT_RGBA32 : PIX_FMT_YUV420P, #endif