Skip to content

3D Distance

Operator Function

Select the type of distance calculation, input parameters of the points, lines, or planes to be measured. Obtain the shortest distance between them, distances along each coordinate axis direction, and distances along each coordinate plane direction.

Parameter Introduction

Input Parameters

ParameterRangeDefault ValueDescriptionIllustration
Input Image0-80The IM number for image input

Calculation Parameters

ParameterRangeDefault ValueDescriptionIllustration
ModeDistance to Point/Distance Between Skew Lines (Vector Formula Method)/Distance Between Skew Lines and Planes (Reference Point Outside Line/Plane)Distance to PointSee Mode
Measurement DirectionSee Measurement Direction

Mode

  • Distance to Point: Select function to measure distance between point and point/line/plane
ParameterRangeDefault ValueDescriptionImage
Geometry 13D Point3D PointPosition: Input point's X, Y, Z coordinates
Geometry 23D Point/3D Line/Plane3D PointType: Only enabled in manual mode, set manual input type: Point/Line/Plane
Position: Only enabled in manual mode, input X, Y, Z coordinates of point/point on line/point on plane
Direction: Only enabled in manual mode, enabled when input type is 3D Line, input line's direction vector
Normal Vector: Only enabled in manual mode, enabled when input type is Plane, input plane's normal vector
  • Distance Between Skew Lines (Vector Formula Method): Select function to measure distance between skew lines
ParameterRangeDefault ValueDescriptionImage
Geometry 13D Line3D LinePosition: Only enabled in manual mode, input X, Y, Z coordinates of point on line
Direction: Only enabled in manual mode, input line's direction vector
Geometry 23D Line3D LinePosition: Only enabled in manual mode, input X, Y, Z coordinates of point on line
Direction: Only enabled in manual mode, input line's direction vector
  • Distance Between Skew Lines/Planes (Reference Point Outside Line/Plane): Select function to measure distance between line and line, line and plane, plane and plane using a third point
ParameterRangeDefault ValueDescriptionImage
Geometry 13D Line/Plane3D LineType: Only enabled in manual mode, set manual input type: Line/Plane
Position: Only enabled in manual mode, input X, Y, Z coordinates of point on line/plane
Direction: Only enabled in manual mode, enabled when input type is 3D Line, input line's direction vector
Normal Vector: Only enabled in manual mode, enabled when input type is Plane, input plane's normal vector
Geometry 23D Line/Plane3D LineType: Only enabled in manual mode, set manual input type: Line/Plane
Position: Only enabled in manual mode, input X, Y, Z coordinates of point on line/plane
Direction: Only enabled in manual mode, enabled when input type is 3D Line, input line's direction vector
Normal Vector: Only enabled in manual mode, enabled when input type is Plane, input plane's normal vector
Reference Point3D Point3D PointPosition: Input reference point's X, Y, Z coordinates

Measurement Direction

  • Direction:
ParameterDescription
Shortest DistanceSelect mode to measure shortest distance
Parallel to X-axisSelect mode to measure distance parallel to X-axis direction
Parallel to Y-axisSelect mode to measure distance parallel to Y-axis direction
Parallel to Z-axisSelect mode to measure distance parallel to Z-axis direction
On XY PlaneSelect mode to measure distance projected onto XY plane
On XZ PlaneSelect mode to measure distance projected onto XZ plane
On YZ PlaneSelect mode to measure distance projected onto YZ plane

Based on different measurement requirements, different measurement objects and directions can be selected:

Distance to Point:

Point to Point Distance

ParameterDescriptionImage
Shortest DistanceThis function measures the shortest distance (straight line) between two points
Parallel to Coordinate AxisExample parallel to X-axis: This function only measures the shortest distance between two points in the direction parallel to X-axis
On Coordinate PlaneExample on XY plane: This function only measures the shortest distance between two points on the XY plane

Point to Line Distance:

ParameterDescriptionImage
Shortest DistanceThis function measures the shortest distance from point to line
Parallel to Coordinate AxisExample parallel to X-axis: This function only measures the shortest distance from point to line in the direction parallel to X-axis
On Coordinate PlaneExample on XY plane: This function only measures the shortest distance from point to line on the XY plane

Point to Plane Distance:

ParameterDescriptionImage
Shortest DistanceThis function measures the shortest distance from point to plane
Parallel to Coordinate AxisExample parallel to X-axis: This function only measures the shortest distance from point to plane in the direction parallel to X-axis
On Coordinate PlaneExample on XY plane: This function only measures the shortest distance from point to plane on the XY plane

Distance Between Skew Lines (Vector Formula Method)

As shown below, when selecting this method, regardless of the measurement direction chosen, the measured shortest distance between skew lines is output

