summaryrefslogtreecommitdiff
path: root/src/android/camera_hal_manager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/android/camera_hal_manager.cpp')
-rw-r--r--src/android/camera_hal_manager.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/android/camera_hal_manager.cpp b/src/android/camera_hal_manager.cpp
index f5b86974..54087d3a 100644
--- a/src/android/camera_hal_manager.cpp
+++ b/src/android/camera_hal_manager.cpp
@@ -37,6 +37,13 @@ CameraHalManager::CameraHalManager()
/* CameraManager calls stop() in the destructor. */
CameraHalManager::~CameraHalManager() = default;
+/* static */
+CameraHalManager *CameraHalManager::instance()
+{
+ static CameraHalManager *cameraHalManager = new CameraHalManager;
+ return cameraHalManager;
+}
+
int CameraHalManager::init()
{
cameraManager_ = std::make_unique<CameraManager>();