Java examples for 2D Graphics:JPEG
save JPEG Image
//package com.java2s; import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; import javax.imageio.ImageIO; public class Main { public static void saveJPEGImage(BufferedImage image, String pathWithoutExtension) throws IOException { ImageIO.write(image, "jpg", new File(pathWithoutExtension + ".jpg")); }/*from ww w. j a v a 2 s. co m*/ }