test_monkey.py 文件源码

python
阅读 24 收藏 0 点赞 0 评论 0

项目:ATX 作者: NetEaseGame 项目源码 文件源码
def test_grid():
    m = StupidMonkey({'touch':10})
    poss = []
    while True:
        pos = m.get_touch_point()
        if not pos:
            break
        poss.append(pos)
    print 'grid point count:', len(poss)

    import cv2
    import numpy
    img = numpy.zeros((1920, 1080))
    for x,y in poss:
        img[x,y] = 255
    img = cv2.resize(img, (540, 960))
    cv2.imshow('grid', img)
    cv2.waitKey()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号