summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/hid/irsensor/clustering_processor.cpp
diff options
context:
space:
mode:
authorgerman77 <juangerman-13@hotmail.com>2022-06-19 06:45:06 +0200
committergerman77 <juangerman-13@hotmail.com>2022-07-24 02:40:25 +0200
commit453970059528d564d9ef88f7f9096c05946fbefe (patch)
tree3b1a43e8dd51e5c03204108ac72c4cd33d5361c0 /src/core/hle/service/hid/irsensor/clustering_processor.cpp
parentcore: hid: Add cammera support (diff)
downloadyuzu-453970059528d564d9ef88f7f9096c05946fbefe.tar
yuzu-453970059528d564d9ef88f7f9096c05946fbefe.tar.gz
yuzu-453970059528d564d9ef88f7f9096c05946fbefe.tar.bz2
yuzu-453970059528d564d9ef88f7f9096c05946fbefe.tar.lz
yuzu-453970059528d564d9ef88f7f9096c05946fbefe.tar.xz
yuzu-453970059528d564d9ef88f7f9096c05946fbefe.tar.zst
yuzu-453970059528d564d9ef88f7f9096c05946fbefe.zip
Diffstat (limited to 'src/core/hle/service/hid/irsensor/clustering_processor.cpp')
-rw-r--r--src/core/hle/service/hid/irsensor/clustering_processor.cpp36
1 files changed, 36 insertions, 0 deletions
diff --git a/src/core/hle/service/hid/irsensor/clustering_processor.cpp b/src/core/hle/service/hid/irsensor/clustering_processor.cpp
new file mode 100644
index 000000000..aac3e4fec
--- /dev/null
+++ b/src/core/hle/service/hid/irsensor/clustering_processor.cpp
@@ -0,0 +1,36 @@
+// SPDX-FileCopyrightText: Copyright 2022 yuzu Emulator Project
+// SPDX-License-Identifier: GPL-3.0-or-later
+
+#include "core/hle/service/hid/irsensor/clustering_processor.h"
+
+namespace Service::HID {
+ClusteringProcessor::ClusteringProcessor(Core::IrSensor::DeviceFormat& device_format)
+ : device(device_format) {
+ device.mode = Core::IrSensor::IrSensorMode::ClusteringProcessor;
+ device.camera_status = Core::IrSensor::IrCameraStatus::Unconnected;
+ device.camera_internal_status = Core::IrSensor::IrCameraInternalStatus::Stopped;
+ device.state.start = 0;
+ device.state.count = 0;
+}
+
+ClusteringProcessor::~ClusteringProcessor() = default;
+
+void ClusteringProcessor::StartProcessor() {}
+
+void ClusteringProcessor::SuspendProcessor() {}
+
+void ClusteringProcessor::StopProcessor() {}
+
+void ClusteringProcessor::SetConfig(Core::IrSensor::PackedClusteringProcessorConfig config) {
+ current_config.camera_config.exposure_time = config.camera_config.exposure_time;
+ current_config.camera_config.gain = config.camera_config.gain;
+ current_config.camera_config.is_negative_used = config.camera_config.is_negative_used;
+ current_config.camera_config.light_target =
+ static_cast<Core::IrSensor::CameraLightTarget>(config.camera_config.light_target);
+ current_config.pixel_count_min = config.pixel_count_min;
+ current_config.pixel_count_max = config.pixel_count_max;
+ current_config.is_external_light_filter_enabled = config.is_external_light_filter_enabled;
+ current_config.object_intensity_min = config.object_intensity_min;
+}
+
+} // namespace Service::HID