Capture pictures using Jpython
Becuz it is a jpython code, we can use it in Sikuli.
from time import strftime, gmtime
from java.awt import Toolkit
from java.awt import Robot
from java.awt import Rectangle
from javax.imageio import ImageIO
from java.io import File tk = Toolkit.getDefaultToolkit()
ss = tk.getScreenSize()
rbt = Robot()
wait(2)
bimage = rbt.createScreenCapture(Rectangle(ss))
setTime = strftime("%Y_%m_%d_%H_%M_%S", time.localtime())
ImageIO.write(bimage, "png", File("C:\\screenshot_"+ setTime +".png"))
Capture pictures using Jpython的更多相关文章
- 【转】[fix] Wireshark error: There are no interfaces on which a capture can be done. on Mac OS X
I got the following error message when trying to open a network interface for capture using Wireshar ...
- Wireshark设置interface 时提示“There are no interfaces on which a capture can be done ”
Wireshark设置interface 时提示“There are no interfaces on which a capture can be done ” 解决方法: 今天在电脑上安装了WIR ...
- HTML5属性--(capture="camera") 上传照片或者打开手机相机
要获取手机相机拍照或者访问相册 这里贴一个相关链接:http://blog.csdn.net/jackfrued/article/details/8967667 JSP页面代码: <inp ...
- SPX Instant Screen Capture
Today I will recommend a NICE screen capture tool, which name is SPA Instant Screen Capture. http:// ...
- 在webapp上使用input:file, 指定capture属性调用默许相机,摄像,录音功能
## 在webapp上使用input:file, 指定capture属性调用默认相机,摄像,录音功能 在iOS6下开发webapp,使用inputz之file,很有用 <input type=& ...
- <input type="file" id="camera" multiple="multiple" capture="camera" accept="image/*"> 上传图片,手机调用相册和摄像头
<input type="file" id="camera" multiple="multiple" capture="ca ...
- DirectX.Capture Namespace
DirectX.Capture Class Library DirectX.Capture Namespace The DirectX.Capture namespace contains cla ...
- DirectX.Capture Class Library
DirectX.Capture Class Library Brian Low, 29 Mar 2008 ...
- Capture
1.导出Logical symbol 单个元件导出放入指定库:左键选中元件→右键“Edit Parts”→View“Package”→file“Save As”→找到要存放的库. 从某个已经设计好的原 ...
随机推荐
- 解析安装mysql
大多数人在结束咱们前面学习的基础知识的时候,其实一脸懵逼,不过我们已经开始步入了另一个新的高度,针对基础知识还是必须巩固针对性的进行补充,可以分模块总结:比如基础知识的数据结构---->函数-- ...
- docker安装es
下载镜像 docker pull docker.elastic.co/elasticsearch/elasticsearch:6.8.1 创建容器并映射docker run -e ES_JAVA_OP ...
- Invalid operator< assertion error解析
这两天忙着在准备3月份打PAT考试,许久没有接触刷题了,各种生疏各种忘记,刷题速度那是一个慢,真是为自己智商着急.今天刷题碰到了一个有意思的编程习惯性错误,好几道题都涉及到自定义排序,需要自己重写&l ...
- tf.expand_dims
想要增加一维,可以使用tf.expand_dims(input, dim, name=None)函数 t = np.array(np.arange(1, 1 + 30).reshape([2, 3, ...
- Codeforces 图论题板刷(2000~2400)
前言 首先先刷完这些在说 题单 25C Roads in Berland 25D Roads not only in Berland 9E Interestring graph and Apples ...
- u盘被占用,无法弹出解决办法
方法1.把鼠标放到电脑屏幕最底部的中央,点击右键,点击 任务管理器 方法2.按:CTRL+ALT+ENTER(回车) 打开任务管理器,点击 进入性能后点击下方的:资源管理器 回到桌面,查看 ...
- 破解 MyEclipse For Spring 的步骤
破解 MyEclipse For Spring 的步骤: 1.关闭myeclipse: 2.运行破解工具,写上UserCode,最好是 8 位以上, 3.注意选择 myeclipse 的版本,我提供的 ...
- Android 一键分享功能简单实现
import java.io.File;import java.util.ArrayList;import java.util.List; import android.content.Context ...
- BaseActivity 基类
public abstract class BaseActivity extends AppCompatActivity implements IBaseView { private ProxyAct ...
- http预请求 options
问题 使用axios请求接口时,出现了发出两次请求的情况:一个是请求OPTIONS,一个是正常的POST请求:查资料发现与跨域请求有关. 概念 MDN中有提到: 出于安全原因,浏览器限制从脚本内发起的 ...