CameraBridge
Thread-safe handle for non-main-thread code (OPAL tasks, background workers) to request camera state changes on the UI's live CameraController.
| Inherits | QObject |
| Group | construct |
In the namespace construct. Declared in src/libs/libconstruct/construct/CameraBridge.hpp.
Detailed description
OPAL tasks run on a worker thread inside the task runtime. They must not touch QRhi / QWidget state directly. CameraBridge sits between them and ConstructShell:
- Tasks call the
Q_INVOKABLEentry points (orQMetaObject::invokeMethodwithQt::QueuedConnection). - The corresponding
*Requestedsignal is emitted. ConstructShellconnects the signals to its own methods on the main thread (defaultQt::AutoConnectionbecomes QueuedConnection when sender and receiver live on different threads).
The bridge is owned by ConstructShell and registered with ConstructServiceLocator so tasks can find it without depending on the UI layer.