Skip to content

Measure ​

Reports the extent of whatever is wired into it — width, height, size, center and corners — as plain values you can wire into anything else.

Category: Utility Menu path: Utility > Measure

Ports ​

PortTypeDirectionDescription
inshape / points / text / imageRgba16finputThe thing being measured
widthscalaroutputMeasured width in comp pixels
heightscalaroutputMeasured height in comp pixels
sizevec2output(width, height) as one vec2
centervec2outputCenter of the measured box
minvec2outputTop-left corner (smallest x, smallest y)
maxvec2outputBottom-right corner (largest x, largest y)

Every output is in origin-centerd composition pixels — (0, 0) is the center of the frame, +x right, +y down — the same space shapes and points are authored in. That means center drops straight into a Transform2D position and size straight into a Rectangle, with no conversion.

Parameters ​

ParamTypeDefaultDescription
modestringContentContent = the extent of what the image actually contains; Canvas = the whole frame. Only shown, and only meaningful, when an image is wired in — geometry and text are always measured at their own extent.
paddingvec2(0, 0)Grows the measured box. padding.x is added to the total width, padding.y to the total height — half on each side, so center never moves. size, width, height, min and max all include it.

Expose Channels ​

None. Measure produces values rather than consuming them; there is nothing to drive.

How It Works ​

A pure CPU value node — no texture output, no GPU work, no cost worth thinking about.

What it measures depends on what is wired in:

  • Shape — the curve-aware bounding box, so a bezier that bulges past its anchor points is inside the measurement. (Measuring the anchors alone would hand you a box the curve escapes from.)
  • Points — the bounding box of the point positions.
  • Text — the layout box the Text node computed: the extent of the set copy, including line wrapping and multiple lines.
  • Image — measured structurally, not by scanning pixels. The node follows the wire back through the chain to its source and reports where that source's rectangle lands on the frame, carried through any Transform2D or Crop on the way. It does not read the image back off the GPU and look for lit pixels, so it will not find the tight extent of, say, a blob painted in the middle of a transparent frame. A generator (Noise, Gradient, Solid Color) or any chain the walk cannot resolve reports the whole frame — which is what those actually fill. Canvas mode reports the frame rect outright.
  • Nothing wired, or geometry with no points — every output is zero, including center. Padding does not apply: it grows a measurement, it does not invent one.

Measure has no clock of its own. It re-reports whenever what it is measuring changes, and costs nothing when that thing is static.

Seeing the numbers ​

Select the Measure node and Properties shows a Readout section with the measured Size and Center, in composition pixels — the same numbers the ports publish, padding included. They are live measurements, not parameters: there is nothing to type, drag or keyframe there.

The readout follows the last rendered frame. Scrub or play and it moves with the picture; when a frame doesn't need to re-evaluate the node, the last numbers stay on screen rather than blanking out.

min and max are not in the panel — they are the same box said a different way, and they are on the ports for anything that needs them.

Usage Examples ​

Basic: a plate that fits its text ​

The reason this node exists. Instead of keyframing a rounded rectangle to match every copy change:

Text ──┬──────────────── DrawText ─┐
       │                           ├─ Merge ── Output
       └─ Measure ── Rectangle ── Transform2D ── DrawShape ─┘

Wire Text.out into Measure.in, then Measure.size into the Rectangle (or width → width_in and height → height_in if you want them separately). Set padding to the breathing room you want — (60, 32) is a reasonable plate — and the rectangle now tracks the copy, at any string, any font size, any number of lines. Put the DrawShape below the DrawText in the Merge so the plate sits behind the type.

Add cornerRadius on the Rectangle for a pill, and animate the Text and the plate together from one Transform2D.

Basic: center something on something else ​

Wire Measure.center into a Transform2D's position_in to park one element on the middle of another's extent — useful when the thing being measured moves or resizes under animation.

Creative: a bar that reads a point cloud ​

Measure a points cloud (a Point Scatter, a particle population, a Grid) and drive a Rectangle's width from width. The bar now reports the spread of the population as it disperses — a readout built out of the same geometry it describes.

Practical: framing an image ​

Measure an Image Source to get the rectangle it occupies in the frame, then use size to build a border or a matte around it that follows the footage's aspect without hand-typing numbers. Remember this is the image's placement rectangle, not its lit content — see How It Works.

Tips ​

  • Padding is the total added extent, not a per-side inset: padding.x = 60 gives 30px of room on each side. It reads the way a designer thinks about a plate, and it keeps center fixed.
  • Measuring a Transform2D's output measures the transformed result, which is usually what you want — put the Measure after the transform, not before.
  • The measurement is a box, not an outline. A rotated shape measures its axis-aligned bounding box, which is larger than the shape itself.
  • Wiring size into a Rectangle gives you a plate the same size as the content, edge to edge. Almost every real use wants some padding.
  • For the composition's own dimensions rather than a layer's content, use Comp Details instead — it is free and does not depend on anything being wired.
  • CompDetails — the composition's width / height / fps / duration, rather than a piece of content's
  • Rectangle — the usual consumer: width_in / height_in take the measurement
  • Transform2D — takes center on position_in to park something on what was measured
  • Text — the usual subject; also exposes its own width / height outputs for the simple single-node case
  • VectorMath — for arithmetic on size beyond what padding covers
  • Debug — the same readout channel on the node's face, for any value in the graph rather than a measurement