Video Detection Feature Points

Finds corners and textured points in the video and follows each one from frame to frame with a stable id and its motion. Use it to attach particles or 3D objects to moving image content, to measure the motion of a scene or of the camera, or to stabilize an overlay.

A train passing a fixed camera, max points 300, min distance 12, trail 8: trails on the train, still points on the station.

A night street filmed by hand, same settings.

With track ON, each point is followed into the next frame. A lost point is removed, and new points are found on each frame to fill up to max points, with new ids. detector, quality and min distance choose these new points only: the points already tracked stay. On a fixed camera nearly every point lasts (96 to 100 % of them kept from one second to the next on a passing train), while fast motion with blur loses them within 10 to 20 frames. The frames are those the module processes: one per frame of the clip behind a Video Player, but about 80 to 115 per second behind an image player or a generator, which send their picture again and again. A frame costs about 1.5 ms at 1920 x 1080 and 6 ms at 3840 x 2160.

Settings

bypass

Bypasses the module processing when activated (ON).

  • OFF (0): Module processes normally
  • ON (1): Input passes directly to output without processing

video in

Video input flow(s).

video out

Video output flow(s).

process time

Total time used for the calculation of the module.

detector

Measure of the corners (default shi-tomasi).

  • shi-tomasi: the Shi-Tomasi measure, which gives the best points to track.
  • harris: the Harris measure.
  • fast: the FAST test, the cheapest, set by fast threshold. It finds the corners of shapes, but not the crossings of a checkerboard.

max points

Largest number of points, from 1 to 1024 (default 200).

quality

Weakest corner kept, as a fraction of the strongest corner of the frame, from 0.001 to 1 (default 0.05): higher values keep the strongest corners only.

fast threshold

Difference of grey level between a corner and the pixels around it, from 1 to 100 (default 20). Used by detector fast only.

min distance

Smallest distance between two points, from 1 to 100 pixels of the frame (default 10).

analysis size

Resolution at which the points are found and followed (default auto). A smaller one costs less; the outputs stay relative to the whole frame.

  • auto: the frame halved until its width is 1280 pixels or less (960 x 540 for 1920 x 1080 and for 3840 x 2160).
  • full: the size of the frame.
  • 1/2: half its width and height.
  • 1/4: a quarter of its width and height.

track

When ON (default), follows the points from frame to frame: each keeps its id and gets a motion and an age. When OFF, the points are found again on each frame, with the ids 1 to count, no motion and age 0; once ON again, the new ids continue after count.

window

Half size of the square followed around each point, from 2 to 15 pixels of the analysis (default 7): larger windows follow faster motions and cost more. The points also stay window + 1 pixels away from the edges.

levels

Number of levels of the tracking pyramid, from 1 to 5 (default 3): each level doubles the largest motion that can be followed. The smallest level stays at least 8 pixels wide and high.

max error

Largest mean difference of grey level between the window of a point and the place where it is found in the next frame, from 1 to 64 (default 12): beyond it the point is lost.

reset

Forgets every point: the ids start again at 1. Activating the patch, or a change of the frame size, of analysis size or of levels, does the same.

draw

When ON (default), draws each point as a square in color on video out 1, with a trail showing its motion. The marks grow with the frame, so that they stay visible on a screen: the squares are 3 pixels wide up to 1280 x 720, 5 at 1920 x 1080 and 9 at 3840 x 2160, and the trails 1, 2 and 4 pixels thick.

trail

Length of the trail drawn behind each tracked point, from 0 to 20 times its motion of one frame (default 4). At 0 only the points are drawn.

color

Color of the points and trails (default $FFFFFF00, yellow).

count

Number of points, from 0 to max points.

input = a black and white checkerboard of 80-pixel cells on a 1280 x 720 frame
count = 120, one point on each of the 15 x 8 inner crossings

ids

Array of the id of each point. The points kept keep their order and their id; the new ones come after them.

x

Array of the x of each point, from 0 (left edge) to 1 (right edge).

y

Array of the y of each point, from 0 (top edge) to 1 (bottom edge).

motion x

Array of the move of each point along x since the previous frame, from -1 to 1 in frame widths: positive to the right, 0 for a new point.

motion y

Array of the move of each point along y since the previous frame, from -1 to 1 in frame heights: positive downward, 0 for a new point.

ages

Array of the number of frames each point has been tracked (0 for a new point).

mean motion x

Mean of motion x over the tracked points, from -1 to 1 (0 when there is none): the motion of the whole picture, such as a camera pan.

mean motion y

Mean of motion y over the tracked points, from -1 to 1 (0 when there is none).

Common Settings

info

show manual

Button. Opens the manual page of the selected object (or of its parent module for a control) in the web browser. If no page exists for this object, an error is traced in the trace panel.

For more details about information/help creation, see create-help-file.

description

Free multi-line text attached to the module, saved with the patch. When it is not empty, it is shown as the hint of the module (mouse over the module header in the patch) in place of the default module hint, even when the module hints are disabled.

ID's

visible only in god mode, see setup-panel-tab-expert.

unique ID

Read-only, not saved. Current private numeric ID of the object, used internally to identify it (for example as the target of a bind ID).

preset ID

Read-only, not saved. Private ID used to store and recall the values of this control in presets.

recreate ID

Button. Generates a new unique ID, original ID and preset ID for the object. Use it if you experience difficulties in Polyphonic mode or if two objects share the same ID. Preset values and binds referring to the old IDs are lost.

Object Remote Address

absolute

Read-only, not saved. Absolute address of the object in the Usine objects tree, built from the workspace root. This is the address to use to reach the object from scripts, the objects panel or remote messages. Only shown for objects that are registered in the objects list. See objects-address.

local

Read-only, not saved. Address of the object relative to the current patch, valid inside that patch only. See objects-address.

user addr

Free user-defined address for the object (empty by default). When set, the object is also registered in the objects tree under this name, so it can be reached independently of its position in the workspace (the value is also reported in the mouse-over and mouse-down chunks). Changing it rebuilds the objects list. Only available on objects that support a user address. See objects-address.

See also

version 7.0.250921

Edit All Pages