|
MayaFlux 0.4.0
Digital-First Multimedia Processing Framework
|
| std::function<void(uint64_t endpoint_id, std::function<void(uint64_t, const uint8_t*, size_t, std::string_view)> callback)> MayaFlux::Registry::Service::NetworkService::set_endpoint_receive_callback |
Register a per-endpoint receive callback.
| endpoint_id | Endpoint to listen on. |
| callback | Called on the backend's receive thread. |
Overrides any previously registered callback for this endpoint. For endpoints opened with EndpointRole::SEND this is a no-op.
Thread safety: the callback fires on the backend's receive thread. If the consumer needs to bridge to a different thread (audio callback, coroutine scheduler), it must handle that in the callback body (e.g., push into a lock-free queue, set an atomic flag).
Definition at line 134 of file NetworkService.hpp.
Referenced by MayaFlux::Core::InputManager::setup_osc_bridge(), and MayaFlux::Vruta::NetworkSource::~NetworkSource().