Point Cloud Bounding Box (Along Long Edge)

Functional Description

This operator calculates an oriented 3D bounding box (OBB) for each input point cloud. Unlike standard OBB calculation, this operator forces one of the principal axes of the bounding box (usually the longest axis) to align with the direction of a user-input line. It outputs the parameters of this aligned OBB, including the center point, dimensions, transformation matrix, normal vector, and an adjustable 3D ROI.

Usage Scenarios

  • Oriented Object Pose Estimation: When you need to obtain an accurate bounding box for an object whose main direction is known (e.g., the long edge direction of a bar-shaped workpiece). By inputting this main direction (long edge line), a more stable bounding box that better fits the actual orientation of the object can be obtained.

  • Constrained Bounding Box Calculation: In some applications, it’s necessary to calculate the boundary range of an object under a specific directional constraint.

  • Grasping and Placing: Generate aligned bounding boxes for objects with known main directions, facilitating directional grasping or placing operations by robots.

Inputs and Outputs

Input Items

Pointcloud: Input point cloud or list of point clouds.

Long side linear equation parameters: A list containing line model parameters corresponding one-to-one with the input point cloud list. This direction vector defines the main direction to which the bounding box needs to align.

Output Items

Bounding box normal: A list of normal vectors (usually the short edge direction) for the calculated OBB.

Bounding box center point: A list of center points for each calculated bounding box. The calculation method is determined by the Center point type parameter.

Bounding box: A list of detailed information for each bounding box, including center, dimensions, and a 3x3 rotation transformation matrix (which transforms the bounding box from its own coordinate system to the world coordinate system).

Bounding box size: A list of X, Y, Z dimensions for each bounding box along its principal axes.

3D ROI: A list of 3D ROIs generated based on the calculated bounding box, possibly scaled or adjusted.

Parameter Description

This operator has two versions:

  • Point Cloud Bounding Box (Along Long Edge) : Processes point clouds without normal information.

  • Point Cloud Bounding Box with Normals (Along Long Edge) : Processes point clouds with normal information. Both have identical core functionality and parameters, only differing in the type of point cloud data they process.

  • Input Correspondence: The input Pointcloud list and the Long side linear equation parameters list must correspond one-to-one, and the line model parameters must contain 6 values (point + direction).

  • Long Edge Assumption: The operator’s effectiveness depends on the input line direction accurately representing a principal direction (usually the length direction) of the point cloud. If the input line deviates significantly from the actual shape of the point cloud, the calculated bounding box may be inaccurate.

Center point type

Parameter Description

Selects how the output "Bounding box center point" is calculated.

Tuning Description

  • Bounding box center (Default): Directly uses the geometric center of the OBB calculated and aligned with the input line.

  • Point cloud mean : Uses the XYZ coordinate mean of the original point cloud constituting this OBB.

  • Point cloud median : Uses the XYZ coordinate median of the original point cloud constituting this OBB, which is more robust to outliers. The choice depends on the subsequent application’s requirements for the center point definition.

Normal Z direction

Parameter Description

Specifies whether the Z-component of the output "Bounding box normal" should be positive or negative. The operator adjusts the calculated normal vector direction based on this setting.

Tuning Description

Used to unify the orientation of the output normal vector. If you want the normal vector to always point in the positive Z-axis direction ("upwards"), select "Positive Z"; if you want it to point in the negative Z-axis direction ("downwards"), select "Negative Z".

Zoom method

Parameter Description

Selects how to adjust (scale/expand) the final output 3D ROI region.

Tuning Description

  • Do not allow zoom (Default): No scaling or expansion is performed; the ROI is consistent with the calculated minimum bounding box.

  • Specified value: Adds or subtracts the absolute values specified by the "Scale range in X direction"/"Scale range in Y direction"/"Z scaling range" parameters below to/from the min/max coordinates of each axis of the bounding box.

  • Specified ratio: Scales the dimensions of the bounding box according to the "Scale X"/"Scale Y"/"Zoom" parameters below.

Scale range in X direction/Scale range in Y direction/Z scaling range

Parameter Description

Effective when "Zoom method" is set to "Specified value". Specifies the distance to expand outwards (positive value) or shrink inwards (negative value) in the X, Y, and Z directions of the bounding box, respectively.

For example, x=10 means the ROI is 20mm wider in the X direction (the bounding box’s own X-axis) than the original bounding box (10mm added to each side).

Tuning Description

Used for precise control of ROI size, e.g., slightly expanding the ROI to include possible grasping error margins, or slightly shrinking it to exclude edge noise.

Parameter Range

[-5000, 10000], Default: 0, Unit: mm

Scale X/Scale Y/Zoom

Parameter Description

Effective when "Zoom method" is set to "Specified ratio". Specifies the scaling factor for the ROI (and possibly the bounding box) in the X, Y, and Z directions, respectively.

Tuning Description

A scaling factor of 1 means maintaining the original size, greater than 1 means enlarging, and less than 1 means shrinking. For example, x=1.1 means the size of the ROI in the X direction (the bounding box’s own X-axis) becomes 1.1 times the original.

Parameter Range

[0, 5], Default: 1