libcamera v0.7.2+1-aebe4861-nvm
Supporting cameras in Linux since 2019
Loading...
Searching...
No Matches
lsc_table.h
1/* SPDX-License-Identifier: LGPL-2.1-or-later */
2/*
3 * Copyright (C) 2026, Ideas On Board
4 *
5 * Table-based Lsc implementation
6 */
7#pragma once
8
9#include <vector>
10
11#include <libcamera/base/log.h>
12
13#include <libcamera/geometry.h>
14
16
17#include "lsc_base.h"
18
19namespace libcamera {
20
22
23namespace ipa {
24
26{
27public:
28 int parseLscData(const ValueNode &sets,
29 const LscDescriptor &descriptor) override;
30
32 sampleForCrop([[maybe_unused]] const Rectangle &cropRectangle,
33 [[maybe_unused]] std::vector<double> xPos,
34 [[maybe_unused]] std::vector<double> yPos) override
35 {
36 LOG(LscTable, Warning)
37 << "Tabular LSC data doesn't support resampling";
38 return lscData_;
39 }
40
41private:
42 int parseLscComponent(const ValueNode &yamlSet,
43 unsigned int ct, const LscDescriptor &descriptor);
44 std::vector<float> parseTable(const ValueNode &tuningData,
45 const char *prop,
46 unsigned int numHSamples,
47 unsigned int numVSamples);
48
50};
51
52} /* namespace ipa */
53
54} /* namespace libcamera */
Describe a rectangle's position and dimensions.
Definition geometry.h:247
A class representing a tree structure of values.
Definition value_node.h:27
Pure virtual base class for LSC algorithm implementations.
Definition lsc_base.h:33
std::map< unsigned int, Components > ComponentsMap
Associate a colour temperature to a LSC table.
Definition lsc_base.h:36
Table based LSC algorithm implementation.
Definition lsc_table.h:26
int parseLscData(const ValueNode &sets, const LscDescriptor &descriptor) override
Parse tabular LSC data.
Definition lsc_table.cpp:40
LscImplementation::ComponentsMap sampleForCrop(const Rectangle &cropRectangle, std::vector< double > xPos, std::vector< double > yPos) override
Re-sample the LSC components for cropRectangle.
Definition lsc_table.h:32
Data structures related to geometric objects.
Logging infrastructure.
#define LOG_DECLARE_CATEGORY(name)
Declare a category of log messages.
Definition log.h:51
#define LOG(category, severity)
Log a message.
Definition log.h:155
Base types and definitions for LscImplementation class hierarchy.
Top-level libcamera namespace.
Definition backtrace.h:17
Describe the ISP LSC engine.
Definition lsc_base.h:25
Data structure to manage tree of values.