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 13:34:00 +0400
committerAlex Zolotarev <alex@maps.me>2015-09-23 02:23:27 +0300
commita01ed92d8abc9edc86b9f958bb4bd8d891762fcd (patch)
tree44281cea6e1fc1413193a3779e7fed1db4edef48 /geometry/geometry_tests
parent2f07cd115f2e65133e7147a77a8385b8ddf52fea (diff)
removed method FromArray
Diffstat (limited to 'geometry/geometry_tests')
-rw-r--r--geometry/geometry_tests/spline_test.cpp24
1 files changed, 8 insertions, 16 deletions
diff --git a/geometry/geometry_tests/spline_test.cpp b/geometry/geometry_tests/spline_test.cpp
index 5e1327634a..aa03af8af0 100644
--- a/geometry/geometry_tests/spline_test.cpp
+++ b/geometry/geometry_tests/spline_test.cpp
@@ -21,8 +21,7 @@ UNIT_TEST(SmoothedDirections)
path.push_back(PointF(40, 40));
path.push_back(PointF(80, 0));
- Spline spl;
- spl.FromArray(path);
+ Spline spl(path);
float const sqrt2 = sqrtf(2.0f);
Spline::iterator itr;
PointF dir1(sqrt2 / 2.0f, sqrt2 / 2.0f);
@@ -44,8 +43,7 @@ UNIT_TEST(SmoothedDirections)
path.push_back(PointF(120, 0));
PointF dir12(1.0f, 0.0f);
- Spline spl2;
- spl2.FromArray(path);
+ Spline spl2(path);
itr.Attach(spl2);
TestPointFDir(itr.m_avrDir, dir1);
itr.Step(sqrt2 * 80.0f + 40.0f);
@@ -64,8 +62,7 @@ UNIT_TEST(UsualDirections)
path.push_back(PointF(40, 40));
path.push_back(PointF(80, 0));
- Spline spl;
- spl.FromArray(path);
+ Spline spl(path);
float const sqrt2 = sqrtf(2.0f);
Spline::iterator itr;
PointF dir1(sqrt2 / 2.0f, sqrt2 / 2.0f);
@@ -85,8 +82,7 @@ UNIT_TEST(UsualDirections)
path.push_back(PointF(120, 0));
PointF dir12(1.0f, 0.0f);
- Spline spl2;
- spl2.FromArray(path);
+ Spline spl2(path);
itr.Attach(spl2);
TestPointFDir(itr.m_dir, dir1);
itr.Step(sqrt2 * 80.0f + 35.0f);
@@ -105,9 +101,8 @@ UNIT_TEST(Positions)
path.push_back(PointF(40, 40));
path.push_back(PointF(80, 0));
- Spline spl0;
+ Spline spl0(path);
Spline spl4;
- spl0.FromArray(path);
spl4 = spl0;
float const sqrt2 = sqrtf(2.0f);
Spline::iterator itr;
@@ -131,8 +126,7 @@ UNIT_TEST(Positions)
path.push_back(PointF(80, 40));
path.push_back(PointF(120, 0));
- Spline spl2;
- spl2.FromArray(path);
+ Spline spl2(path);
Spline spl3 = spl2;
itr.Attach(spl3);
TestPointFDir(itr.m_pos, PointF(0, 0));
@@ -156,8 +150,7 @@ UNIT_TEST(BeginAgain)
path.push_back(PointF(40, 40));
path.push_back(PointF(80, 0));
- Spline spl;
- spl.FromArray(path);
+ Spline spl(path);
float const sqrt2 = sqrtf(2.0f);
Spline::iterator itr;
PointF dir1(sqrt2 / 2.0f, sqrt2 / 2.0f);
@@ -178,8 +171,7 @@ UNIT_TEST(BeginAgain)
path.push_back(PointF(80, 40));
path.push_back(PointF(120, 0));
- Spline spl2;
- spl2.FromArray(path);
+ Spline spl2(path);
itr.Attach(spl2);
TEST_EQUAL(itr.BeginAgain(), false, ());
itr.Step(90.0f);