Class KuwaharaFilterScalar

All Implemented Interfaces:
KuwaharaF, ProgressReporter

public class KuwaharaFilterScalar extends GenericFilterScalar implements KuwaharaF

Scalar version of a Kuwahara-type filter, similar to the filter described in [1]. It structures the filter region into five overlapping, square subregions (including a center region) of size (r+1) x (r+1). See Sec. 17.1 of [2] for additional details.

[1] F. Tomita and S. Tsuji. Extraction of multiple regions by smoothing in selected neighborhoods. IEEE Transactions on Systems, Man, and Cybernetics 7, 394–407 (1977).
[2] W. Burger, M.J. Burge, Digital Image Processing – An Algorithmic Introduction, 3rd ed, Springer (2022).

Version:
2021/01/02
  • Constructor Details

  • Method Details

    • doPixel

      protected float doPixel(PixelPack.PixelSlice plane, int u, int v)
      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 a PixelPack.PixelSlice container, which holds the scalar values of one image component. The method PixelPack.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 class GenericFilterScalar
      Parameters:
      plane - the scalar-valued data for a single image component
      u - the current x-position
      v - the current y-position
      Returns:
      the result of the filter calculation for this pixel