Ansel
0.0
A darktable fork - bloat + design vision
Loading...
Searching...
No Matches
homography.h
Go to the documentation of this file.
1
/*
2
* This file is part of darktable,
3
* Copyright (C) 2016 johannes hanika.
4
* Copyright (C) 2016, 2020 Tobias Ellinghaus.
5
* Copyright (C) 2020 Pascal Obry.
6
* Copyright (C) 2021 Sakari Kapanen.
7
* Copyright (C) 2022 Martin BaĆinka.
8
*
9
* darktable is free software: you can redistribute it and/or modify
10
* it under the terms of the GNU General Public License as published by
11
* the Free Software Foundation, either version 3 of the License, or
12
* (at your option) any later version.
13
*
14
* darktable is distributed in the hope that it will be useful,
15
* but WITHOUT ANY WARRANTY; without even the implied warranty of
16
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17
* GNU General Public License for more details.
18
*
19
* You should have received a copy of the GNU General Public License
20
* along with darktable. If not, see <http://www.gnu.org/licenses/>.
21
*/
22
23
24
#ifndef DT_MATH_HOMOGRAPHY_H
25
#define DT_MATH_HOMOGRAPHY_H
26
27
/* Planar homography: the 3x3 projective map between two quadrilaterals.
28
*
29
* This lived in chart/common.c, next to the colour-chart parser, back when the
30
* chart tool was its own program. It is plain projective geometry with no
31
* dependency on either -- iop/channelmixerrgb.c uses it to map its colour-checker
32
* bounding box, and was compiling chart/common.c directly to get at it. */
33
34
typedef
struct
point_t
35
{
36
float
x
,
y
;
37
}
point_t
;
38
41
int
get_homography
(
const
point_t
*source,
const
point_t
*target,
float
*h);
42
44
point_t
apply_homography
(
point_t
p
,
const
float
*h);
45
47
float
apply_homography_scaling
(
point_t
p
,
const
float
*h);
48
49
#endif
// DT_MATH_HOMOGRAPHY_H
p
const float p
Definition
colorspaces_inline_conversions.h:680
apply_homography
point_t apply_homography(point_t p, const float *h)
Definition
homography.c:69
apply_homography_scaling
float apply_homography_scaling(point_t p, const float *h)
Definition
homography.c:80
get_homography
int get_homography(const point_t *source, const point_t *target, float *h)
Definition
homography.c:28
point_t
Definition
censorize.c:77
point_t::x
float x
Definition
homography.h:36
point_t::y
size_t y
Definition
censorize.c:78
src
math
homography.h
Generated by
1.9.8