**Dirac patch for ffmpeg **Tested with ffmpeg cvs version dated 06-08-2005 **Author: dirac_dev@sourceforge.net Dirac is an open-source video codec currently under development. Both the encoder and decoder have been integrated with ffmpeg. This patch is only a basic integration such that only the salient paremeters are currently passed from ffmpeg to Dirac. As Dirac develops, especially with the integration of a formalised bit-stream syntax, then more complex screnarios can be dealt with. Encoded Dirac files, with the right patch, can be played back using MPlayer. Please feel free to modify/add-to the code. These are the instructions for enabling Dirac support in ffmpeg source code. 1. Download Dirac 0.5.4 from http://sourceforge.net/projects/dirac/ 2. Unpack the Dirac source tar xvzf dirac-0.5.4.tar.gz 3. Build and Install cd dirac-0.5.4 ./configure make make install The last step installs the Dirac share encoder and decoder libraries in /usr/local/lib (which is the default install point). 3. Download ffmpeg cvs version dated 06-08-2005 http://www2.mplayerhq.hu/MPlayer/cvs/FFMpeg-20050806.tar.bz2 (NOTE that the patch also works with CVS snapshot up until 16-08-2005. However, CVS snapshots were not available for dates past 6-Aug-2005 on the FFmpeg server at the time this note was written). 4. Unpack the source tar xjvf FFMpeg-20050806.tar.bz2 5. Apply the patch cd FFMpeg-20050806.tar.bz2 patch -p1 < FFMpeg-20050806-dirac-0.5.x.patch 6. Build and Install ./configure --enable-dirac make make install The option '--enable-dirac' must be used during configuration in order to pick-up the Dirac code during building. pkg-config is used to determine if dirac is available. Note that on some systems pkg-config is not available by default and will have to be installed. Sample Usage: (encoding) ffmpeg -s 720x576 -i input_file.yuv -vcodec dirac -qscale 15 -f rawvideo dirac_output.drc Currently, the output from the encoder is exactly as it is written to the .drc encoded file ( hence the '-f rawvideo' output). Dirac bit-rate is controlled by a quality-factor (currently a basic intepretation from qscale. A qscale of 1 maps to dirac uality factor 10 and 30 maps to quality factor 1) (decoding) ffmpeg -i input.drc -f rawvideo output.yuv Dirac can also be invoked via ffmpeg using transcode after applying the transcode patch. transcode -i input.avi -x raw -i raw_input.avi -y ffmpeg -F dirac,null -o dirac_output.avi