QCPatch Configuration
From QuartzCompositions.com the central source for Quartz Composer :: wiki
When implementing Custom Patches, the developer has the option to configure these parameters in a subclass of QCPatch.
| Table of contents |
[edit]
Patch Configuration (Class Methods)
[edit]
+ (int)executionMode;
Return a constant that specifies how this Patch is to be executed when evaluating the GFGraph.
Defaults to 0.
Return values:
- 0
- Numeric / Modifier / Generator --- green title bar
- 1
- "Consumer Patch" --- Renderer / Environment --- pink title bar --- not permitted to have Output Ports
- 2
- Source / Tool / Controller --- blue title bar
todo: document exactly how each executionMode differs
[edit]
Examples of 0 : Numeric / Modifier / Generator
[edit]
Examples of 1 : Renderer / Environment
[edit]
Examples of 2 : Source / Tool / Controller
- QCAudioInput
- QCIMServices
- QCMidiClock
- QCMidiControllers
- QCMidiNotes
- QCSyndication
- QCVideoInput
- QCiTunesDatabase
- QCBonjourServices
[edit]
+ (BOOL)allowsSubpatches;
Defaults to 0.
Return values:
- 0
- Not a Macro Patch; do not allow patches within this patch; patch rendered with round edges
- 1
- Macro Patch; allow patches within this patch; patch rendered with square edges
[edit]
Examples of 0
(everything else)
[edit]
Examples of 1
[edit]
+ (int)timeMode;
Controls whether the patch renders all the time, or only when inputs change / redraw / mouse and keyboard events. Maybe it controls more too.
Defaults to 0.
Return values:
[edit]
0
- If executionMode == 1, patch is only execute()d when inputs change / redraw / mouse and keyboard events
- If executionMode != 1, patch is only execute()d if connected to a Renderer patch, and only when inputs change / redraw / mouse and keyboard events
- "Timebase" menu option is hidden
[edit]
1
- If executionMode == 1, patch is constantly execute()d
- If executionMode != 1, patch is constantly execute()d if connected to a Renderer patch
[edit]
2
- If executionMode == 1, patch is only execute()d when inputs change / redraw / mouse and keyboard events
- If executionMode != 1, patch is only execute()d if connected to a Renderer patch, and only when inputs change / redraw / mouse and keyboard events
- "Timebase" menu option is hidden
(how does this differ from timeMode==0 ?)
[edit]
Examples of 0
(everything else)
[edit]
Examples of 1
- QCQuickTimePlayer
- QCClock
- QCInterpolation
- QCLFO
- QCParticleSystem
- QCPlasmaImage
- QCPsychedelic
- QCRandom
- QCSignal
- QCTime
[edit]
Examples of 2
[edit]
+ (unsigned int)stateVersion;
(unknown purpose)
Defaults to 0.
Return values:
- 0
- (unknown)
- 1
- (unknown)
[edit]
Examples of 0
(everything else)
[edit]

