Measure

Added in version 3.17.0.

This visual element renders the geometric measurement computed by the Measure modifier: the line segments connecting the measurement points, the arcs marking the interior angles, the labels showing the measured values, and the area enclosed by a closed polyline.

The element is attached to the measure data table the modifier outputs and takes every value it draws from there, so the annotation in the viewports always agrees with the numbers in the table.

The modifier creates and manages the visual element, so there is normally no need to add it yourself. The parameters below control what the annotation looks like; what is being measured is up to the modifier.

Parameters

Custom color, Line width

The appearance of the connecting segments and the angle arcs. With Custom color disabled, the line color is automatically determined based on the background color: white lines for dark backgrounds and black lines for light backgrounds. When enabled, the manually selected color is used instead. The width is given in pixels, so the lines keep their thickness no matter how far the camera is away from the measurement.

Dashed lines, Dash length

Draws the lines and arcs dashed instead of solid. The dash length is given in units of length of the simulation, which means the dashes stay attached to their position along the line and grow smaller as you zoom out. Leaving the length at 0 scales the pattern to the size of the measurement.

Show distances, Distance format

Displays the length of each segment at the middle of the segment. The format is a printf-style format string, e.g. %.2f nm. Any literal text in it, a unit symbol for instance, becomes part of every label.

Show angles, Angle format, Arc radius

Displays an arc and the angle value at every vertex where two segments meet. The angles are given in degrees. An arc radius of 0 derives the radius from the two segments meeting at the vertex; the radius never exceeds 40% of the shorter of the two, so that an arc cannot overrun the segments it spans.

Text size, Text color, Outline

The appearance of the value labels. The text size is given as a fraction of the rendered image height.

Enclosed area

Fills the area enclosed by the measurement points if they form a closed polyline. Note that the fill is correct for convex and star-shaped outlines; a strongly concave outline may be filled only partially.

Always in front

Draws the measurement on top of all other objects in the scene, so that the segments, arcs and value labels are no longer hidden by the objects they annotate. This is the quickest way to keep a measurement readable inside a dense particle system. While this option is active, Depth offset has no effect.

Note that the filled area of a closed measurement is an exception: it stays part of the scene and can still be covered by objects in front of it.

Depth offset

Distance by which the whole measurement is lifted toward the camera, given in units of length of the simulation. Raise it in small steps to free the annotation from geometry it is buried in, or to stop it from flickering against a surface it lies exactly on. The value labels are lifted slightly further than the lines, so that the text always stays clear of the line it belongs to.

Note

The value labels are placed in the three-dimensional scene as billboards that always face the camera, so a label behind an opaque object is occluded by it. The labels keep a constant size on screen, independent of their distance to the camera.

Note

The segments, arcs and labels are drawn by the interactive viewports and by OVITO’s standard renderer. The Tachyon, OSPRay and ANARI renderers composite them into the rendered image as well. They are not part of a scene exported to a glTF file, however, because that format has no representation for them.

See also

ovito.vis.MeasureVis (Python API)