Project

General

Profile

WIPVideo » History » Revision 3

Revision 2 (Saúl Ibarra Corretgé, 08/21/2013 04:00 PM) → Revision 3/43 (Saúl Ibarra Corretgé, 08/21/2013 04:08 PM)

h1. WIPVideo 

 Notes while video is a work in progress. 

 h2. Dependencies 

 The following dependencies are required to build PJSIP with video support (including H264) 

 * SDL 2 
 * ffmpeg (libavformat, libswscale, libavcodec, libavutil) 
 * libx264 

 Versions I have tried: 

 * SDL (2.0.0-7655) 
 * ffmpeg (2.0 release) 
 * libx264 (snapshot-20130806-2245-stable) 

 

 h2. Patches 

 If the above versions are used, PJSIP needs to be patched with the attached patch (avcodec.diff) or it won't compile. This does not occur when compiling it against the latest library versions on Debian unstable. 

 h2. Compiling dependencies 

 All dependencies will be compiled to a directory in the user's HOME directory: 

 <pre> 
 export MY_VIDEO_LIBS=$HOME/work/ag-projects/video/local 
 </pre> 

 h3. libx264 

 <pre> 
 ./configure --enable-shared --disable-avs --disable-swscale --disable-lavf --disable-ffms --disable-gpac --prefix=$MY_VIDEO_LIBS 
 make 
 make install 
 </pre> 

 h3. ffmpeg 

 <pre> 
 # Some exports 
 export PKG_CONFIG_PATH=$MY_VIDEO_LIBS/lib/pkgconfig 
 export CFLAGS=`pkg-config --cflags x264` 
 export LDFLAGS=`pkg-config --libs x264` 

 ./configure --enable-shared --disable-static --enable-memalign-hack --enable-gpl --enable-libx264 --prefix=$MY_VIDEO_LIBS 
 make 
 make install 

 # Clear CFLAGS and LDFLAGS 
 unset CFLAGS 
 unset LDFLAGS 
 </pre> 

 h3. SDL 

 <pre> 
 ./configure --disable-audio --prefix=$MY_VIDEO_LIBS 
 make 
 make install 
 </pre>