Generate Trajectory from Surface Point Cloud

You are currently viewing the documentation for the latest version (2.2.2). To access a different version, click the "Switch version" button located in the upper-right corner of the page.

■ If you are not sure which version of the product you are currently using, please feel free to contact Mech-Mind Technical Support.

Function Description

This Step generates trajectory points from the input point cloud of the target object surface.

Usage Scenario

This Step is suitable for scenarios where trajectory points need to be generated directly from the point cloud of the target object surface. For example, when no CAD model is available, trajectory points can be generated from the point cloud of the target object captured by the camera. Trajectory points can also be generated in real time from the current point cloud when the incoming target object has deviations. This Step is generally preceded by point cloud preprocessing Steps and followed by trajectory processing Steps.

Input and Output

Input

Input Port Data Type Description

Surface Point Cloud

PointCloud/XYZNormal

The surface point cloud used to generate trajectory points. The point cloud should contain surface shape and normal information. This Step generates trajectory points based on the point cloud.

Reference Point

Pose[]

Optional input. A reference point located outside the target object, used to determine the starting side of the trajectory. This Step starts generating trajectory points from the side closer to the reference point.

Output

Output Port Data Type Description

Trajectory Points

Pose[]

Trajectory points generated from the target object surface point cloud.

Parameter Description

Trajectory Distribution Settings

Parameter Description

Row Spacing

Sets the distance between adjacent trajectory rows. A smaller row spacing results in denser trajectories and increases the number of generated trajectory points.

Point Spacing

Sets the distance between adjacent trajectory points on the same trajectory line. A smaller point spacing results in denser trajectory points and a more detailed trajectory.

First Row Offset Distance

Sets the inward offset distance of the first trajectory row from the edge of the target object point cloud. A larger value places the first trajectory row farther from the edge of the point cloud. Outward offsetting of the trajectory beyond the edge of the target object point cloud is not supported.

End Extension Distance

Sets the extension distance of each trajectory row in the start and end directions. This parameter ensures that the trajectory covers the working area beyond the boundary. A negative value indicates that both ends of the trajectory row are retracted inward.

Lift Height Between Rows

Sets the lift height of the robot end tool when moving from one trajectory row to the next. This parameter reduces the risk of collision between the end tool and the target object surface during cross-row movement.

Trajectory Connection Method

Sets how trajectories are connected between adjacent trajectory rows. This parameter determines the generation direction of each trajectory row and how the robot enters the next row after completing the current one.

Value List: Z Shape, S Shape

  • Z Shape: Each trajectory row is generated in the same direction. After one row is generated, the next row starts from the end closer to the starting point of the previous row, forming an overall Z-shaped trajectory. This method is suitable for scenarios where a consistent processing direction is required for each row.

  • S Shape: Adjacent trajectory rows are generated in opposite directions. After one row is generated, the next row starts from the end closer to the endpoint of the previous row, forming a continuous back-and-forth S-shaped trajectory. This method is suitable when reduced idle movement between rows and improved trajectory continuity are desired.

Trajectory Row Direction Calculation Method

Sets how the trajectory row direction is calculated. This parameter determines the direction along which each trajectory row is arranged.

Value List: Auto, Reference Point X-Axis Direction

  • Auto: The Step automatically calculates the principal direction based on the overall distribution of the input point cloud and uses this direction as the trajectory row direction. This method is suitable for point clouds with relatively regular shapes when automatic trajectory direction determination is desired.

  • Reference Point X-Axis Direction: Uses the X-axis direction of the input reference point as the trajectory row direction. This method is suitable when the trajectory direction needs to be specified manually or kept consistent with an external pose or processing direction. When this option is selected, the Step automatically calculates the trajectory row direction if the Reference Point port is not connected.

Trajectory Row Generation Method

Sets how trajectory rows are generated. This parameter determines whether the Step generates multiple parallel lines or generates trajectory rows layer by layer along the point cloud profile.

Value List: Parallel Straight Lines, Equidistant Profiles

  • Parallel Straight Lines: Generates multiple parallel lines within the point cloud region and arranges them at the specified row spacing. This method is suitable for relatively regular shapes when trajectory rows need to be generated in a fixed direction.

  • Equidistant Profiles: Generates trajectory rows layer by layer inward from the outer profile of the point cloud. This method is suitable when the trajectory needs to follow the target object’s outer shape. In this mode, the direction calculated by Trajectory Row Direction Calculation Method is used only as a scanning reference; the trajectory row shape is determined by the target object profile.

Trajectory Gap Settings

Parameter Description

Gap Width Threshold

