blob: c6168e30fb2e0891c6eb32b5401976c70b77834e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
/* SPDX-License-Identifier: LGPL-2.1-or-later */
/*
* Copyright (C) 2021, Red Hat
*
* af.h - IPU3 Af algorithm
*/
#pragma once
#include <linux/intel-ipu3.h>
#include <libcamera/base/utils.h>
#include <libcamera/geometry.h>
#include "algorithm.h"
namespace libcamera {
namespace ipa::ipu3::algorithms {
class Af : public Algorithm
{
/* The format of y_table. From ipu3-ipa repo */
typedef struct __attribute__((packed)) y_table_item {
uint16_t y1_avg;
uint16_t y2_avg;
} y_table_item_t;
public:
Af();
~Af() = default;
int configure(IPAContext &context, const IPAConfigInfo &configInfo) override;
void prepare(IPAContext &context, const uint32_t frame,
IPAFrameContext &frameContext,
ipu3_uapi_params *params) override;
void process(IPAContext &context, const uint32_t frame,
IPAFrameContext &frameContext,
const ipu3_uapi_stats_3a *stats,
|