summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/libcamera/camera_manager.h38
-rw-r--r--include/libcamera/libcamera.h1
-rw-r--r--include/libcamera/meson.build1
3 files changed, 40 insertions, 0 deletions
diff --git a/include/libcamera/camera_manager.h b/include/libcamera/camera_manager.h
new file mode 100644
index 00000000..9d032d71
--- /dev/null
+++ b/include/libcamera/camera_manager.h
@@ -0,0 +1,38 @@
+/* SPDX-License-Identifier: LGPL-2.1-or-later */
+/*
+ * Copyright (C) 2018, Google Inc.
+ *
+ * camera_manager.h - Camera management
+ */
+#ifndef __LIBCAMERA_CAMERA_MANAGER_H__
+#define __LIBCAMERA_CAMERA_MANAGER_H__
+
+#include <vector>
+#include <string>
+
+namespace libcamera {
+
+class Camera;
+class DeviceEnumerator;
+class PipelineHandler;
+
+class CameraManager
+{
+public:
+ CameraManager();
+
+ int start();
+ void stop();
+
+ std::vector<std::string> list() const;
+ Camera *get(const std::string &name);
+ void put(Camera *camera);
+
+private:
+ DeviceEnumerator *enumerator_;
+ std::vector<PipelineHandler *> pipes_;
+};
+
+} /* namespace libcamera */
+
+#endif /* __LIBCAMERA_CAMERA_MANAGER_H__ */
diff --git a/include/libcamera/libcamera.h b/include/libcamera/libcamera.h
index 44c094d9..32fb1ff7 100644
--- a/include/libcamera/libcamera.h
+++ b/include/libcamera/libcamera.h
@@ -8,6 +8,7 @@
#define __LIBCAMERA_LIBCAMERA_H__
#include <libcamera/camera.h>
+#include <libcamera/camera_manager.h>
namespace libcamera {
diff --git a/include/libcamera/meson.build b/include/libcamera/meson.build
index 9b266ad9..3e04557d 100644
--- a/include/libcamera/meson.build
+++ b/include/libcamera/meson.build
@@ -1,5 +1,6 @@
libcamera_api = files([
'camera.h',
+ 'camera_manager.h',
'libcamera.h',
])