Map Matching
Main Page
Related Pages
Classes
Files
File List
File Members
pointGPS.cpp
Go to the documentation of this file.
1
#include "
pointGPS.h
"
2
3
#include <sstream>
4
5
void
PointGPS::addEmissionProbability
(
long
roadId,
double
distance)
6
{
7
EmissionProbability
e(roadId, distance);
8
m_emissionProbability
.push_back(std::move(e));
9
}
10
11
void
PointGPS::updateProbability
()
12
{
13
double
sum = 0.0;
14
for
(
auto
& e :
m_emissionProbability
)
15
sum += e.distance();
16
for
(
auto
& e : m_emissionProbability)
17
e.updateProbability(sum);
18
}
19
20
std::string
PointGPS::infos
()
const
21
{
22
std::stringstream ss;
23
ss <<
Point::infos
() <<
" with "
<<
m_emissionProbability
.size() <<
" emissions to roads < 200m"
;
24
return
ss.str();
25
}
PointGPS::m_emissionProbability
std::vector< EmissionProbability > m_emissionProbability
Definition:
pointGPS.h:42
PointGPS::addEmissionProbability
void addEmissionProbability(long roadId, double distance)
Definition:
pointGPS.cpp:5
Point::infos
virtual std::string infos() const
Definition:
point.cpp:45
EmissionProbability
Definition:
emissionprobability.h:4
PointGPS::infos
std::string infos() const
Definition:
pointGPS.cpp:20
pointGPS.h
PointGPS::updateProbability
void updateProbability()
Definition:
pointGPS.cpp:11
pointGPS.cpp
Generated on Sat Dec 3 2016 18:38:42 for Map Matching by
1.8.11