Post
by Macciza » 10 Dec 2012 02:04
Hi
I think 'context' is important and you should try thinking more Lemur rather than try making Lemur think elsewise . . .
Arrays don't truncate to shortest when operated upon - because of the context in which they are used, a row of switches, lights etc
The best debugging method is simply to put parts of your equation into a Monitor.value
then you see vec1==vec2 returns an array {vec1-vec2} not simply a binary 0-1, T/F . . .
Comparisons can be done in many ways, without iterating as well, avoiding the loops
if x-y=0 then x=y
(firstof(vec1-vec2)==sizeof(vec1))&&(sizeof(vec1)==sizeof(vec2)) -
I find that you use too many loops in your functions for my liking . . .
Another option is conversion
arraytostring(vec1) == arraytostring(vec2) works a charm . . .
Cheers
MM
iMac 2.8G i7 12G 10.6.8/10.7.2, Legacy Dexter/Lemur, Liine Lemur/iPad2, KMI SoftStep, 12Step & QuNeo , B-Controls, Mackie C4 etc
MaxMSP, Live Suite, Native Instrument stuff, etc Modified Virtual Guitar System etc All Projects/Modules © CC-BY-NC-SA[*][/b]