Object Orientated (OOP) Style with Feedback Module
If you are used to program object-orientated programming languages like Java or Objective-C it can sometimes get hard to make certain things in Quartz Composer. The patching-paradigm does not allow a use of “writing classes” and “make instances of that classes”. But you can nevertheless make something similar in Quartz Composer - utilizing the Feedback module in a macro patch.
The Feedback module does the following: it takes a published output and feeds it into the feedback-module. The value is in the next frame available at the Feedback outlet. With that module you can make things like incremental motion.
The input of the Feedback module is a “initial parameter” - that parameter will be fed in tot eh feedback outlet at the very first frame. From frame two on, that fed back parameter will be used.
To add new inlet/outlet to the Feedback module, just publish any value of the patch as a output-parameter. The Feedback will update its parameter instantly.
Notice: The feedback module must be inside a macro-patch to work properly.
With Iterator and a Structure you can instantiate some sort of “module array” and work a little like object-orientated style in Quartz Composer. Here I wrote a tutorial how to do it: Initialize Iterator with a defined set of values.