Processing math: 100%
ImageDev

ImageCurvature2d

Computes local gray level curvature in a two-dimensional image.

Access to parameter description

This algorithm computes, for each pixel of an input image, a local texture curvature attribute. The curvature estimation takes the pixel size into account.

The curvature is extracted from the gradient structure tensor of the input image. For each pixel, the curvature parameter κ is linked to the radius of curvature R by the formula :
κ=1R
<b> Figure 1.</b> The Local radius of curvature
Figure 1. The Local radius of curvature


Reference:
L.J. van Vliet, P.W. Verbeek. "Curvature and Bending Energy in Digitized 2D and 3D Images". SCIA 93, Proc. 8th Scandinavian Conference on Image Analysis, Tromso, Norway, pp. 1403-1410, 1993.

See also

Function Syntax

This function returns outputRealImage.
// Function prototype
std::shared_ptr< iolink::ImageView > imageCurvature2d( std::shared_ptr< iolink::ImageView > inputImage, std::shared_ptr< iolink::ImageView > inputMaskImage, double standardDeviation, std::shared_ptr< iolink::ImageView > outputRealImage = NULL );

Class Syntax

Parameters

Parameter Name Description Type Supported Values Default Value
input
inputImage
The input image. Image Binary, Label, Grayscale or Multispectral nullptr
input
inputMaskImage
The binary image designating the area to process. If it equals null, the algorithm is applied on the whole image. This image must have the same dimensions as the input image. Image Binary nullptr
input
standardDeviation
The standard deviation for Gaussian filter, expressed in world coordinates of the input image. Float64 >0 4
output
outputRealImage
The output image. Each pixel value represents the inverse of the local curvature radius in the world coordinates system. Its dimensions are forced to the same values as the input. Its data type is forced to floating point. Image nullptr

Object Examples

std::shared_ptr< iolink::ImageView > polystyrene = ioformat::readImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "polystyrene.tif" );
auto polystyrene_sep = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "polystyrene_sep.vip" );

ImageCurvature2d imageCurvature2dAlgo;
imageCurvature2dAlgo.setInputImage( polystyrene );
imageCurvature2dAlgo.setInputMaskImage( polystyrene_sep );
imageCurvature2dAlgo.setStandardDeviation( 4.0 );
imageCurvature2dAlgo.execute();

std::cout << "outputRealImage:" << imageCurvature2dAlgo.outputRealImage()->toString();

Function Examples

std::shared_ptr< iolink::ImageView > polystyrene = ioformat::readImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "polystyrene.tif" );
auto polystyrene_sep = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "polystyrene_sep.vip" );

auto result = imageCurvature2d( polystyrene, polystyrene_sep, 4.0 );

std::cout << "outputRealImage:" << result->toString();