usnistgov / OOF3D

Object Oriented for Finite Elements 3D version code.
http://www.ctcms.nist.gov/oof/oof3d/
34 stars 6 forks source link

"Threaded" mouse handlers in unthreaded mode #4

Open snarkhunter opened 7 years ago

snarkhunter commented 7 years ago

The click and drag mouse handlers for the clipping planes and pixel selection methods rely on a daemon thread with an infinite loop and a pthread condition variable to process the events. Currently, in unthreaded mode subthread.daemon() will start the infinite loop and never return. We need some way of handling the events synchronously when in unthreaded mode.

snarkhunter commented 7 years ago

We may need to switch back and not use daemon threads. Linux is crashing on exit when a daemon thread is waiting on pthread_cond_wait.