Welcome to %s forums

BrainModular Users Forum

Login Register

(script) when trunc, or round, make change

I need help on a Patch
Post Reply
23fx23
Member
Posts: 2545
Contact:

Unread post by 23fx23 » 17 Oct 2010, 07:57

ive got a scrolling system script that is based on a 0..1 range on input.

so when i multiply my scroll01 by maxscroll in the script i got my realscroll output:

scrollNBout := round (scroll01in * maxscroll)

I dlike the script to provide a pulse when the integer of ScrollNBout changes. I can't link the change code straight to
the 0..1 input since this one may change subtly without making a change on real rounded scroll...
I can simply put a haschg module out of the script
but this is more by curiosity, i fail to find what would be the 'how to full script', thoutgh making the difference between rounded and not rounded value, but it may be not necessary perfectly 0 i feel, well i got to try....maybe with a tolerance based on total...
mmmmm or do the callback also scan outputs? could do the job, damned never tested that yet...

any ideas from masterS, more generally if see what i mean, is it possible to trig some internal code when a rounded, or trunced variable changed, due to the trunc or round function?
is the subtract with tolerance check way to go? if so, i may keep my simple has change module after all..
i like to complexify things for nothing ;)

Who is online

Users browsing this forum: No registered users and 55 guests