Class AutomaticThresholding


  • public class AutomaticThresholding
    extends java.lang.Object
    Given a buffered image with bimodal histogram, we'll segment that image into foreground and background using automatic thresholding mechanism.

    This one implements Otsu's Algorithm.

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.awt.image.BufferedImage segment​(java.awt.image.BufferedImage img)
      Performs automatic thresholding based image segmentation op, using Otsu's Algorithm
      java.awt.image.BufferedImage segment​(java.lang.String img)
      Performs automatic thresholding based image segmentation op, using Otsu's Algorithm
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AutomaticThresholding

        public AutomaticThresholding()
    • Method Detail

      • segment

        public java.awt.image.BufferedImage segment​(java.awt.image.BufferedImage img)
        Performs automatic thresholding based image segmentation op, using Otsu's Algorithm
        Parameters:
        img - Image to be segmented
        Returns:
        Segmented image
      • segment

        public java.awt.image.BufferedImage segment​(java.lang.String img)
        Performs automatic thresholding based image segmentation op, using Otsu's Algorithm
        Parameters:
        img - Image to be segmented
        Returns:
        Segmented image