ClosestBoundaryPoints3d
Computes the Chamfer distance map of the background of a three-dimensional image and the coordinates of the associated boundary points.
Access to parameter description
This algorithm is like the DistanceMap3d algorithm, applied on the background of the input image, and indicates the distance to the closest object boundary point.
It also stores the X, Y, and Z coordinates of the corresponding point in three additional output images.
Note: This algorithm does not take into account the input image calibration. The output values are systematically indicating distance in voxel units.
See also
Access to parameter description
This algorithm is like the DistanceMap3d algorithm, applied on the background of the input image, and indicates the distance to the closest object boundary point.
It also stores the X, Y, and Z coordinates of the corresponding point in three additional output images.
Note: This algorithm does not take into account the input image calibration. The output values are systematically indicating distance in voxel units.
See also
Function Syntax
This function returns a ClosestBoundaryPoints3dOutput structure containing outputMapImage, outputImageX, outputImageY and outputImageZ.
// Output structure of the closestBoundaryPoints3d function. struct ClosestBoundaryPoints3dOutput { /// The output background distance map image. Its dimensions are forced to the same values as the input. Its type is signed 16-bit integer. std::shared_ptr< iolink::ImageView > outputMapImage; /// The X coordinate image of the closest boundary point, in voxel units. Its dimensions are forced to the same values as the input. Its type is signed 16-bit integer. std::shared_ptr< iolink::ImageView > outputImageX; /// The Y coordinate image of the closest boundary point, in voxel units. Its dimensions are forced to the same values as the input. Its type is signed 16-bit integer. std::shared_ptr< iolink::ImageView > outputImageY; /// The Z coordinate image of the closest boundary point, in voxel units. Its dimensions are forced to the same values as the input. Its type is signed 16-bit integer. std::shared_ptr< iolink::ImageView > outputImageZ; }; // Function prototype
ClosestBoundaryPoints3dOutput closestBoundaryPoints3d( std::shared_ptr< iolink::ImageView > inputBinaryImage, std::shared_ptr< iolink::ImageView > outputMapImage = NULL, std::shared_ptr< iolink::ImageView > outputImageX = NULL, std::shared_ptr< iolink::ImageView > outputImageY = NULL, std::shared_ptr< iolink::ImageView > outputImageZ = NULL );
Class Syntax
Parameters
Parameter Name | Description | Type | Supported Values | Default Value | |
---|---|---|---|---|---|
![]() |
inputBinaryImage |
The binary input image. | Image | Binary | nullptr |
![]() |
outputMapImage |
The output background distance map image. Its dimensions are forced to the same values as the input. Its type is signed 16-bit integer. | Image | nullptr | |
![]() |
outputImageX |
The X coordinate image of the closest boundary point, in voxel units. Its dimensions are forced to the same values as the input. Its type is signed 16-bit integer. | Image | nullptr | |
![]() |
outputImageY |
The Y coordinate image of the closest boundary point, in voxel units. Its dimensions are forced to the same values as the input. Its type is signed 16-bit integer. | Image | nullptr | |
![]() |
outputImageZ |
The Z coordinate image of the closest boundary point, in voxel units. Its dimensions are forced to the same values as the input. Its type is signed 16-bit integer. | Image | nullptr |
Object Examples
auto foam_sep = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam_sep.vip" ); ClosestBoundaryPoints3d closestBoundaryPoints3dAlgo; closestBoundaryPoints3dAlgo.setInputBinaryImage( foam_sep ); closestBoundaryPoints3dAlgo.execute(); std::cout << "outputMapImage:" << closestBoundaryPoints3dAlgo.outputMapImage()->toString(); std::cout << "outputImageX:" << closestBoundaryPoints3dAlgo.outputImageX()->toString(); std::cout << "outputImageY:" << closestBoundaryPoints3dAlgo.outputImageY()->toString(); std::cout << "outputImageZ:" << closestBoundaryPoints3dAlgo.outputImageZ()->toString();
Function Examples
auto foam_sep = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam_sep.vip" ); auto result = closestBoundaryPoints3d( foam_sep ); std::cout << "outputMapImage:" << result.outputMapImage->toString(); std::cout << "outputImageX:" << result.outputImageX->toString(); std::cout << "outputImageY:" << result.outputImageY->toString(); std::cout << "outputImageZ:" << result.outputImageZ->toString();