Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Making something happen for exactly 1 frame



Here is an example which will toggle between two input values every frame on Tiger.

var n0 = inputs[0]==undefined?0:inputs[0];
var n1 = inputs[1]==undefined?0:inputs[1];
var state = outputs[1]==undefined?0:outputs[1];

if (state == 0) {
   outputs[0] = n0;
   outputs[1] = 1;
}
else {
   outputs[0] = n1;
   outputs[1] = 0;
}

The idea is that i have an internal state variable that i use to determine which variable to output and then i flip it.
.xX


Alex Drinkwater wrote:
Hi Alessandro,

thanks for getting back to me.
Could you possibly give me a couple of pointers as to how I would go about doing that?


Cheers,

alx



On 11 Jul 2007, at 19:35, Alessandro Sabatelli wrote:

You can use JavaScript to do this.
.xX

Alex Drinkwater wrote:
Hi,

I'm trying to create a composition that freezes the input movie-stream a certain number of times over a given time-period (creating the effect of a reduced frame-rate). The Accumulator node does the job of freezing the image just fine, but I need to be able to set a minimum time so that the Accumulator's 'Accumulate' parameter is always turned on for a minimum of 1 frame. I'm currently finding that the Accumulator is sometimes not switched on for long enough to 'catch' a frame. This varies according to the frame-rate the composition is running at and can lead to unpredicatable behaviour.

Anyone any idea how I would achieve this?


alx
http://www.toneburst.net
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/email@hidden



This email sent to email@hidden


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/email@hidden



This email sent to email@hidden

_______________________________________________ Do not post admin requests to the list. They will be ignored. Quartzcomposer-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/quartzcomposer-dev/email@hidden

This email sent to email@hidden
References: 
 >Making something happen for exactly 1 frame (From: Alex Drinkwater <email@hidden>)
 >Re: Making something happen for exactly 1 frame (From: Alessandro Sabatelli <email@hidden>)
 >Re: Making something happen for exactly 1 frame (From: Alex Drinkwater <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.