use of boofcv.alg.transform.pyramid.PyramidDiscreteSampleBlur in project BoofCV by lessthanoptimal.
the class FactoryPyramid method discreteGaussian.
/**
* Creates an updater for discrete pyramids where a Gaussian is convolved across the input
* prior to sub-sampling.
*
* @param imageType Type of input image.
* @param sigma Gaussian sigma. If < 0 then a sigma is selected using the radius. Try -1.
* @param radius Radius of the Gaussian kernel. If < 0 then the radius is selected using sigma. Try 2.
* @return PyramidDiscrete
*/
public static <T extends ImageBase<T>> PyramidDiscrete<T> discreteGaussian(int[] scaleFactors, double sigma, int radius, boolean saveOriginalReference, ImageType<T> imageType) {
Class<Kernel1D> kernelType = FactoryKernel.getKernelType(imageType.getDataType(), 1);
Kernel1D kernel = FactoryKernelGaussian.gaussian(kernelType, sigma, radius);
return new PyramidDiscreteSampleBlur<>(kernel, sigma, imageType, saveOriginalReference, scaleFactors);
}
Aggregations