Building ffdshow
Prerequisites
TortoiseSVN or any other SVN client (getting the revision number relies on TSVN though)
MinGW (4.6.2 recommended) xvidvideo.ru MinGW or XhmikosR or TDM's GCC/mingw32 Builds
For the MSVC 2010 builds: Microsoft Visual Studio 2010 Professional Edition (90-day Trial) or Visual C++ 2010 Express Edition (Free)
For the ICL builds: Intel Parallel Composer 2011 ($399 or 30 day evaluation) (If you plan to use Intel Parallel Composer 2011 read below)
Microsoft DirectX SDK June 2010
Yasm (Download the Win32 version if you are not sure which one to get and rename the file to â€Ĺ›yasm.exe”)
Optionally:
Microsoft Visual Studio 2010 SP1
Inno Setup Unicode (make sure you download the Unicode version and you install the Inno Setup Preprocessor while installing the pack)
MSYS
Getting the source code
Create a blank directory whose full path does not contain any spaces. Assuming you have installed TortoiseSVN, right click the directory in Windows Explorer, choose â€Ĺ›SVN Checkout” from the context menu.
Enter â€Ĺ›https://ffdshow-tryout.svn.sourceforge.net/svnroot/ffdshow-tryout/” as the URL of the repository. This would check out all branches of the source code, so if you are only interested in one particular branch (like â€Ĺ›trunk”, which is where the completed changes are added and where releases are again branched from), click on the ”â€Ĺšâ€ť button next to the repository URL list box and select the desired branch.
Installing prerequisite software
Installing Microsoft Visual Studio 2010
The required components are:
Visual C++ Tools > Win32 Tools
Visual C++ Run-time Libraries
Visual C++ Class & Template Libraries
Optionally:
x64 Compilers And Tools if you want to build the 64-bit version
Installing Microsoft DirectX SDK
The required component is:
DirectX Headers and Libs
Configuring Compilers
Intel Parallel Composer 2011
The ICL12 project files require that you have MSVC 2010 installed. All ffdshow components are built with ICL12 except for the components which MinGW/GCC is used. Just open the solution file ffdshow_icl12.sln and build Release|Win32.
ICL12 can compile ffmpeg. It is slow and may or may not work. A lot of optimized CPU specific code is disabled because ICL12 for Windows does not fully support GCC/GAS style inline assembler. If it works and can reproduce the same bugs that are found in GCC builds, you can use ICL12 for debugging purpose.
Configuring MinGW
Assuming that MinGW was installed to C:\MinGW, browse to C:\MinGW\bin:
Make a copy of 'mingw32-make.exe' and name it 'make.exe'
Make a copy of 'gcc.exe' and name it 'cc.exe'
Put 'yasm.exe' in the 'bin' directory
The first two steps are required for 'TDM's MinGW', and can be skipped when using the custom MinGW installer or any other MinGW.
An alternative method to renaming (and the preferred one) is to set the following environment variables (adjust the paths to your paths):
MINGW32=C:\MinGW
MSYS=C:\msys\1.0
Path=%MINGW32%\bin;%MSYS%\bin;
Compiling the project
ffmpeg.dll must be compiled using GCC.
Xvidcore has a much better performance (+30% speed gain) when compiled with GCC so you better compile Xvidcore with GCC too.
The same goes for KernelDeint.
The rest of the project can be compiled using Visual Studio or ICL.
Make command line options
To build dlls using MinGW, launch MSYS or cmd.exe (if you have added the needed environment variables) and go to the ffdshow source directory.
Type:
make
or if you have a quad core CPU:
make -j4
This should build x86 version of ffdshow.
If you are building the 64-bit version, type:
make 64BIT=yes
or if you have a quad core CPU:
make -j4 64BIT=yes
Compiling with MinGW
assuming you added MinGW\bin folder to the path, launch MSYS or cmd.exe and navigate ('cd') to each of the following directories:
src\ffmpeg
src\imgFilters\KernelDeint
src\codecs\xvidcore
inside each directory, type 'make' and press Enter.
OR you can browse to the src dir and run make. All dlls which are meant to compile with GCC will be compiled.
There's even a â€Ĺ›MakeAll.bat” batch file in the root dir for those who prefer that.
Choosing the best compiler
MSVC can build most files of ffdshow, but this is not always recommended:
libavcodec, libmpeg2, xvidcore: These files are originally Linux projects. GCC should be used for release builds. MSVC may be able to compile some of these, which is useful for debugging purposes. Also note that libmpeg2 is faster when compiled with ICL (~+15%).
KernelDeint, TomsMoComp: For best performance, GCC is preferred.
ffdshow.ax: MSVC or ICL12. ICL12 is faster when filters are used, while MSVC is good enough for most cases.
Installing the files you have just built
After building ffdshow.ax, call bin\register.bat and install the new files. The 'bin' directory is the new installation directory, do not copy the files to â€Ĺ›Program Files\ffdshow”. ffdshow.ax requires that the dlls are in the same directory.
You have to double click bin\register64.bat manually if you are building x64 version (see the bat for the reason).
Creating an installer
Double click bin\distrib\InnoSetup\ffdshow_installer.iss. Read the first five lines and enter appropriate values. Press F9 to build or Ctrl+F9 if you use InnoIDE.
Note: Don't use ISTool since it has problems with Unicode.
Wyszukiwarka
Podobne podstrony:
CompilationMXBeanCompileDB (2)compilar linuxcompilar dosCompilerDataNoch ein PIC CompilerCompileInv3stateProjects Compil32 manifestCompiledScriptcompilation?pendency in implementation?D92496CompilercompilerCompilationMXBeanjava lang Compileravr compiler 8hcompiler[Papermodels@emule] GPM Paper Model Compilation VIII (osloskop net) spiswięcej podobnych podstron