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的更多相关文章

  1. 【转】[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 ...

  2. 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 ...

  3. HTML5属性--(capture="camera") 上传照片或者打开手机相机

    要获取手机相机拍照或者访问相册    这里贴一个相关链接:http://blog.csdn.net/jackfrued/article/details/8967667 JSP页面代码: <inp ...

  4. SPX Instant Screen Capture

    Today I will recommend a NICE screen capture tool, which name is SPA Instant Screen Capture. http:// ...

  5. 在webapp上使用input:file, 指定capture属性调用默许相机,摄像,录音功能

    ## 在webapp上使用input:file, 指定capture属性调用默认相机,摄像,录音功能 在iOS6下开发webapp,使用inputz之file,很有用 <input type=& ...

  6. <input type="file" id="camera" multiple="multiple" capture="camera" accept="image/*"> 上传图片,手机调用相册和摄像头

    <input type="file" id="camera" multiple="multiple" capture="ca ...

  7. DirectX.Capture Namespace

    DirectX.Capture Class Library   DirectX.Capture Namespace The DirectX.Capture namespace contains cla ...

  8. DirectX.Capture Class Library

    DirectX.Capture Class Library Brian Low,              29 Mar 2008                                    ...

  9. Capture

    1.导出Logical symbol 单个元件导出放入指定库:左键选中元件→右键“Edit Parts”→View“Package”→file“Save As”→找到要存放的库. 从某个已经设计好的原 ...

随机推荐

  1. linux tcp/ip 调优

    sysctl 变量修改方法:sysctl –a 使用 sysctl 命令修改系统变量,和通过编辑 sysctl.conf 文件来修改系统变量两种.但并不是所有的 变量都可以在这个模式下设定. 注:sy ...

  2. python面向对象的三大特征--多态

    #什么是多态:由不同的类实例化得到的对象,调用同一个方法,执行的逻辑不同 #多态体现在由一个类实例化出多个对象,这些对象执行相同的方法时,执行的过程和结果不一样--不同的对象调用相同的方法 #多态的概 ...

  3. [python 学习] sax

    #!/usr/bin/python # -*- coding: UTF-8 -*- import xml.sax class MovieHandler( xml.sax.ContentHandler ...

  4. Flutter-TextField初始化值和選中取值

    import 'package:flutter/material.dart'; class PersonalCenterInformationScreen extends StatefulWidget ...

  5. BZOJ 5046 分糖果游戏

    网页崩溃了 心态也崩溃了 MD劳资写了那么多 题意: 有a,b两个人分糖,每个人都有一个能量值.每个人每一轮可以选择进行两种操作: 1.取走最左边的糖果,补充相应的能量值并获取相应的美味度. 2.跳过 ...

  6. pspice建立仿真模型元件库

    摘自:http://royroyyy.blog.163.com/blog/static/1376506172011026102216175/ PSpice9.2电子元器件模型--由网页下载的model ...

  7. Harbor修改暴露端口

    把原来的端口映射改成1180 一 修改docker-compose.yml [root@topcheer ~]# cat /mnt/harbor/docker-compose.yml version: ...

  8. python-zx笔记9-单元测试

    unittest核心要素 1.TestCase 一个TestCase的实例就是一个测试用例.什么是测试用例呢?就是一个完整的测试流程,包括测试前准备环境的搭建(setUp),执行测试代码(run),以 ...

  9. drawRect

    1) 画笔设置 Paint.Style.STROKE 中空模式 paint = new Paint(); //新建一个画笔对象 paint.setAntiAlias(true);//抗锯齿功能 pai ...

  10. centos7升级kernel之后,vmware无法打开

    12.57版本的vmware: https://my.vmware.com/group/vmware/details?downloadGroup=WKST-1257-LX&productId= ...