Search
j0ke.net Open Build Service
>
Projects
>
multimedia
:
EL5
>
mpeg4ip
> mpeg4ip-ffmpeg.patch
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File mpeg4ip-ffmpeg.patch of Package mpeg4ip
--- mpeg4ip-1.6.1/player/plugin/audio/ffmpeg/ffmpeg.h~ 2007-07-02 22:26:01.000000000 +0200 +++ mpeg4ip-1.6.1/player/plugin/audio/ffmpeg/ffmpeg.h 2008-08-26 17:07:24.000000000 +0200 @@ -26,7 +26,7 @@ #include "codec_plugin.h" extern "C" { #ifdef HAVE_FFMPEG_INSTALLED -#include <ffmpeg/avcodec.h> +#include <libavcodec/avcodec.h> #else #include <avcodec.h> #endif --- mpeg4ip-1.6.1/server/mp4live/audio_ffmpeg.h~ 2007-07-02 22:26:04.000000000 +0200 +++ mpeg4ip-1.6.1/server/mp4live/audio_ffmpeg.h 2008-08-26 17:15:49.000000000 +0200 @@ -25,7 +25,7 @@ #include "audio_encoder.h" extern "C" { #ifdef HAVE_FFMPEG_INSTALLED -#include <ffmpeg/avcodec.h> +#include <libavcodec/avcodec.h> #else #include <avcodec.h> #endif --- mpeg4ip-1.6.1/server/mp4live/video_ffmpeg.h~ 2007-07-02 22:26:05.000000000 +0200 +++ mpeg4ip-1.6.1/server/mp4live/video_ffmpeg.h 2008-08-26 17:16:07.000000000 +0200 @@ -25,7 +25,7 @@ #include "video_encoder.h" extern "C" { #ifdef HAVE_FFMPEG_INSTALLED -#include <ffmpeg/avcodec.h> +#include <libavcodec/avcodec.h> #else #include <avcodec.h> #endif --- mpeg4ip-1.6.1/configure.in.orig 2008-08-26 17:02:49.000000000 +0200 +++ mpeg4ip-1.6.1/configure.in 2008-08-26 19:28:09.000000000 +0200 @@ -487,7 +487,7 @@ if test x$have_ffmpeg_arg = xtrue; then AC_MSG_NOTICE([have enable ffmpeg $enable_ffmpeg]) FFMPEG_INC=-I${enable_ffmpeg}/libavcodec - FFMPEG_LIB="${enable_ffmpeg}/libavcodec/libavcodec.a -lz" + FFMPEG_LIB="-lavcodec -lz" saveCFLAGS="$CFLAGS" CFLAGS="$CFLAGS $FFMPEG_INC" AC_CHECK_TYPES([AVRational], , , [#include <avcodec.h>]) diff -burNp mpeg4ip-1.6.1/configure.in mpeg4ip-1.6.1-new/configure.in --- mpeg4ip-1.6.1/configure.in 2007-09-28 22:45:08.000000000 +0200 +++ mpeg4ip-1.6.1-new/configure.in 2008-10-10 22:09:56.469368599 +0200 @@ -512,7 +512,7 @@ if test x$disable_ffmpeg = xfalse; then if test x$have_ffmpeg = xtrue; then AC_DEFINE(HAVE_FFMPEG_INSTALLED, 1, [defined if ffmpeg is installed]) FFMPEG_INC= - FFMPEG_LIB="-lavcodec -lz $ffmpeg_add_libs" + FFMPEG_LIB="-lavcodec -lz $ffmpeg_add_libs $(pkg-config libswscale --libs --silence-errors)" AC_CHECK_TYPES([AVRational], , , [#include <ffmpeg/avcodec.h>]) AC_CHECK_MEMBERS(AVCodecContext.time_base, , , [#include <ffmpeg/avcodec.h>]) AC_CHECK_DECLS([avcodec_decode_audio2], , ,[#include <ffmpeg/avcodec.h>]) --- mpeg4ip-1.6.1/player/plugin/video/ffmpeg/ffmpeg.h 2007-07-02 22:26:03.000000000 +0200 +++ mpeg4ip-1.6.1-new/player/plugin/video/ffmpeg/ffmpeg.h 2008-10-10 22:16:05.176622742 +0200 @@ -27,7 +27,8 @@ #include "codec_plugin.h" extern "C" { #ifdef HAVE_FFMPEG_INSTALLED -#include <ffmpeg/avcodec.h> +#include <libavcodec/avcodec.h> +#include <libswscale/swscale.h> #else #include <avcodec.h> #endif --- mpeg4ip-1.6.1/player/plugin/video/ffmpeg/ffmpeg.cpp 2007-07-02 22:26:03.000000000 +0200 +++ mpeg4ip-1.6.1-new/player/plugin/video/ffmpeg/ffmpeg.cpp 2008-10-10 23:01:19.519476374 +0200 @@ -585,10 +585,16 @@ static int ffmpeg_decode (codec_data_t * from.data[ix] = ffmpeg->m_picture->data[ix]; from.linesize[ix] = ffmpeg->m_picture->linesize[ix]; } - - img_convert(&to, PIX_FMT_YUV420P, - &from, ffmpeg->m_c->pix_fmt, - ffmpeg->m_c->width, ffmpeg->m_c->height); +#ifdef HAVE_FFMPEG_INSTALLED + SwsContext *pSWSCtx; + pSWSCtx = sws_getContext(ffmpeg->m_c->width, ffmpeg->m_c->height, + ffmpeg->m_c->pix_fmt, + ffmpeg->m_c->width, ffmpeg->m_c->height, + PIX_FMT_YUV420P, SWS_BICUBIC, 0, 0, 0); + sws_scale(pSWSCtx, from.data, from.linesize, 0, ffmpeg->m_c->height, + to.data, to.linesize); + sws_freeContext(pSWSCtx); +#endif ffmpeg->m_vft->video_filled_buffer(ffmpeg->m_ifptr, ffmpeg->have_cached_ts ? ffmpeg->cached_ts : ts);