Class BinaryImageLoader


  • public class BinaryImageLoader
    extends Object
    Loads a file from disk and converts it into a 2D boolean array, where 0s indicate black, 1s indicate white.
    • Constructor Detail

      • BinaryImageLoader

        public BinaryImageLoader()
    • Method Detail

      • loadImage

        public static boolean[][] loadImage​(File imagePath)
                                     throws IOException
        Helper method to load an image from disk.
        Parameters:
        imagePath - as file object toward resource location. Can be absolute or relative.
        Returns:
        2D boolean array representing the images max-contrast grid, all pixels black/white.
        Throws:
        IOException