Fawkes API
Fawkes Development Version
rht_circle.h
1
2
/***************************************************************************
3
* rht_circle.h - Header of circle shape model
4
* using Randomized Hough Transform
5
*
6
* Created: Tue Jun 28 00:00:00 2005
7
* Copyright 2005 Hu Yuxiao <Yuxiao.Hu@rwth-aachen.de>
8
*
9
****************************************************************************/
10
11
/* This program is free software; you can redistribute it and/or modify
12
* it under the terms of the GNU General Public License as published by
13
* the Free Software Foundation; either version 2 of the License, or
14
* (at your option) any later version. A runtime exception applies to
15
* this software (see LICENSE.GPL_WRE file mentioned below for details).
16
*
17
* This program is distributed in the hope that it will be useful,
18
* but WITHOUT ANY WARRANTY; without even the implied warranty of
19
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20
* GNU Library General Public License for more details.
21
*
22
* Read the full text in the LICENSE.GPL_WRE file in the doc directory.
23
*/
24
25
#ifndef _FIREVISION_RHT_CIRCLE_H_
26
#define _FIREVISION_RHT_CIRCLE_H_
27
28
#include <fvmodels/shape/accumulators/ht_accum.h>
29
#include <fvmodels/shape/circle.h>
30
#include <fvutils/base/types.h>
31
#include <utils/math/types.h>
32
33
#include <iostream>
34
#include <vector>
35
36
namespace
firevision {
37
38
class
ROI;
39
40
class
RhtCircleModel :
public
ShapeModel
41
{
42
private
:
43
std::vector<Circle> m_Circles;
44
RhtAccumulator accumulator;
45
static
const
float
RHT_MIN_RADIUS;
46
static
const
float
RHT_MAX_RADIUS;
47
48
public
:
49
RhtCircleModel
(
void
);
50
virtual
~RhtCircleModel
(
void
);
51
52
std::string
53
getName
(
void
)
const
54
{
55
return
std::string(
"RhtCircleModel"
);
56
}
57
int
parseImage
(
unsigned
char
*buffer,
ROI
*roi);
58
int
getShapeCount
(
void
)
const
;
59
Circle
*
getShape
(
int
id
)
const
;
60
Circle
*
getMostLikelyShape
(
void
)
const
;
61
62
private
:
63
void
calcCircle(
// for calculating circles from 3 points
64
const
fawkes::upoint_t
&p1,
65
const
fawkes::upoint_t
&p2,
66
const
fawkes::upoint_t
&p3,
67
center_in_roi_t
& center,
68
float
& radius);
69
};
70
71
}
// end namespace firevision
72
73
#endif // FIREVISION_RHT_CIRCLE_H__
firevision::RhtCircleModel::getName
std::string getName(void) const
Definition:
rht_circle.h:60
firevision::Circle
Definition:
circle.h:49
firevision::RhtCircleModel::getMostLikelyShape
Circle * getMostLikelyShape(void) const
Definition:
rht_circle.cpp:257
firevision::RhtCircleModel::parseImage
int parseImage(unsigned char *buffer, ROI *roi)
Definition:
rht_circle.cpp:67
fawkes::upoint_t
Point with cartesian coordinates as unsigned integers.
Definition:
types.h:34
firevision::RhtCircleModel::getShapeCount
int getShapeCount(void) const
Definition:
rht_circle.cpp:241
firevision::ROI
Definition:
roi.h:60
firevision::RhtCircleModel::RhtCircleModel
RhtCircleModel(void)
Constructor.
Definition:
rht_circle.cpp:51
firevision::RhtCircleModel::~RhtCircleModel
virtual ~RhtCircleModel(void)
Destructor.
Definition:
rht_circle.cpp:56
firevision::center_in_roi_t
Center in ROI.
Definition:
types.h:44
firevision::RhtCircleModel::getShape
Circle * getShape(int id) const
Definition:
rht_circle.cpp:247
src
libs
fvmodels
shape
rht_circle.h
Generated by
1.8.17