Files
SingularityViewer/indra/aistatemachine
Aleric Inglewood 9114f04ef6 Add AIStateMachine::yield_if_not
This can be used to switch to a specific engine.
If the state machine is not running in the passed engine,
then it performs a yield to that engine, otherwise it keeps
running. Hence, putting this at the top of a state
guarantees that it runs in that engine.

For example:

    case FrontEnd_done:
    {
      // Unlock must be called by the same thread that locked it.
      if (yield_if_not(&gStateMachineThreadEngine))
      {
        break;
      }
      // Here we are running in gStateMachineThreadEngine.
    ...
2013-10-15 22:30:16 +02:00
..
2013-05-27 02:15:28 +02:00
2013-10-15 22:29:52 +02:00
2013-01-26 19:19:09 +01:00