示例#1
0
    def test(self):
        full_path = os.path.realpath(__file__)
        path, filename = os.path.split(full_path)

        recognizer = BoardRecognizer(path + '/tests/test-1.avi')

        while True:
            print recognizer.getBoardState()

            if cv2.waitKey(10) == ord('q'):
                break
示例#2
0
    def test(self):
        full_path = os.path.realpath(__file__)
        path, filename = os.path.split(full_path)

        recognizer = BoardRecognizer(path + '/tests/test-1.avi')

        while True:
            print recognizer.getBoardState()

            if cv2.waitKey(10) == ord('q'):
                break
示例#3
0
    def getBoardState(self):
        recognizer = BoardRecognizer(0)

        try:
            board = recognizer.getBoardState()
            return board
        except Exception as e:
            print "An error occured"
            print e
示例#4
0
    def getBoardState(self):
        recognizer = BoardRecognizer(0)

        try:
            board = recognizer.getBoardState()
            return board
        except Exception as e:
            print "An error occured"
            print e