3D Point Cloud Centroid
Definition of Centroid
The centroid of a point cloud is the "average position" of all points in space, which can be considered as the "center of gravity" of the point cloud. If we sum up the position coordinates of every point in the point cloud and divide by the total number of points, we obtain the coordinates of the centroid. The position of the centroid represents the "center" or balance point of the entire point cloud.
In 3D point cloud processing and computation, the centroid has many applications. For example, it can serve as a reference for point cloud alignment, helping to register or align point clouds in different coordinate systems.
Operator Function
Select the region of interest from the input point cloud based on ROI, then calculate the centroid of the ROI point cloud.
Parameter Introduction
Input Parameters
| Parameter | Range | Default Value | Description | Illustration |
|---|---|---|---|---|
| Input Image | 0-8 | 0 | The IM number for image input |
Calculation Parameters

| Parameter | Range | Default Value | Description | Illustration |
|---|---|---|---|---|
| Use Region Parameters | true/false | false | If enabled, use Region as input; if not enabled, use Input Image as input | |
| Region | 2D Window/Box | Box | Manually select an appropriate ROI regionCan bind to select existing ROI regions. When input is an array, output will also be an array |
Result Display

| Parameter | Range | Default Value | Description | Illustration |
|---|---|---|---|---|
| ROI Point Set | true/false | false | Only effective when Use Region Parameters is selected; the point set of the ROI selected region; if enabled, displayed in the image | |
| Centroid | true/false | false | Centroid point; if enabled, displayed in the image |
Output Parameters

| Name | Type | Range | Description |
|---|---|---|---|
| Result | bool | true/false | true for success false for failure |
| Warning | bool | true/false | true indicates there is a warning false indicates there is none |
| Message | string | Outputs success, error, or warning information; if there is no error or warning, it is empty | |
| Time | float | Operator execution time, unit: ms | |
| Pointe3D | point3d | 3D point cloud centroid point coordinates When input is an array, output will also be an array |
Exception Troubleshooting
| No. | Exception Information | Corresponding Parameter | Solution |
|---|
Example Introduction
Engineering Design
Select the
Load Point Cloudtool to load the 3D point cloud image to be processed into IM0.Select the
3D Point Cloud Centroidtool.
Tool Usage
Select the input image for operation; the image number must match the IM number where the image is located in the project.
Select the region type as Box, move the box to the position to be measured, enclosing the point cloud to be measured.
Usage Tips
- Use the ROI controller on the image window to drag or scale the box;
- Directly modify the start or end coordinates of the box in the calculation parameters to adjust the box position and size;
Set parameters
Check the content you want to display in the result display section
Click
Testto check if the image window and parameters meet expectationsIf there are no issues, click
Save, then run the operator in the run list to view the results in the corresponding IM

