This past week, I'd been finding a scenario where movie playback on something was doing an annoying halt at an unpredictable time, inside of QC. With the qtz running in an actual Xcode application (not the Quartz Composer editor), I don't think I would ever notice the little "tick". It was very minimized in comparison to how it exhibited itself in the Quartz Composer (editor).app.
After looking at it more, I decided, "why not see what happens if I undo the macro?". The patch itself had multiple input splitters running to it, and "exploding macro" revealed that it had more inside.
So, in order for the value to get propagated to the port of a patch that could do something to it, it was already going through two superficial patches (that unfortunately do execute code, and rob cycles), and an additional macro layer, adding another port. Exploding macro made it more obvious that there were two input splitters going on, when may not have been as immediately obvious. Before removing those, I simply ran the composition. The little tick in movie playback disappeared in the actual QC Editor, and was just as unnoticeable in the app context. Movie playback wasn't flying (because of other issues with codec, patch, etc)., but the uneven seeming evaluation had vanished.
With QC, keeping things with a minimal amount of nesting of macros seems to be an important principle in keeping performance consistent.
It also seems that, in general, external providers and related processors should be placed at top level of the patch whenever possible; there is almost never any scenario where a composition can't be reorganized to achieve this.
(Photo Copyright Apple. Used for educational purpose :
Notwithstanding the provisions of sections 17 U.S.C. § 106 and 17 U.S.C. § 106A, the fair use of a copyrighted work, including such use by reproduction in copies or phonorecords or by any other means specified by that section, for purposes such as criticism, comment, news reporting, teaching (including multiple copies for classroom use), scholarship, or research, is not an infringement of copyright. In determining whether the use made of a work in any particular case is a fair use the factors to be considered shall include:)
- the purpose and character of the use, including whether such use is of a commercial nature or is for nonprofit educational purposes;
- the nature of the copyrighted work;
- the amount and substantiality of the portion used in relation to the copyrighted work as a whole; and
- the effect of the use upon the potential market for or value of the copyrighted work.