0

I am currently building a project with leap motion and vpython (wxpython).

It is a python based project and now I have a problem that when the leap motion senser is on its process (which means that it is continuously getting data from people's hand), the vpython (wxpython) graphic window gets unresponsive (the window of vpython Not Responding, this window should represent the required graphic that i need,and at the mean time, the leap motion senser still works fine, and getting the correct data). not responding picture explaination of the above

I tryed to search in google, said that it might be a thread problem, but I have no idea how to solve it.

Feng
  • 1
  • 1
  • Are you polling for the frames of tracking data or using callback functions? – Charles Ward Oct 10 '16 at 20:07
  • Using Leap API ON-FRAME to track data – Feng Oct 11 '16 at 11:02
  • All the callback functions run in their own, independent thread. This can cause problems when communicating data to windows/controls that can only be updated on a specific thread. The easiest way to handle this is usually to poll for frames -- i.e. just call Controller.frame() on a timer or application loop (if there is one). Otherwise, you have to write the data in the Leap Motion thread and read the data in the window thread -- and make sure that both threads aren't doing it at the same time. – Charles Ward Oct 11 '16 at 20:44

0 Answers0