Skip to main content
Glama

Create motion reactive

create_motion_reactive

Build a video-analysis chain exposing reactive motion and brightness channels to bind any parameter in TouchDesigner.

Instructions

Build a video-analysis chain that exposes ready-to-bind reactive channels — overall brightness plus frame-to-frame motion energy — on a Null CHOP. The camera counterpart to extract_audio_features: bind any parameter to op('…/motion_reactive/features')['motion'] and it responds to movement in front of the camera, or ['brightness'] to ambient light. A Sensitivity knob scales both. Creates a new baseCOMP under parent_path holding the source, a downsized monochrome analysis chain, and a 'features' Null CHOP output. Source can be the live camera (may prompt for macOS permission), a movie file, an animated synthetic pattern (for testing without a camera), or an existing TOP. Optical flow is unavailable on macOS, so direction isn't exposed. Returns a summary plus a JSON block with the container path, created node paths, the features Null path, the channel names, exposed controls, any node errors, and warnings (no preview image — the output is a CHOP, not a TOP).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sourceNoVideo source. 'camera' = live webcam/capture device (the real-world default; creating it may pop a one-time macOS camera-permission dialog — click Allow). 'file' = a movie file. 'synthetic' = an animated noise pattern, handy for testing without any device permission. 'existing_top' = analyze a TOP you already have.camera
movie_file_pathNoPath to a movie file to play as the source; used only when source='file'.
existing_top_pathNoPath of an existing TOP to analyze; used only when source='existing_top'.
analysis_resolutionNoThe video is downsized to this square resolution before analysis — small keeps it cheap (the reactive values barely change with size).
expose_controlsNoWhen true (default), expose a live 'Sensitivity' knob (a gain over every feature channel).
parent_pathNoParent network where the motion-reactive container is created (default '/project1')./project1
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description fully discloses behavioral traits: creates new nodes (mutates, consistent with readOnlyHint=false), may prompt for macOS camera permission, optical flow unavailable on macOS, output is CHOP not TOP, and returns a summary with JSON. This adds significant context beyond the annotations (destructiveHint=false, openWorldHint=true) without contradiction.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is detailed but well-structured: it starts with the main purpose, then explains usage, caveats, and return value. It is not overly long given the complexity, and every sentence adds value. Could be slightly more concise, but overall efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema, the description thoroughly explains the return value (summary plus JSON with paths, channel names, etc.). It covers all source options, permissions, macOS limitation, and output type. The tool has moderate complexity with 6 parameters, and the description provides sufficient context for an agent to use it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 100% schema coverage, the schema already describes each parameter. The description adds value by explaining practical details: source='camera' may prompt permission, source='synthetic' for testing, analysis_resolution rationale, and default parent path. This enriches understanding beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool builds a video-analysis chain exposing reactive channels (brightness and motion energy) on a Null CHOP. It uses specific verbs ('Build') and resource description ('video-analysis chain'), and distinguishes from siblings by mentioning it is the camera counterpart to extract_audio_features and listing alternative source types.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context for when to use this tool: for motion and brightness reactivity from camera or video. It mentions alternatives (extract_audio_features for audio) and caveats (macOS optical flow unavailable). However, it does not explicitly state when NOT to use it, such as if audio reactivity is needed instead.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Pantani/tdmcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server