Sets the width threshold for determining whether a gap is large. A gap is considered large when the 3D distance across it exceeds this value. When set to 0, all gaps with a width greater than 0 are considered large. This parameter takes effect only when Gap Handling Strategy is set to Lift at large gaps only.

Gap Lift Height

Sets the lift height of the trajectory at gaps. When traversing a gap that requires lifting, the trajectory is lifted by this height. If this value is less than or equal to 0, no lift points are generated for any Gap Handling Strategy, and the trajectory transitions across the gap by surface interpolation.

Gap Handling Strategy

Sets how detected gaps are handled.

Value List: Lift at All Gaps, Lift at Large Gaps Only, Ignore All Gaps

  • Lift at All Gaps: Lifts the trajectory by the specified Gap Lift Height at all detected gaps.

  • Lift at Large Gaps Only: Lifts the trajectory by the specified Gap Lift Height only when the gap exceeds the Gap Width Threshold. Gaps that do not exceed the threshold are not lifted.

  • Ignore All Gaps: Does not lift the trajectory at any gaps. The trajectory transitions directly across gaps by surface interpolation, remaining continuous without interruption.

Point Cloud Processing Settings

Parameter Description

Mask Hole Filling Strength

Sets the initial kernel size for morphological processing of the mask using closing and opening operations. Closing fills holes inside the mask and connects nearby broken regions, but may expand the boundary outward. Opening removes edge burrs and small isolated regions, but may shrink the boundary inward or remove small structures. A larger value produces a stronger effect. The Step starts from this value and gradually reduces the kernel size if the Minimum Retention Ratio of Original Region is not met, limiting changes to the original region.

Mask Roughness

Sets the grid resolution used to generate the mask from the point cloud projection. This value must be greater than 0. A larger value results in a rougher representation of the surface contour in the mask, while a smaller value results in a finer mask.

Min Retention Ratio of Original Region

Sets the minimum proportion of the original region that must be retained after morphological operations are performed on the mask. The value range is [0, 1]. This parameter limits the extent to which the morphological operations alter the original region. A higher ratio better preserves the shape of the original point cloud region, while a lower ratio allows greater adjustment of the region.

Trajectory Point Pose Settings

Parameter Description

Trajectory Point Z-Axis Angle

Sets the tilt angle of the trajectory point Z-axis relative to the surface normal, in degrees. A value of 90° indicates that the trajectory point Z-axis coincides with the surface normal, meaning it is perpendicular to the surface. The Z-axis rotates around the trajectory direction. The farther the value is from 90°, the greater the tilt. Values greater than and less than 90° tilt the Z-axis toward opposite sides.

Surface Normal Source

Sets the source of the surface normal used to calculate the initial direction of the trajectory point Z-axis.

Value List: Calculate from Local Point Cloud, Calculate from Overall Point Cloud

  • Calculate from Local Point Cloud: Uses the surface normal of the local point cloud near each trajectory point to calculate the Z-axis direction, allowing the trajectory point pose to adapt to local surface shape variations.

  • Calculate from Overall Point Cloud: Uses the normal of the principal plane fitted to the entire point cloud to calculate the Z-axis direction, keeping the pose directions of all trajectory points consistent.

Flip Surface Normal

When enabled, flips the surface normal calculated based on Surface Normal Source. This option is suitable when the generated trajectory point Z-axis points in the opposite direction from the expected direction.

Forward Alignment Axis

Sets the trajectory point coordinate axis that aligns with the trajectory direction.

Value List: X-Axis, Y-Axis

  • X-Axis: The trajectory point X-axis points in the trajectory direction.

  • Y-Axis: The trajectory point Y-axis points in the trajectory direction.

Alignment Axis Orientation

Sets whether the orientation of the alignment axis changes with the trajectory direction of each trajectory row.

Value List: Follow Trajectory Direction, Maintain Consistent Direction

  • Follow Trajectory Direction: The alignment axis always points in the direction of the current trajectory row. For an S-shaped trajectory, adjacent trajectory rows have opposite directions, and the alignment axis reverses accordingly.

  • Maintain Consistent Direction: The alignment axis points toward the projection of the Reference Point X-axis onto the principal plane of the surface for all trajectory rows, and does not reverse with the direction of adjacent rows. If the Reference Point port is not connected or the reference point pose is invalid, the Step falls back to the principal direction of the trajectory rows and outputs a warning.

Is this page helpful?

You can give a feedback in any of the following ways:

We Value Your Privacy

We use cookies to provide you with the best possible experience on our website. By continuing to use the site, you acknowledge that you agree to the use of cookies. If you decline, a single cookie will be used to ensure you're not tracked or remembered when you visit this website.