The gestureCapture COMP records movement and then displays the curves as rendered lines. The outputs of
gestureCapture are a SOP containing all paths as polygonal lines, the rendered image, and a CHOP containing the number of lines. Internally you can access a CHOP and a SOP for every gesture recorded.
By default you click and draw on the panel. It uses the x and y position of the cursor over the component, plus the left-click mouse button state to start/run capturing each gesture. Random colors are artificially added via the Color page.
To record your own input channels, put any set of channels in input 1 of this component, like the channels from a Vive controller. If you have channels named
tz scaled in the XY range -1 to +1, you will see the paths in the default viewer.
In the second input, attach an on/off "select" channel to start, run and end the capturing of the gesture.
In the third input you can optionally send a “clear all lines” channel to signal to remove all lines. In the fourth input you can send a “undo” channel to signal to remove the last line drawn. Alternately you can clear and undo using the Clear and Undo pulse parameters.
For every frame while recording a gesture, a keyframe is generated for every incoming channel. Recording as keyframes enables the recorded data to be smoothed. Some parameters on the Gesture page set the threshold of motion, affecting whether keyframes are created or not. When the motion is deemed still, it will not add new keyframes. Channel groups like
tz has their own threshold of motion vs stillness, and you can set thresholds for other sets of channels.
Each gesture is stored as a component at
line2... It outputs 3 CHOPs and a SOP:
out1- CHOP - the raw captured channels.
out2- CHOP - the smoothed and generated channels. It contains 16 channels including channels that compute the gesture speed, velocity, direction and distance travelled, which can be readily used by your applications.
out3- SOP - the smoothed gesture as a polygonal line.
out4- CHOP - the length of time of the gesture, in seconds.
To watch the data while it is being gathered and processed, press the Keys and Chans buttons in the
gestureCapture panel to see floating data viewers.
The number of lines is stored in
ipar.Gesture.Nlines and output to
(2019 30K and later: The SOP has a '
width' attribute and is rendered with the Line MAT.)
Note: This component is set up by default to use '
u' and '
v' from the panel, '
select' from the panel left-click. '
tz' is set to 0, and random colors are artificially added. remove
sero_color or replace them if you wish.
Note: The moving dot is
gestureCapture/dotCycle1, an example of moving objects by sampling the gesture curves.
Parameters - Control Page
Help - Opens this page.
Version - Current version of this COMP.
Width - This value is the width of the stroke. This value is in pixels.
Blur - The amount of blur in pixels.
Clear - Clears all lines.
Undo - Clears the last line drawn.
Threshold Xlate Speed
Threshold Rotate Speed
Resample by Edge Length
Resamplelength - Forces the length of each stroke to be the value set in the “Edge Length” parameter.
Edgelength - The length of each stroke.
Keep Last Edge Point
Keeplast - Turning off this parameter will remove the ends of strokes that are less than the value in the ‘Edge Length’ parameter.
- Input 0 -
- Input 1 -
- Input 2 -
- Input 3 -
- Output 0 -
- Output 1 -
- Output 2 -
|• • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • • •|
An Operator Family that reads, creates and modifies 3D polygons, curves, NURBS surfaces, spheres, meatballs and other 3D surface data.
Each SOP has a list of Points. Each point has an XYZ 3D position value plus other optional attributes. Each polygon Primitive is defined by a vertex list, which is list of point numbers.
A built-in panel in TouchDesigner that contains a library of components and media that can be dragged-dropped into a TouchDesigner network.