Intro to After Effects plugin development for beginners
Building plugins for After Effects isn’t that quite simple. There are many ways to create a plugin for After Effects and it depends on the type of plugin you want to create. In this article I will explore the various tools/technologies you can use to create plugins for AE and their respective advantages and disadvantages.
1. Quartz Composer:
Quartz Composer is a visual programming tool, that helps artists and programmers create interactive compositions without the need to write a single line of code. The beauty of Quartz Composer is that, you can use various technologies like OpenGL, CoreImage, OpenCL, Quartz, CoreVideo and many other Mac OS specific layers with ease. The interface is node based and extremely easy to use, especially if you are familiar with a Node based application like Nuke, Houdini or Xpresso in Cinema4D. On the flip side, it is Mac only, that means there is no way you can use these compositions on Windows. If you have no prior programming experience, Quartz Composer is probably the best tool to begin with.
p. Now how do you create AE plugins from Quartz Compositions? Luckily, there are a couple of Amazing tools that help you do it. They are FxFactory Pro and Effect Builder AE. FxFactory Pro is CS5 compatible and it has many other advantages like, you can create plugins for FCP and Motion and synchronize all the presets. I have seen some beautiful plugins created with FxFactory and they all use Quartz Composer underneath. Effect builder AE is another tool from Pixlock, which I don’t think is compatible with CS5, but it provides a unique advantage i.e. you don’t need to install a whole bundle like FxFactory and you can distribute just your plugin with ease.
Pros:
Easy to learn, very artist friendly, no need to write any code.
Cons:
Mac-Only, dependent on third party frameworks.
2. Pixel Bender:
Pixel Bender is a technology created by Adobe that helps developers create Image manipulation kernels. It has an XML based language syntax and is very easy to learn if you have some sort of scripting or programming experience. Even if you don’t its very easy to pick up. Pixel Bender is a relatively young technology with a promising future. Right now, Pixel Bender support in After Effects is pretty basic, but it is enough to create some very cool plugins for After Effects. Now technically speaking, Pixel Bender doesn’t create After Effects ‘plugins’. But, After Effects recognizes Pixel Bender Kernel files and treats them as ‘Effect plugins’. If you want to know how Pixel Bender works, you can view my introductory tutorial.
Not going into too much details, Pixel Bender kernels treat every pixel individually. So every output pixel is processed individually and there is no way you can process the whole image since they don’t have memory. To understand better, take After Effects Expressions as an example. Expressions are calculated every frame and they don’t have any memory. In the same way, Pixel Bender kernels are processed for every pixel and no data from a previously processed pixel is available. Now, before you get all confused, watch the introductory tutorial for much detailed explanation. Pixel Bender doesn’t support timeline, native AE Camera, masks and other AE related controls but it is only a matter of time before Adobe integrates them. There are a lot of expectations on Pixel Bender and I am sure it is on Adobe’s high priority list. Also, there is no way you can encrypt the Pixel Kernel files for distribution, which means everyone can access the source code. This might be a concern if you are planning a big scale commercial plugin, but shouldn’t be a problem if you are developing a small sized plugin. I personally like the fact that you can’t encrypt the source, since there is a lot of knowledge you can learn from going through other people’s kernels.
Now, Pixel Bender is mostly used for image processing and other small utilities, but there are also some really heavy duty plugins. Also, you don’t need any Adobe Creative Suite products to create them, since Pixel Bender toolkit is a free download.
Pros:
Easy to learn syntax, supported by multiple Adobe Creative Suite products, no compatibility and dependency issues, Cross Platform.
Cons:
Each pixel is processed individually, no AE camera, timeline support, limited controls.
3.After Effects SDK:
Now, if you are sure that none of the above tools are enough to create your dream plugin, then you have to jump into the world of native AE SDK. The SDK as the name suggests it is just a kit that helps you create platform native plugins that communicate with After Effects and can render graphics/manipulate the layers/ do other things. Native plugins have a lot more control and enjoy many advantages over Pixel Bender kernels. But, they are not easy to create, which I’ll explain in a bit. You need an IDE to write the code and the SDK supports Xcode on the Mac, and Visual Studio on the Windows. Usually, most of the plugins if not all are written in C/C++. So, you have to learn the basics of the language first, which may or may not be a tedious task, depending on the person. Now if you have some sort of prior programming experience, it will be an easy ride, but if you don’t things can be really confusing. No matter, what language you write code, the principles of programming remain the same. So, if you are good at expressions/scripting you might wanna try the SDK since, I had no prior programming experience before and I picked it up in no time.
Contrary to the After Effects User community, developer community is very closed. Although there are some amazing people at the SDK forum that helped me a lot, there isn’t much information about the SDK except for this MacTech article that dates back to 1999. The reason for this is, developers are usually busy and the SDK is not that simple to explain to absolute beginners and ofcourse the commercial implications of more new developers ;). But, the people at the SDK forum always helped me whenever I need help and you have to be reasonable too. You can’t ask abstract questions like ‘How can I make flying texts?’. Always keep them related to the SDK and the programming issues. Unlike Pixel Bender kernel files, your code isn’t platform independent. You have to make changes according to the platform (Mac/Win) and the architecture(32/64 bit). That means, you have to code the same plugin in 4 different configurations each time. Creating plugins using the SDK isn’t as fancy as it sounds. 80% of the development time is spent to create platform specific UI’s, debugging and testing on various configurations and this can get really really boring. If you are planning to distribute the plugin, you have to know some sort of system level event handling and other platform specific calls too. It all sounds scary, but it is really satisfying to have your ideas implemented in a plugin.
Pros:
Complete control, very well integrated into AE.
Cons:
Difficult to learn, Prior programming experience is recommend, a lot of testing and debugging.
So beginners, hopefully this will help you to get started. Irrespective of any process, you need to have ample amount of time to develop plugins for After Effects, which may not be the case if you are a busy freelancer!