Module imagingbook.common
Class NagaoMatsuyamaFilterScalar
java.lang.Object
imagingbook.common.filter.generic.GenericFilter
imagingbook.common.filter.generic.GenericFilterScalar
imagingbook.common.filter.edgepreserving.NagaoMatsuyamaFilterScalar
- All Implemented Interfaces:
NagaoMatsuyamaF
,ProgressReporter
Scalar version of the Nagao-Matsuyama filter. This class implements a 5x5 Nagao-Matsuyama filter, as described in [1]. See Sec. 17.1 of [2] for additional details.
[1] M. Nagao and T. Matsuyama. Edge preserving smoothing. Computer Graphics and Image Processing 9(4), 394–407
(1979).
[2] W. Burger, M.J. Burge, Digital Image Processing – An Algorithmic Introduction, 3rd ed, Springer
(2022).
- Version:
- 2021/01/02
-
Nested Class Summary
Nested classes/interfaces inherited from interface imagingbook.common.filter.edgepreserving.NagaoMatsuyamaF
NagaoMatsuyamaF.Constants, NagaoMatsuyamaF.Parameters
-
Constructor Summary
ConstructorsConstructorDescription -
Method Summary
Modifier and TypeMethodDescriptionprotected float
doPixel
(PixelPack.PixelSlice plane, int u, int v) This method defines the steps to be performed for a single image pixel and must be implemented by any concrete sub-class.Methods inherited from class imagingbook.common.filter.generic.GenericFilterScalar
reportProgress, runPass
Methods inherited from class imagingbook.common.filter.generic.GenericFilter
abort, applyTo, applyTo, applyTo, closeFilter, getDepth, getHeight, getPass, getProgress, getWidth, initFilter, initPass, passesRequired, reportProgress
-
Constructor Details
-
NagaoMatsuyamaFilterScalar
public NagaoMatsuyamaFilterScalar() -
NagaoMatsuyamaFilterScalar
-
-
Method Details
-
doPixel
Description copied from class:GenericFilterScalar
This method defines the steps to be performed for a single image pixel and must be implemented by any concrete sub-class. The source data are passed as aPixelPack.PixelSlice
container, which holds the scalar values of one image component. The methodPixelPack.PixelSlice.getVal(int, int)
should be used to read individual pixel values. These data should not be modified but the (float) result of the single-pixel calculation must be returned.- Specified by:
doPixel
in classGenericFilterScalar
- Parameters:
plane
- the scalar-valued data for a single image componentu
- the current x-positionv
- the current y-position- Returns:
- the result of the filter calculation for this pixel
-