Esempio n. 1
0
  public static void main(String[] args) throws IOException {
    FileInputStream fin = new FileInputStream("F:\\passCodeAction.jpg");
    BufferedImage bi = ImageIO.read(fin);
    ImageFilter flt = new ImageFilter(bi);
    flt.changeGrey();
    flt.getMedian();
    flt.getGrey();
    flt.getBrighten();
    bi = flt.getProcessedImg();

    File file = new File("F:\\passCode.jpg");
    ImageIO.write(bi, "jpg", file);
  }
Esempio n. 2
0
  public static void filterImage(String uri) throws IOException {
    FileInputStream fin = new FileInputStream(uri);
    BufferedImage bi = ImageIO.read(fin);
    ImageFilter flt = new ImageFilter(bi);
    flt.changeGrey();
    flt.getMedian();
    flt.getGrey();
    flt.getBrighten();
    bi = flt.getProcessedImg();

    File file = new File(uri);
    ImageIO.write(bi, "jpg", file);
  }