Fantastick bug & iPad

Apr 17, 2012 at 3:58pm

Fantastick bug & iPad

Hello everyone,

this is the first time I write here.
I’m writing a Max patch that would allow me to take advantage of Fantastick’s multitouch capabilities to build intelligent musical instruments for disabled kids.
what I’d like to do is to recognize the number of fingers pressing simultaneously in a section of the iPad, and trigger events accordingly.

I have one problem though: at an apparently random rate, when using more than 1 finger at a time, Fantastick seems to send double messages (either BEGINNING position, or MOVING position or ENDING position).
useless to say, that makes the instrument unusable.

I tried to build a little “filter” for it, but it didn’t work out well.
I was wondering if any of you had experienced and solved this before.
I couldn’t find anything else on the internet on the subject.

I would really appreciate your help.
this is part of the patch I have so fare, I hope it’s clear.

{
“boxes” : [ {
"box" : {
"maxclass" : "newobj",
"text" : "p filter",
"id" : "obj-56",
"fontname" : "Arial",
"numinlets" : 1,
"numoutlets" : 1,
"fontsize" : 12.0,
"outlettype" : [ "" ],
“patching_rect” : [ 15.0, 58.0, 43.0, 20.0 ],
“patcher” : {
“fileversion” : 1,
“rect” : [ 362.0, 193.0, 432.0, 324.0 ],
“bglocked” : 0,
“defrect” : [ 362.0, 193.0, 432.0, 324.0 ],
“openrect” : [ 0.0, 0.0, 0.0, 0.0 ],
“openinpresentation” : 0,
“default_fontsize” : 12.0,
“default_fontface” : 0,
“default_fontname” : “Arial”,
“gridonopen” : 0,
“gridsize” : [ 15.0, 15.0 ],
“gridsnaponopen” : 0,
“toolbarvisible” : 1,
“boxanimatetime” : 200,
“imprint” : 0,
“enablehscroll” : 1,
“enablevscroll” : 1,
“devicewidth” : 0.0,
“boxes” : [ {
"box" : {
"maxclass" : "newobj",
"text" : "pipe 0 0 0 1",
"id" : "obj-26",
"fontname" : "Arial",
"numinlets" : 4,
"numoutlets" : 3,
"fontsize" : 12.0,
"outlettype" : [ "", "", "" ],
“patching_rect” : [ 203.0, 119.0, 73.0, 20.0 ]
}

}
, {
“box” : {
“maxclass” : “newobj”,
“text” : “unpack 0 0 0″,
“id” : “obj-4″,
“fontname” : “Arial”,
“numinlets” : 1,
“numoutlets” : 3,
“fontsize” : 12.0,
“outlettype” : [ "int", "int", "int" ],
“patching_rect” : [ 19.0, 200.0, 79.0, 20.0 ]
}

}
, {
“box” : {
“maxclass” : “newobj”,
“text” : “if $i3>10 then bang else out2 $i1 $i2 $i3″,
“id” : “obj-3″,
“fontname” : “Arial”,
“numinlets” : 3,
“numoutlets” : 2,
“fontsize” : 12.0,
“outlettype” : [ "", "" ],
“patching_rect” : [ 19.0, 276.0, 223.0, 20.0 ]
}

}
, {
“box” : {
“maxclass” : “newobj”,
“text” : “unpack 0 0 0″,
“id” : “obj-57″,
“fontname” : “Arial”,
“numinlets” : 1,
“numoutlets” : 3,
“fontsize” : 12.0,
“outlettype” : [ "int", "int", "int" ],
“patching_rect” : [ 19.0, 57.0, 79.0, 20.0 ]
}

}
, {
“box” : {
“maxclass” : “newobj”,
“text” : “if $i1==$i4 && $i2==$i5 && $i3==$i6 then bang else out2 $i1 $i2 $i3″,
“id” : “obj-35″,
“fontname” : “Arial”,
“numinlets” : 6,
“numoutlets” : 2,
“fontsize” : 12.0,
“outlettype” : [ "", "" ],
“patching_rect” : [ 19.0, 159.0, 370.0, 20.0 ]
}

}
, {
“box” : {
“maxclass” : “outlet”,
“id” : “obj-2″,
“numinlets” : 1,
“numoutlets” : 0,
“patching_rect” : [ 370.0, 276.0, 25.0, 25.0 ],
“comment” : “”
}

}
, {
“box” : {
“maxclass” : “inlet”,
“id” : “obj-1″,
“numinlets” : 0,
“numoutlets” : 1,
“outlettype” : [ "" ],
“patching_rect” : [ 19.0, 13.0, 25.0, 25.0 ],
“comment” : “”
}

}
],
“lines” : [ {
"patchline" : {
"source" : [ "obj-26", 2 ],
“destination” : [ "obj-35", 5 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-57", 2 ],
“destination” : [ "obj-26", 2 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-26", 1 ],
“destination” : [ "obj-35", 4 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-57", 1 ],
“destination” : [ "obj-26", 1 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-57", 0 ],
“destination” : [ "obj-26", 0 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-26", 0 ],
“destination” : [ "obj-35", 3 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-1", 0 ],
“destination” : [ "obj-57", 0 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-57", 2 ],
“destination” : [ "obj-35", 2 ],
“hidden” : 0,
“midpoints” : [ 88.5, 144.0, 168.899994, 144.0 ]
}

}
, {
“patchline” : {
“source” : [ "obj-57", 1 ],
“destination” : [ "obj-35", 1 ],
“hidden” : 0,
“midpoints” : [ 58.5, 144.0, 98.699997, 144.0 ]
}

}
, {
“patchline” : {
“source” : [ "obj-57", 0 ],
“destination” : [ "obj-35", 0 ],
“hidden” : 0,
“midpoints” : [ 28.5, 78.0, 28.5, 78.0 ]
}

}
, {
“patchline” : {
“source” : [ "obj-35", 1 ],
“destination” : [ "obj-4", 0 ],
“hidden” : 0,
“midpoints” : [ 379.5, 189.0, 28.5, 189.0 ]
}

}
, {
“patchline” : {
“source” : [ "obj-3", 1 ],
“destination” : [ "obj-2", 0 ],
“hidden” : 0,
“midpoints” : [ 232.5, 305.0, 275.5, 305.0, 275.5, 266.0, 379.5, 266.0 ]
}

}
, {
“patchline” : {
“source” : [ "obj-4", 0 ],
“destination” : [ "obj-3", 0 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-4", 1 ],
“destination” : [ "obj-3", 1 ],
“hidden” : 0,
“midpoints” : [ 58.5, 247.5, 130.5, 247.5 ]
}

}
, {
“patchline” : {
“source” : [ "obj-4", 2 ],
“destination” : [ "obj-3", 2 ],
“hidden” : 0,
“midpoints” : [ 88.5, 247.5, 232.5, 247.5 ]
}

}
]
}
,
“saved_object_attributes” : {
“fontname” : “Arial”,
“default_fontface” : 0,
“default_fontname” : “Arial”,
“globalpatchername” : “”,
“fontface” : 0,
“default_fontsize” : 12.0,
“fontsize” : 12.0
}

}

}
, {
“box” : {
“maxclass” : “newobj”,
“text” : “mxj net.udp.recv @port 6661″,
“id” : “obj-22″,
“fontname” : “Arial”,
“numinlets” : 1,
“numoutlets” : 2,
“fontsize” : 9.0,
“outlettype” : [ "", "" ],
“patching_rect” : [ 15.0, 7.0, 144.0, 17.0 ]
}

}
, {
“box” : {
“maxclass” : “newobj”,
“text” : “unpack 0 0 0″,
“id” : “obj-23″,
“fontname” : “Arial”,
“numinlets” : 1,
“numoutlets” : 3,
“fontsize” : 12.0,
“outlettype” : [ "int", "int", "int" ],
“patching_rect” : [ 15.0, 211.0, 79.0, 20.0 ]
}

}
, {
“box” : {
“maxclass” : “newobj”,
“text” : “route B M S E X V”,
“id” : “obj-14″,
“fontname” : “Arial”,
“numinlets” : 1,
“numoutlets” : 7,
“fontsize” : 9.0,
“outlettype” : [ "", "", "", "", "", "", "" ],
“patching_rect” : [ 15.0, 33.0, 100.0, 17.0 ]
}

}
],
“lines” : [ {
"patchline" : {
"source" : [ "obj-22", 0 ],
“destination” : [ "obj-14", 0 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-14", 0 ],
“destination” : [ "obj-56", 0 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
, {
“patchline” : {
“source” : [ "obj-56", 0 ],
“destination” : [ "obj-23", 0 ],
“hidden” : 0,
“midpoints” : [ ]
}

}
]
}

#63037
Apr 17, 2012 at 5:12pm

I had the same problem with FantaStick..
here is a patch that should help you.
(it translate Fantastick multitouch messages to TUIO-like messages : addCursor, updateCursor, …)

(it’s part of my MMF-fs framework : http://www.mathieuchamagne.com/2010/08/25/mmf-fantastick/ )

– Pasted Max Patch, click to expand. –

Mathieu

#227493
Apr 17, 2012 at 5:45pm

this is EXACTLY what I needed.
I am so greatful, and thank you for the super-quick reply!

Andreas

#227494

You must be logged in to reply to this topic.