Often, when I’m writing Pixel Bender content targeted for Flash Player, the original toolkit leaves something to be desired. Luckily, Joa Ebert created his PBDT plugin for Eclipse which was already a great step to streamline my workflow. Still, the lack of previewing would require switching back to the PB toolkit. And more often than not, that preview didn’t tell me much, as many of my PB projects consist of multiple filters that are dependent on eachother’s output.
So yesterday, I created Render Bender v0.1 (yes, that is some juvenile wordplay) strictly to suit my own needs, but it might just be useful for people out there with the same problem. It is designed to tackle the following issues:
- Eliminate the need of writing much AS3 code for PB code that might not even work. Instead generating an easy “proof of concept” method.
- Real Flash-based rendering (instead of simulated rendering of the toolkit, which does not expose runtime bugs)
- Running a sequence of consecutive Shaders, which may be dependent of a previous Shader or a previous run of an iterative sequence
- Easy integration with Eclipse and PBDT, without the need of switching applications.
- Have an easy way of demoing pixel bender effects in development
Essentially, it’s just a Flex App/Component that you need to add to a project, which contains nothing else except for perhaps some interactivity handling necessary for your effect. This way, you can then add your kernels to this project and have them compiled with PBDT. All you need to do is to set up an xml file (once) defining the assets and the kernel sequence. After that, it’s simply a matter of running the project after editing a kernel.
The documentation is a bit sparse at this point, but along with the Demo.mxml source file, it should be pretty clear.
- Render Bender on Google Code: The code comes with an example set of kernels, which is actually this effect. Be sure to check the documentation before getting started.
- Demo: Note: it is made to run locally compiled from a Flex project, so “import xml” will not work.
It’s in early stages, but it works for me :) I’ll be glad to hear questions, suggestions or bugs. I’m not sure how much time I can invest at this point, but I do have some ideas for future development. At this point, it uses the default Flex skin (3 or 4, depends on your sdk) to minimize compile time. If someone wants to create a minimal fast skin, feel free! :)