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)

Still trying to get this working… Hi folks, just to clarify…

I’m trying to use a multitouch surface to start some particle to emit, but only on the release of the touch, while touching I’d like the particle to remain on the touch xy, and then on release of the touchpoint fly away. My touch surface can handle 10 simultaneous touches at a time, I want to queue the positions so that when you release, the touch doesn’t return a null, but leaves the last position of that point. As each new touch point comes in I want to keep the last position for the duration of it’s lifetime, and then it can disappear.

hey superfly, nice example.
i tried to implement what i understood from your description and added comments. hope it is clear. (9.4 KB)

also have a look at this example. not exactly the same, but similar enough it could help you understand things:

Thanks heaps for that Joreg, been making some good progress, have added some acceleration, and am trying to pick a colour based on x location of each touch, then saving that colour for that particle on release. Wonder if you can have a quick look and see if you can see where I’ve gone wrong. I’ve added another concat, so that I can set the current position of the initial location of the fingers, and also draw the particles which have been given a colour.

What seems to be happening is the colours are shifting as new ones are added, and the update isn’t quite happening right… (13.3 KB)

very good. only a small error: have a look at the order of the inputs of the new Concat you added for the colors!

1 Like

Ah, gotcha… ha, too easy! Thanks!!

One thing that I had in my original non vl was that along with the release of the finger from the surface, it would also create a particle based on a y trigger, I divided the screen into 40, and used a s+h to collect the XY if the Y = a round number between 1 and 40. Sort of like if you had strings, and each time you pass a string it plays it, along with any note when you release your fingers from the surface.

I’ve pulled the points back in, but somethings not quite right…

Barspray - (15.0 KB)

i’m afraid i cannot follow this…can you maybe show a visualization of how this is supposed to look like?

Here’s a 4v example that shows the trigger, my touch monitor is flipped 90 degrees so the colour selection works right in touch, but not quite right with the mouse, but it’s more to see how when you move the mouse as it hits one of the 40 triggers vertically it fires off another bar.Touch Buffer.v4p (45.1 KB)

Been loving the patch @joreg, and been doing some variations, something that’s eluding me is I’ve been trying to get a single particle be emitted at the time of contact, I would do it with a togedge in vvvv, but haven’t figured it out to do the same operation in VL.

still not exactly sure i get what you want, but please have a look at the attached and let me know if you have any questions: (15.1 KB)

regarding the TogEdge: it is exactly the same in vl as in vvvv

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.