NagaoFilter3d
Performs an edge-preserving smoothing of a three-dimensional image by selecting a mean value from different neighborhood configurations.
Access to parameter description
For an introduction to image filters: see Images Filtering.
This algorithm uses an adaptive 5x5 neighborhood geometry to compute a mean neighbors value around a central pixel.
The mean values of different neighborhood configurations around the considered pixel are computed. The pixel is replaced by the mean value of the configuration presenting:
The predefined sub neighborhoods are composed of 27 pixels and are a 3D extension of the Nagmod configurations of the NagaoFilter2d algorithm.
Reference:
M.Nagao, T.Matsuyama. "Edge preserving smoothing". Computer Graphics and Image Processing, vol. 9, pp. 394-407, 1979.
See also
Access to parameter description
For an introduction to image filters: see Images Filtering.
This algorithm uses an adaptive 5x5 neighborhood geometry to compute a mean neighbors value around a central pixel.
The mean values of different neighborhood configurations around the considered pixel are computed. The pixel is replaced by the mean value of the configuration presenting:
- either the minimum variance,
- or the minimum range (difference between maximum and minimum values)
The predefined sub neighborhoods are composed of 27 pixels and are a 3D extension of the Nagmod configurations of the NagaoFilter2d algorithm.
Reference:
M.Nagao, T.Matsuyama. "Edge preserving smoothing". Computer Graphics and Image Processing, vol. 9, pp. 394-407, 1979.
See also
Function Syntax
This function returns outputImage.
// Function prototype
std::shared_ptr< iolink::ImageView > nagaoFilter3d( std::shared_ptr< iolink::ImageView > inputImage, NagaoFilter3d::FilterMethod filterMethod, std::shared_ptr< iolink::ImageView > outputImage = nullptr );
This function returns outputImage.
// Function prototype. nagao_filter_3d(input_image: idt.ImageType, filter_method: NagaoFilter3d.FilterMethod = NagaoFilter3d.FilterMethod.VARIANCE, output_image: idt.ImageType = None) -> idt.ImageType
This function returns outputImage.
// Function prototype. public static IOLink.ImageView NagaoFilter3d( IOLink.ImageView inputImage, NagaoFilter3d.FilterMethod filterMethod = ImageDev.NagaoFilter3d.FilterMethod.VARIANCE, IOLink.ImageView outputImage = null );
Class Syntax
Parameters
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
inputImage |
The input image. | Image | Binary, Label, Grayscale or Multispectral | nullptr | |||||
filterMethod |
The neighborhood selection criterion.
|
Enumeration | VARIANCE | ||||||
outputImage |
The output image. Its dimensions, type, and calibration are forced to the same values as the input. | Image | nullptr |
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
input_image |
The input image. | image | Binary, Label, Grayscale or Multispectral | None | |||||
filter_method |
The neighborhood selection criterion.
|
enumeration | VARIANCE | ||||||
output_image |
The output image. Its dimensions, type, and calibration are forced to the same values as the input. | image | None |
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
inputImage |
The input image. | Image | Binary, Label, Grayscale or Multispectral | null | |||||
filterMethod |
The neighborhood selection criterion.
|
Enumeration | VARIANCE | ||||||
outputImage |
The output image. Its dimensions, type, and calibration are forced to the same values as the input. | Image | null |
Object Examples
auto foam = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam.vip" ); NagaoFilter3d nagaoFilter3dAlgo; nagaoFilter3dAlgo.setInputImage( foam ); nagaoFilter3dAlgo.setFilterMethod( NagaoFilter3d::FilterMethod::VARIANCE ); nagaoFilter3dAlgo.execute(); std::cout << "outputImage:" << nagaoFilter3dAlgo.outputImage()->toString();
foam = imagedev.read_vip_image(imagedev_data.get_image_path("foam.vip")) nagao_filter_3d_algo = imagedev.NagaoFilter3d() nagao_filter_3d_algo.input_image = foam nagao_filter_3d_algo.filter_method = imagedev.NagaoFilter3d.VARIANCE nagao_filter_3d_algo.execute() print("output_image:", str(nagao_filter_3d_algo.output_image))
ImageView foam = Data.ReadVipImage( @"Data/images/foam.vip" ); NagaoFilter3d nagaoFilter3dAlgo = new NagaoFilter3d { inputImage = foam, filterMethod = NagaoFilter3d.FilterMethod.VARIANCE }; nagaoFilter3dAlgo.Execute(); Console.WriteLine( "outputImage:" + nagaoFilter3dAlgo.outputImage.ToString() );
Function Examples
auto foam = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam.vip" ); auto result = nagaoFilter3d( foam, NagaoFilter3d::FilterMethod::VARIANCE ); std::cout << "outputImage:" << result->toString();
foam = imagedev.read_vip_image(imagedev_data.get_image_path("foam.vip")) result = imagedev.nagao_filter_3d(foam, imagedev.NagaoFilter3d.VARIANCE) print("output_image:", str(result))
ImageView foam = Data.ReadVipImage( @"Data/images/foam.vip" ); IOLink.ImageView result = Processing.NagaoFilter3d( foam, NagaoFilter3d.FilterMethod.VARIANCE ); Console.WriteLine( "outputImage:" + result.ToString() );