質問内容
Python3でLeap Motionを参考にpython3.7環境でLeap Motionを使えるようにしたのですが、以下のプログラムを実行したところ以下のようなエラーが発生しました。このプログラムをpython2.7環境で実行したところエラーなくできました。
python
1import Leap, sys, time 2controller = Leap.Controller() 3while True: 4 frame = controller.frame() 5 6 for hand in frame.hands: 7 handType = "Left hand" if hand.is_left else "Right hand" 8 9 if frame.hands.is_empty: 10 print("not hand") 11 12 if not frame.hands.is_empty: 13 print ("Middle x:%s"% (hand.palm_position.x)) 14 print ("Middle y:%s"% (hand.palm_position.y)) 15 print ("Middle z:%s"% (hand.palm_position.z))
エラーコード
Traceback (most recent call last): File "pa.py", line 11, in <module> for hand in frame.hands: SystemError: <built-in function delete_HandList> returned a result with an error set
あなたの回答
tips
プレビュー