Hugin trunk
0.1
Loading...
Searching...
No Matches
hugin_cpfind
localfeatures
Homography.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2007-2008 Anael Orlinski
3
*
4
* This file is part of Panomatic.
5
*
6
* Panomatic is free software; you can redistribute it and/or modify
7
* it under the terms of the GNU General Public License as published by
8
* the Free Software Foundation; either version 2 of the License, or
9
* (at your option) any later version.
10
*
11
* Panomatic is distributed in the hope that it will be useful,
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
* GNU General Public License for more details.
15
*
16
* You should have received a copy of the GNU General Public License
17
* along with Panomatic; if not, write to the Free Software
18
* <http://www.gnu.org/licenses/>.
19
*/
20
21
#ifndef __lsurf_homography_h
22
#define __lsurf_homography_h
23
24
#include <iostream>
25
26
#include "
PointMatch.h
"
27
#include <vector>
28
29
namespace
lfeat
30
{
31
32
class
LFIMPEX
Homography
33
{
34
public
:
35
Homography
();
36
~Homography
();
37
38
void
initMatchesNormalization(
PointMatchVector_t
&
iMatches
);
39
40
bool
estimate(
PointMatchVector_t
&
iMatches
);
41
42
friend
std::ostream&
operator<<
(std::ostream& o,
const
Homography
&
H
);
43
44
void
transformPoint(
double
iX
,
double
iY
,
double
&
oX
,
double
&
oY
);
45
46
47
private
:
48
void
initialize
(
void
);
49
50
void
addMatch(
size_t
iIndex
,
PointMatch
&
iMatch
);
51
52
static
const
int
kNCols
;
53
54
55
void
allocMemory(
int
iNPoints
);
56
void
freeMemory();
57
58
// the matrices for solving least squares
59
double
**
_Amat
;
60
double
*
_Bvec
;
61
double
*
_Rvec
;
62
double
*
_Xvec
;
63
64
public
:
65
double
_H[3][3];
// the homography matrix.
66
int
_nMatches
;
// number of matches to calc homography
67
68
// values for vector normalization
69
double
_v1x
, _v2x, _v1y, _v2y;
70
71
72
};
73
74
std::ostream&
operator<<
(std::ostream& o,
const
Homography
&
H
);
75
76
}
77
78
#endif
// __lsurf_homography_h
79
PointMatch.h
lfeat::Homography
Definition
Homography.h:33
lfeat::Homography::initialize
void initialize(void)
lfeat::Homography::_Bvec
double * _Bvec
Definition
Homography.h:60
lfeat::Homography::_v1x
double _v1x
Definition
Homography.h:69
lfeat::Homography::kNCols
static const int kNCols
Definition
Homography.h:52
lfeat::Homography::_Amat
double ** _Amat
Definition
Homography.h:59
lfeat::Homography::_Xvec
double * _Xvec
Definition
Homography.h:62
lfeat::Homography::_nMatches
int _nMatches
Definition
Homography.h:66
lfeat::Homography::_Rvec
double * _Rvec
Definition
Homography.h:61
operator<<
std::ostream & operator<<(std::ostream &o, const hugin_utils::TDiff2D< T > &d)
Definition
hugin_math.h:250
LFIMPEX
#define LFIMPEX
Definition
hugin_shared.h:41
lfeat
Definition
TestCode.h:27
lfeat::operator<<
std::ostream & operator<<(std::ostream &o, const Homography &H)
Definition
Homography.cpp:130
lfeat::PointMatchVector_t
std::vector< PointMatchPtr > PointMatchVector_t
Definition
PointMatch.h:53
lfeat::PointMatch
Definition
PointMatch.h:33
threshold
std::vector< deghosting::BImagePtr > threshold(const std::vector< deghosting::FImagePtr > &inputImages, const double threshold, const uint16_t flags)
Threshold function used for creating alpha masks for images.
Definition
threshold.h:41
Generated on Sun Sep 6 2026 02:43:02 for Hugin trunk by
1.9.8