diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2019-01-04 21:19:38 +0200 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2019-01-08 16:23:16 +0200 |
commit | 1a57bcb8d1a7a49cc8a43596a79d57cd2fbb5dfe (patch) | |
tree | 94efe46bd05b546010c6ead62c645070aa8ab3e3 /include/libcamera/camera_manager.h | |
parent | d0fd42a4fde6cf29bae760d553d4a4f9b857810f (diff) |
libcamera: Add event notification infrastructure
Add three new classes, EventDispatcher, EventNotifier and Timer, that
define APIs for file descriptor event notification and timers. The
implementation of the EventDispatcher is meant to be provided to
libcamera by the application.
The event dispatcher is integrated twith the camera manager to implement
automatic registration of timers and events.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Diffstat (limited to 'include/libcamera/camera_manager.h')
-rw-r--r-- | include/libcamera/camera_manager.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/libcamera/camera_manager.h b/include/libcamera/camera_manager.h index e14da0f8..15e7c162 100644 --- a/include/libcamera/camera_manager.h +++ b/include/libcamera/camera_manager.h @@ -14,6 +14,7 @@ namespace libcamera { class Camera; class DeviceEnumerator; +class EventDispatcher; class PipelineHandler; class CameraManager @@ -27,13 +28,19 @@ public: static CameraManager *instance(); + void setEventDispatcher(EventDispatcher *dispatcher); + EventDispatcher *eventDispatcher(); + private: CameraManager(); CameraManager(const CameraManager &) = delete; void operator=(const CameraManager &) = delete; + ~CameraManager(); DeviceEnumerator *enumerator_; std::vector<PipelineHandler *> pipes_; + + EventDispatcher *dispatcher_; }; } /* namespace libcamera */ |