I am trying to expose data from my Bevy app to non-Bevy callers within the same address space without going through disk I/O.
The general idea is to use Bevy as the backend to run a simulation and periodically query it to extract state. Kinda similar to what the Render World is doing, but at random rather than each frame, and probably via a DLL.
The data will be Plain Old Stack Data owned by the receiver, i.e. we don't need to worry about lifetimes or anything; I'm pretty flexible on the structure(s). It doesn't need to be generic, the number of types exposed will be finite.
So far I've gotten comms going the other way by creating a static AtomicBool that the DLL user can toggle, so that seems like one option - but I was wondering if anyone might have a neater pattern around this?