import java.awt.AWTException; import java.awt.Rectangle; import java.awt.Robot; import java.awt.Toolkit; import java.awt.image.BufferedImage; import java.io.IOException;
public static BufferedImage getScreenCapture() throws AWTException, IOException { return new Robot().createScreenCapture(new Rectangle(Toolkit.getDefaultToolkit().getScreenSize())); }
沒有留言 :
張貼留言