static BufferedImage twoColorImage(Color bg, Color fg, IBinaryImage image) { ret image == null ?: bufferedImageFromFunctionWithoutAlpha( image.getWidth(), image.getHeight(), (x, y) -> image.getBoolPixel_noRangeCheck(x, y) ? fg : bg); }