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”→找到要存放的库. 从某个已经设计好的原 ...
随机推荐
- HTTPS证书转换成PEM格式
PEM 格式的证书文件(*.pem)一般为以下格式: 注意:PEM 格式证书文件可用 notepad++ 等文本编辑器打开. CER / CRT 格式证书转换为 PEM 格式 对于 CER / CRT ...
- linux手动测试 rsync 的同步情况
特别强调:此步很关键,如果这不能同步,后面的 inotify 配好了也不会同步数据. 1) 分别创建待同步数据 [root@rsync-client-inotify ~]# mkdir /data/{ ...
- tf.reshape
tf.reshape(tensor, shape, name=None) 其中,tensor是向量,或者说矩阵 shape是转换后的向量,或者转换后的矩阵形状 [2,1]转换成二行一列 [2,-1]转 ...
- python内存分析
安装 首先安装memory_profiler和psutil pip install memory_profiler pip install psutil 在需要分析的函数前面添加装饰器@profile ...
- xargs 将标准输入转换成命令行参数
1. 命令功能 xargs 命令过滤器,接收管道或者标准输入传递的数据转换成xargs命令. 2. 语法格式 xargs [option] xargs 选项 参数 参数说明 -n 指定每行的最大参数 ...
- Task4.文本表示:从one-hot到word2vec
参考:https://blog.csdn.net/wxyangid/article/details/80209156 1.one-hot编码 中文名叫独热编码.一位有效编码.方法是使用N位状态寄存器来 ...
- 分享一个知乎答案 最详细易懂的 js闭包
作者:大闲人柴毛毛 链接:https://www.zhihu.com/question/34210214/answer/136673471 来源:知乎 著作权归作者所有.商业转载请联系作者获得授权,非 ...
- php compact()函数 语法
php compact()函数 语法 作用:创建包含变量名和它们的值的数组.大理石构件哪家好 语法:compact(var1,var2...) 参数: 参数 描述 var1 必需.可以是带有变量名的字 ...
- 写php用什么编辑器
编辑器是编程工作者强有力的工具,一款好的编辑器可以大大加快程序员的开发速度.那么,如何在众多编辑器中选出顺手的编辑器呢? 下面为大家推荐几款好评较多的编辑器: 1.NetBeans —— 免费,开源, ...
- Log4d:Error:Could not instantiate class[com.mapgis.util.tools.JDBCExtAppender]
https://blog.csdn.net/gikieng/article/details/47150567 https://blog.alswl.com/2018/03/sql-server-mi ...