Catalano.Imaging.Filters.Photometric
Class DifferenceOfGaussian
- java.lang.Object
-
- Catalano.Imaging.Filters.Photometric.DifferenceOfGaussian
-
- All Implemented Interfaces:
- IPhotometricFilter, IApplyInPlace
public class DifferenceOfGaussian extends java.lang.Object implements IPhotometricFilter
Difference of Gaussians is a feature enhancement algorithm that involves the subtraction of one blurred version of an original image from another.- Supported types: Grayscale, RGB.
- Coordinate System: Matrix.
-
-
Constructor Summary
Constructors Constructor and Description DifferenceOfGaussian()Initialize a new instance of the DifferenceOfGaussian class.DifferenceOfGaussian(double sigma1, double sigma2)Initialize a new instance of the DifferenceOfGaussian class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidapplyInPlace(FastBitmap fastBitmap)Apply filter to an image.doublegetSigma1()Get sigma 1.doublegetSigma2()Get sigma 2.double[][]Process(double[][] image, boolean normalize)Process the image as matrix.voidsetSigma1(double sigma1)Set sigma 1.voidsetSigma2(double sigma2)Set sigma 2.
-
-
-
Constructor Detail
-
DifferenceOfGaussian
public DifferenceOfGaussian()
Initialize a new instance of the DifferenceOfGaussian class.
Default:
Sigma 1: 1
Sigma 2: 2
-
DifferenceOfGaussian
public DifferenceOfGaussian(double sigma1, double sigma2)Initialize a new instance of the DifferenceOfGaussian class.- Parameters:
windowSize1- First window size.windowSize2- Second window size.sigma1- First sigma value.sigma2- Second sigma value.
-
-
Method Detail
-
getSigma1
public double getSigma1()
Get sigma 1.- Returns:
- Sigma value.
-
setSigma1
public void setSigma1(double sigma1)
Set sigma 1.- Parameters:
sigma1- Sigma value.
-
getSigma2
public double getSigma2()
Get sigma 2.- Returns:
- Sigma value.
-
setSigma2
public void setSigma2(double sigma2)
Set sigma 2.- Parameters:
sigma2- Sigma value.
-
applyInPlace
public void applyInPlace(FastBitmap fastBitmap)
Description copied from interface:IApplyInPlaceApply filter to an image.- Specified by:
applyInPlacein interfaceIPhotometricFilter- Specified by:
applyInPlacein interfaceIApplyInPlace- Parameters:
fastBitmap- Image to be processed.
-
Process
public double[][] Process(double[][] image, boolean normalize)Process the image as matrix.- Parameters:
image- Image.normalize- True if the image needs to be normalized.- Returns:
- DoG of the image.
-
-
DataMelt 3.0 © DataMelt by jWork.ORG