Scalar fields\Interpolate from another entity
Menu
This tool is accessible via the 'Edit > Scalar fields > Interpolate from another entity' menu.
Description
Interpolates the active scalar field from one cloud to another cloud (or vertices of a mesh) with potentially a different number of points/vertices.
To start the tool, the user must first select two point clouds (note that mesh vertices are point clouds).
If only one entity has an (active) scalar field, then CloudCompare will automatically set it as the 'source', and the other one as the 'destination'. Otherwise if both entities have scalar fields, then CC will display a small dialog to let the user designates the roles of each cloud.
Then the main tool dialog will be displayed:
First, one must select how the points in the source cloud that are close to each point of the destination cloud should be selected:
- Nearest neighbor (only the nearest neighbor will be selected: no interpolation)
- Nearest neighbors (fixed number of neighbors)
- Radius (sphere) (all the neighbors falling inside a sphere)
Then, if several neighbors are used, one must select how the corresponding scalar value will be computed:
- Average value
- Median value (more robust to noise)
- Normal distribution (weighted average with a specified 'kernel / sigma' value - tip: the weight is zero at a distance of '3*sigma')
When the OK button is pressed, CC will interpolate the active scalar field of the source cloud, and create one on the destination cloud with the interpolated values.
Notes:
- the destination scalar field will have the same name as the destination one.
- if a similar SF is already present on the destination cloud, it will be overwritten.