/* SPDX-License-Identifier: BSD-2-Clause */ /* * Copyright (C) 2020, Raspberry Pi (Trading) Limited * * focus.cpp - focus algorithm */ #include #include "libcamera/internal/log.h" #include "../focus_status.h" #include "focus.hpp" using namespace RPi; using namespace libcamera; LOG_DEFINE_CATEGORY(RPiFocus) #define NAME "rpi.focus" Focus::Focus(Controller *controller) : Algorithm(controller) { } char const *Focus::Name() const { return NAME; } void Focus::Process(StatisticsPtr &stats, Metadata *image_metadata) { FocusStatus status; unsigned int i; for (i = 0; i < FOCUS_REGIONS; i++) status.focus_measures[i] = stats->focus_stats[i].contrast_val[1][1] / 1000; status.num = i; image_metadata->Set("focus.status", status); LOG(RPiFocus, Debug) << "Focus contrast measure: " << (status.focus_measures[5] + status.focus_measures[6]) / 10; } /* Register algorithm with the system. */ static Algorithm *Create(Controller *controller) { return new Focus(controller); } static RegisterAlgorithm reg(NAME, &Create); icial repositorygit repository hosting on libcamera.org
summaryrefslogtreecommitdiff
path: root/src/qcam/assets/feathericons/server.svg
blob: 54ce094a50974ca436c778a06c4f45a95ab59680 (plain)
1
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-server"><rect x="2" y="2" width="20" height="8" rx="2" ry="2"></rect><rect x="2" y="14" width="20" height="8" rx="2" ry="2"></rect><line x1="6" y1="6" x2="6.01" y2="6"></line><line x1="6" y1="18" x2="6.01" y2="18"></line></svg>