Skew Line Distance

Distance Between Skew Lines/Planes (Reference Point Outside Line/Plane)

Line to Line Distance:

ParameterDescriptionImage
Shortest DistanceThis function references a point outside both lines to measure the shortest distance between the two lines
Parallel to Coordinate AxisExample parallel to X-axis: This function references a point outside both lines to measure the shortest distance between the two lines in the direction parallel to X-axis
On Coordinate PlaneExample on XY plane: This function references a point outside both lines to measure the shortest distance between the two lines on the XY plane

Line to Plane Distance:

ParameterDescriptionImage
Shortest DistanceThis function references a point outside the line and plane to measure the shortest distance between the line and plane
Parallel to Coordinate AxisExample parallel to X-axis: This function references a point outside the line and plane to measure the shortest distance between the line and plane in the direction parallel to X-axis
On Coordinate PlaneExample on XY plane: This function references a point outside the line and plane to measure the shortest distance between the line and plane on the XY plane

Plane to Plane Distance:

ParameterDescriptionImage
Shortest DistanceThis function references a point outside both planes to measure the shortest distance between the two planes
Parallel to Coordinate AxisExample parallel to X-axis: This function references a point outside both planes to measure the shortest distance between the two planes in the direction parallel to X-axis
On Coordinate PlaneExample on XY plane: This function references a point outside both planes to measure the shortest distance between the two planes on the XY plane

Result Display

ParameterRangeDefault ValueDescriptionIllustration
Geometry 1true/falsefalseIf enabled, display Geometry 1 in the image
Geometry 2true/falsefalseIf enabled, display Geometry 2 in the image
Reference Pointtrue/falsefalseReference point; if enabled, displayed in the image
Distance Segmenttrue/falsefalseDistance segment; if enabled, displayed in the image
Distance Valuetrue/falsefalseDistance value; if enabled, displayed in the image

Output Parameters

NameTypeRangeDescription
Resultbooltrue/falsetrue for success
false for failure
Warningbooltrue/falsetrue indicates there is a warning
false indicates there is none
MessagestringOutputs success, error, or warning information; if there is no error or warning, it is empty
TimefloatOperator execution time, unit: ms
distancefloatOutput distance

Tip

For more detailed explanations of parameter types, please refer to Type Definitions

Exception Troubleshooting

No.Exception InformationCorresponding ParameterSolution
1Input measurement direction is {0}, invalid measurement directionMeasurement DirectionInput measurement method must be one of: Direct Distance/Parallel to X-axis/Parallel to Y-axis/Parallel to Z-axis/On XY Plane/On YZ Plane/On XZ Plane
2Input Geometry 1 type is {0}, invalid geometry typeGeometry TypeFirst object type must be 3D Point/3D Line/Plane
3Input Geometry 2 line parameters invalidInput line direction vector parameters cannot all be 0
4Input Geometry 2 plane parameters invalidInput plane normal vector parameters cannot all be 0
5Input Geometry 2 type is {0}, invalid geometry typeGeometry TypeSecond object type must be 3D Point/3D Line/Plane
6Input Geometry 1 line parameters invalidInput line direction vector parameters cannot all be 0
7Input reference point type is {0}, invalid reference point typeGeometry TypeReference point type must be set to 3D Point
8Input Geometry 1 plane parameters invalidInput plane normal vector parameters cannot all be 0
9Input mode is {0}, invalid input modeModeInput mode must be one of: Distance to Point/Distance Between Skew Lines (Vector Formula Method)/Distance Between Skew Lines and Planes (Reference Point Outside Line/Plane)

Example Introduction

Engineering Design

  1. Select the Load Point Cloud tool to load the 3D point cloud image to be processed into IM0.

  2. Select the 3D Crop tool to copy IM0 to IM1, IM2 for different operations.

  3. Select two Square Probe tools to obtain a point and a line for measuring point-line distance; select two Square Probe tools to obtain two lines for measuring line-line distance; select two 3D Plane tools to obtain two planes for measuring plane-plane distance.

  4. Select the 3D Distance tool.

Tool Usage

  1. Select the input image for operation; the image number must match the IM number where the image is located in the project.

  2. Set input mode and input geometry

Select multiple 3D Distance tools, set different input modes (point-line distance, line-line distance, plane-plane distance). Bind the lines or planes obtained from the previous step's Square Probe tools and 3D Plane as Geometry 1 and Geometry 2.

  1. Set parameters

  2. Check the content you want to display in the result display section

  3. Click Test to check if the image window and parameters meet expectations

  4. If there are no issues, click Save, then run the operator in the run list to view the results in the corresponding IM

Local Image

AI-Vision, Making 3D Measurement Easier