public File aplicarSoma(String nomeArq, String caminho) throws IOException, Exception {
        //Calendar cal = new GregorianCalendar();
        BufferedImage controleImg = ImageIO.read(new File(caminho));
        if (controleImg.getWidth() != img.getWidth()) {
            throw new Exception("Imagem de tamanhos diferentes");
        } else if (controleImg.getHeight() != img.getHeight()) {
            throw new Exception("Imagem de tamanhos diferentes");
        }
        int[][] controImgPixel = new int[controleImg.getWidth()][controleImg.getHeight()];
        int[] rgbs = new int[controleImg.getWidth() * controleImg.getHeight()];
        PixelGrabber pixel = new PixelGrabber(controleImg, 0, 0, controleImg.getWidth(), controleImg.getHeight(), rgbs, 0, controleImg.getWidth());
        try {
            pixel.grabPixels();
            int i = 0;
            int w = 0, h = 0;
            for (int control = 0; control < rgbs.length; control++) {
                controImgPixel[w++][h] = rgbs[i++];
                if (i % controleImg.getWidth() == 0) {
                    h++;
                    w = 0;
                }
            }
            rgbs = null;
        } catch (InterruptedException ex) {
            Logger.getLogger(controleImg.class.getName()).log(Level.SEVERE, null, ex);
        }
        opBasicas ob = new opBasicas(imgPixel, controImgPixel, img.getWidth(), img.getHeight(), controleImg.getWidth(), controleImg.getHeight());
        int[][] teste = ob.somarImagem();

        //BufferedImage
        saida = new BufferedImage(ob.getMaiorw(), ob.getMaiorh(), BufferedImage.TYPE_INT_RGB);
        WritableRaster raster = saida.getRaster();
        for (int h = 0; h < img.getHeight(); h++) {
            for (int w = 0; w < img.getWidth(); w++) {
                int[] t = new int[4];
                Pixel p = new Pixel(teste[w][h]);
                t[0] = p.getVermelho();
                t[1] = p.getVerde();
                t[2] = p.getAzul();
                t[3] = p.getAlfa();
                raster.setPixel(w, h, t);
            }
        }
        try {
            //arq = new File("tmp/" + cal.get(Calendar.HOUR_OF_DAY) + cal.get(Calendar.MINUTE) + cal.get(Calendar.SECOND) + "GAMBI1" + nomeArq);
            arq = new File("tmp/" + timestamp("SOMA") + nomeArq);
            ImageIO.write(saida, "JPG", arq);
        } catch (IOException ex) {
            Logger.getLogger(controleImg.class.getName()).log(Level.SEVERE, null, ex);
        }
        return arq;
    }