User Tools

Site Tools


build:devel_2.6

Writing your own plugins (2.6.xx)

You dont need to compile avidemux yourself to write your own plugins.<br> What you need is :

  • The avidemux source tree (get it from tarball or from svn/git)
  • Avidemux installed on your system, with the -dev files (namely 2.6/ADM_coreConfig.h and friends)
  • CMake and working toolchain installed

All

There are two samples available in the source tree, under myOwnPlugins folder. One is a dummy demuxer (not working), the other one is a working videoFilter (logo). They are mostly the same as the ones built by avidemux itself, except their CMakeLists.txt has been changed so that they are independant of avidemux build system. In other words, you can but these samples anywhere you like on your harddrive, and build them standalone.

You can get source from git using

git clone git://gitorious.org/avidemux2-6/avidemux2-6.git

For windows user, msysgit is available ( http://code.google.com/p/msysgit/downloads/list )

Windows

Requisites

Q4

The simplest is to install the Qt4 developement package (http://qt.nokia.com). It is fairly complete and contain a compiler/linker/ etc…

Important: Dont forget to add c:/Qt/xxx/mingw/bin to window path, else cmake will fail.

Cmake

You will need to install cmake http://www.cmake.org

Misc
Avidemux binaries

AVIdemux 2.6 nightly builds that contain the needed include builds can be downloaded from http://www.avidemux.org/nightly/win32/

They are built automatically every morning.

Cmake

Start cmake-gui.

  • where the source is : Select the folder myOwnPlugins/videoFilter
  • where binaries are : Select a new folder, for example myOwnPlugins/videoFilter/obj
  • Now click configure
  • The generator, for example, could be codeblocks mingw makefile
  • Select “Use default native compilers”
  • Add Entry : AVIDEMUX_SOURCE_DIR, type=string, path to avidemux source. For example c:/dev/avidemux-2.6
  • Add Entry : DO_COMMON, type boolean, value=true
  • Add Entry : CMAKE_INSTALL_PREFIX, type path, value where the binary of avidemux is installed. For example c:/dev/r6556

Switch to advanced view in cmake and click generate. Each time you have a red line with “not found”, click the … and select the appropriate lib/include dir. In most cases, xxxINCLUDE_DIR will be c:/Qt/xxx/mingw/include and XXX_LIB will be c:/Qt/xxx/mingw/bin/xxx.dll. That will happen for zlib, png, pthread.

It must be ok until SDL. If SDL and following fails, it is not important. When configuring is ok, click generate and load the resulting project in codeblocks.

CodeBlocks

  • Go to “Settings→Compiler and debugger”. Select gnu compiler and select the mingw32-gcc.exe and friends
  • Load the .cpb generated by cmake and build project. If everything goes well you should have the plugin generated.
build/devel_2.6.txt · Last modified: 2012/11/11 08:51 (external edit)