Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoman Sorokin <sorok-roma@yandex.ru>2014-08-05 17:22:19 +0400
committerAlex Zolotarev <alex@maps.me>2015-09-23 02:23:33 +0300
commit026d4bca976345a1d79c9ce6d52436da086a522c (patch)
tree3f6fb8d5b424ae6045501f5b978c23b460e62f34 /geometry/spline.cpp
parent9b32cde478e1e0b573e2db95474f3a5140977c2a (diff)
small fix
Diffstat (limited to 'geometry/spline.cpp')
-rw-r--r--geometry/spline.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/geometry/spline.cpp b/geometry/spline.cpp
index 64ba61cfe8..ef6f9b6e07 100644
--- a/geometry/spline.cpp
+++ b/geometry/spline.cpp
@@ -3,7 +3,7 @@
namespace m2
{
-Spline::Spline(vector<PointF> const & path)
+Spline::Spline(vector<PointF> const & path) : m_lengthAll(0.0f)
{
ASSERT(path.size() > 1, ("Wrong path size!"));
m_position.assign(path.begin(), path.end());
@@ -28,8 +28,8 @@ void Spline::AddPoint(PointF const & pt)
{
PointF dir = pt - m_position.back();
m_position.push_back(pt);
- m_direction.push_back(dir.Normalize());
m_length.push_back(dir.Length());
+ m_direction.push_back(dir.Normalize());
m_lengthAll += m_length.back();
}
}