ofxFFGLSpoutBridge, an addon to write FFGL plugins


hi friends,
here you find the link to an addon I wrote to build FFGL plugins with OpenFrameworks.

With this addon, together with the related FFGL-SpoutBridge plugin (included in this repo, in the FFGL-Plugin directory), it is possible to use an openFrameworks application as a plugin for any software adopting the FreeFrame FFGL standard. I only tested it with Resolume Arena (a demo version can be downloaded here ) but it should work with the other hosts too.

Since integrating openFrameworks inside the plugin code has proven to be a hard task (I managed to make it work - sort of - with older OF versions but the code never was stable enough and it had bugs nobody managed to fix) the approach used here is different. Not the most elegant thing I could imagine, but it works. The plugin itself sends the texture it gets from host to the OF app via Spout texture sharing, the app gets it, implements arbitrary code and then sends the updated texture to the plugin that finally gives it back to host for further processing.

The plugin can implement parameters (only float ones in this version, but it is easy enough to extend the process to different types), their values are sent to the OF application every frame with an OSC packet.

The process looks a little cumbersome but the back-and-forward path is very fast and in practice there is no noticeable delay while implementing it in Arena (or any other VJ software).

Note: the openFrameworks app can be built either using 32 bits or 64 bits architecture, according to your taste, but the FFGL plugin must be 32 bits for Arena up to 5 and 64 bits for Arena 6 (and higher). For other hosts check the host documentation or just try and see which one works.

Of course this is a beta version, there will be bugs to fix but in my tests the overall process appeared to run smoothly. Let me know of your results if you try it.

Comments and remarks welcome,
happy coding!

FFGL plugin with controls in host (Resolume)