Moving Shape β‘π ‘π π £π
A procedural mask that slides, grows, and bounces across the frame
- MASK
Every other mask node in this pack starts from something - a video, an audio signal, motion, a color. Moving Shape starts from nothing. Give it a canvas size and a shape, and it draws a square, circle, or triangle that travels from one point to another over your sequence, with its own easing and optional growth. No image or mask input required at all - it's a pure generator, which makes it handy for wipes, spotlight reveals, synthetic test masks, or just something animated to drive a compositing effect when you don't have (or don't want to derive from) real footage.
How it works
frame_width/frame_height set the canvas, num_frames the sequence length, shape picks square/circle/triangle, and rgb sets its color as a literal string like (255,255,255). Size is set as a percentage of the frame (shape_width_percent/shape_height_percent), and position is relative too - shape_start_position_x/y and shape_end_position_x/y run from -100 to 100, not pixels, so the shape travels from a start point to an end point over the animation.
movement_type is the easing curve for that travel - linear, ease_in_out, bounce, elastic - note this is a separate, smaller list than the temporal_easing options you'll see elsewhere in the pack (no none option here; movement always happens). grow lets the shape expand as it moves. palindrome plays the whole animation forward then reverses it within the same frame count, rather than just moving one-way. delay holds the shape static for a number of frames before the movement starts - useful for a beat of stillness before a reveal begins.
The inputs and outputs that matter
shape- square, circle, or triangle.shape_width_percent/shape_height_percent(default 50) - size as a percent of the frame.shape_start_position_x/y/shape_end_position_x/y(-100 to 100) - the travel path, relative to frame center, not pixels.movement_type- linear / ease_in_out / bounce / elastic.grow- expansion over the animation.palindrome/delay- reverse-and-repeat, and a static hold before motion starts.
Output is a single MASK - feed it straight into any masking or compositing node, or into FlexMaskWarp and friends if you want to layer the pack's other mask distortions on top of a clean synthetic shape.
How to install it
ComfyUI Manager: search "RyanOnTheInside", install, restart. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/ryanontheinside/ComfyUI_RyanOnTheInside
cd ComfyUI_RyanOnTheInside
pip install -r requirements.txt
then restart. Pure procedural drawing - no model download, and this node doesn't touch the pack's heavier audio or particle dependencies.
Common issues & troubleshooting
Shape doesn't move at all. shape_start_position_x/y and shape_end_position_x/y all default to 0 - if you leave the end position equal to the start, there's nothing to animate toward. Set an actual end position different from the start.
Shape ends up off-screen or clipped. The -100 to 100 position range is relative to the frame, not pixel coordinates, and it stacks with shape_width_percent/shape_height_percent - a large shape pushed to a position near Β±100 will run off the visible canvas. Bring the position closer to 0 or shrink the shape if it's getting clipped.
Movement looks abrupt instead of smooth. That's movement_type set to linear (constant speed, no easing) - switch to ease_in_out for a gentler start/stop, or bounce/elastic if you want overshoot.
Inputs (15)
| Name | Type | Default | Description |
|---|---|---|---|
| frame_width | INT | 5121β3840 | Width of each frame in pixels (1 to 3840) |
| frame_height | INT | 5121β2160 | Height of each frame in pixels (1 to 2160) |
| num_frames | INT | 301β120 | Number of frames in the animation sequence (1 to 120) |
| rgb | STRING | (255,255,255) | Color of the shape in RGB format (e.g., '(255,255,255)') |
| shape | COMBO | Type of shape to generate ('square', 'circle', 'triangle') | |
| shape_width_percent | FLOAT | 50.00β100 | Width of the shape as percentage of frame width (0 to 100) |
| shape_height_percent | FLOAT | 50.00β100 | Height of the shape as percentage of frame height (0 to 100) |
| shape_start_position_x | FLOAT | 0.0-100β100 | Starting X position relative to frame (-100 to 100) |
| shape_start_position_y | FLOAT | 0.0-100β100 | Starting Y position relative to frame (-100 to 100) |
| shape_end_position_x | FLOAT | 0.0-100β100 | Ending X position relative to frame (-100 to 100) |
| shape_end_position_y | FLOAT | 0.0-100β100 | Ending Y position relative to frame (-100 to 100) |
| movement_type | COMBO | Type of movement animation ('linear', 'ease_in_out', 'bounce', 'elastic') | |
| grow | FLOAT | 0.00β100 | Growth factor during animation (0 to 100) |
| palindrome | BOOLEAN | false | Whether to play the animation forward then reverse |
| delay | INT | 00β60 | Number of static frames at the start (0 to 60) |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| MASK | MASK | β |