bugman wrote in Sat Jan 23, 2016 3:04 pm:The more I look into the Nasal timer code, the more I develop a deep down sick feeling. Note that the FGPythonSys subsystem is not bound by this design, and I do not intend it to be.
With Richard's Emesary system now being ported to Nasal, it would actually make sense to look at it with a focus on FGPythonSys, i.e. how this could be moved to C++ space, and reused by the whole FGScriptingSys interface we've been talking about, because that could make timers, and listeners, entirely unnecessary - while providing the option to run scripts asynchronously from the main loop.
It would even be possible to come up with a Canvas mode where a Canvas (FBO) is
only updated using an Emesary transmitter, which would mean that these updates could be processed in a background thread, and that OSG could be also much more aggressive about updating Canvas elements/FBOs concurrently.
Note that there is nothing Nasal specific about Emesary - it's just a way to come up with a decoupled design that lets components act with eachother without having to know much/anything about their internals, and this kind of decoupling would also be useful for any HLA efforts, because HLA would be just one kind of transport, and one that could greatly benefit from having this separation in place.
http://wiki.flightgear.org/Emesary