Thanks Achim and Alastair, I have solved the issue with the text by setting the font size using pixels to units and looking at the resultant size - it's always the same so I can just use that value, and do all the calculations in my app, then use an input to pixels to units into the Y position of the sprite. Once I realized that everything is center based and not flipped, I got the dimensions right and it works like a charm.
I'll have another think about the random choice of animations. I could do the choosing in my app and just fire off the new value and get it to disable the old animation and enable the next, but the thing is that I want to fade one out and the next one in, and I'm not currently sure how to trigger that. Thanks for the pointer to those specific patches - I'll have a look at them and see which ones are of use to me for this task. I haven't really done a lot of research and exploring for this one yet, so will have a decent play before bothering people with too many silly questions… Regards Gideon On 11/07/2012, at 5:15 PM, Achim Breidenbach <[email protected]> wrote: > Hello Gideon, > > regarding the image height: You also could feed in the y-position where the > text should be above (or below) and calculate the y position of the sprite in > your composition depending on this value and the half text image height. With > this, you don't need to know the text height outside your composition. > Anyways: QuartzComposer is "value-pull-based" which means, that only such > patches gets processed that are currently needed to calculate any output on > screen. Your sprite is the first one to be executed. This patch asked their > input patches for their output values which then recursively ask their > previous patches for their outputs, and so on. this gives sometimes the issue > of values are coming up a frame later than expected. > > Your random timer problem can be solved on different ways. The hard way is to > use the native QC patches, like Stop Watch, Random, Sample&Hold, > Watcher-Patch and Pulse-patches. The other way would be to use the JavaScript > to implement this in a short state machine. This is for sure the easier way, > but the current JavaScript implementation make some trouble if you running > QuartzCompositions in a host app. Thats why we choose to use a LUA patch to > implement this kind of logics. > > best, > > Achim Breidenbach > Boinx Software > > _______________________________________________ Do not post admin requests to the list. They will be ignored. Quartzcomposer-dev mailing list ([email protected]) Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/quartzcomposer-dev/archive%40mail-archive.com This email sent to [email protected]

