package com.image.capture;
import java.awt.AWTException;
import java.awt.Rectangle;
import java.awt.Robot;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;
import javax.imageio.ImageIO;
public class RobotExp {
public static void main(String[] args) {
try {
Robot robot = new Robot();
// Capture the screen shot of the area of the screen defined by the
// rectangle
BufferedImage bi = robot
.createScreenCapture(new Rectangle(1024, 768));
ImageIO.write(bi, "jpg", new File("C:/imageTest.jpg"));
} catch (AWTException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
}
}
最近下载更多
阿远远 LV8
2019年12月12日
yongzheng132 LV17
2019年6月24日
飞翔的企鹅嗯嗯 LV11
2019年1月29日
乞丐哥哥 LV23
2018年1月19日
15764212182 LV1
2017年7月12日
玩玩没想到 LV6
2016年2月17日
跳跳猴 LV13
2015年10月21日
M_Kepler LV2
2015年7月7日
zc420625 LV7
2015年6月25日
867747430@qq.com LV6
2015年6月25日
最近浏览更多
dearxo2014 LV1
2024年11月9日
sheep12345
2024年2月29日
暂无贡献等级
crosa_Don LV18
2022年7月6日
yangxb2 LV10
2022年5月30日
ShiRanDIE LV1
2022年1月1日
812795769 LV15
2021年4月6日
sjhdwhudsjk
2020年8月16日
暂无贡献等级
1194837897 LV5
2020年7月25日
wanggsc LV2
2020年5月11日
dragonfly1984
2020年4月7日
暂无贡献等级

