gesture

Multiple Interactions with Sprite

scalf's picture

Hello,

I have been trying to make a slider that responds to direct interaction (mouse) and also to 2 finger drags (magic pad). So that I can click and drag the slider to a position and/or use a 2 finger gesture to drag the slider into a new position also. Sort of like how the song timeline interaction on itunes works.

The problem I have had is getting the values to blend together. For instance, when I click and drag (Mouse) the slider from the origin to a value the slider reverts to the initial position before moving in a (Gesture) making the blending between interactions jerky.

I'd ideally like to have this slider respond to mouse clicks, gestures, and any OSC input I define. The issue is getting the values to merge together without jerky transitions.

I know there is a real good way to do this. They are all over in most programs, how can this functionality be emulated in Quartz? It's like the 2 Finger Drag Patch needs to have an updated value of where the slider is when I click it that way there is not a gap between values when the interactions are switched.

Thanks for any suggestions

You'll need 1024's Selector Plugin (Handy anyways) http://1024d.wordpress.com/qc-plugins/

Custom Multi-Touch Gestures (Composition by dust)

Author: dust
License: (unknown)
Date: 2009.09.12
Compatibility: 10.6
Categories:
Required plugins:
(none)

so i have made a new source file for custom multi-touch gesturing using the tuio protocol. this is using the same method i have been doing before but i have added the multi-touch environment as well a time element for added positive gesture results. i was going to use the value historian and parse out my arrays for a copy and paste into java script so i can have some pre recorded gestures but the VH isn't working for me in SL. i have recoded a two min video to verify and explain the gesture recording process as it relates to recording and the run-time evaluation mode in order to match a gesture. my tolerance settings are pretty tight .01 on x an y and point .05 on time.

with my last attempt i was only matching the sum total of my gestures x pos which was a little flaky. with this iteration i am doing a true point to point match with three elements and a sum total tolerance as well. to start recording a gesture you need to put one finger down and double tap with the second finger then draw your gesture. the global time of the gesture is 2 seconds so if you are recording gestures keep that in mind. to enter runtime evaluation you need to touch down with all 3 fingers. once you have enabled the eval you can do your gesture at anytime. something i will add in the future is a offset to x and y so no matter where you are on the screen the evaluation will be the same in addition im going to add some square roots to evaluate multiple size gestures. right now this is only doing a 1-1 map at the original scale.

http://si02.info/mt_gesture.mov

so this is a 10.6 comp but it should be safe down to 10.4. the requisite plug ins are gl-tools but that is only showing some cursor triangulation and not required for the gesture map to work. maybe there is a circle from 10.6 but again that is only for drawing a cursor and not needed.