Forum

Touch Buffer with multitouch ir frame

I’m playing around with an IR multitouch frame, I’m slowly moving my patches over to VL, but am struggling a bit to try to replicate this particular patch.

Basically it takes the touches that occur on the touch frame, and keeps their XY coordinates after they have been released, and give me time to make them disappear slowly. Ideally I’d like to get this patch working right before trying to replicate in VL.

There must be a better way to do this?

100 Touch Buffer.v4p (15.0 KB)

these kind of things are much easier in VL:

  • make a data type for a touch event
  • as soon as you get a new touch point, create a new instance of your data type and add it to a spread
  • when it disappears start a timer/monoflop or the like inside your data type to calculate a value to fade it out and eventually remove it from the spread

this is almost a 1 to 1 implementation of this particle tutorial:

only difference is that you calculate the alive value inside the particle with a timer and output it as a pin to connect it to the Keep of the ForEach loop outside.

does this get you started?

AspectRatio is a little awkward with vl, but besides that, it is easier

@velcrome can you please elaborate on this (preferrably in a new topic)?

Hi Joreg,

Thanks for the info, was really useful, got some great stuff happening with the mouse, but the ir touchframe is proving more difficult…

I might need a bit more hand holding to get thru this, I’ve tried to follow, but just getting a bit stuck…Spray.7z (6.5 KB)