本文整理汇总了C++中Polyline::setLongitude方法的典型用法代码示例。如果您正苦于以下问题:C++ Polyline::setLongitude方法的具体用法?C++ Polyline::setLongitude怎么用?C++ Polyline::setLongitude使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Polyline
的用法示例。
在下文中一共展示了Polyline::setLongitude方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: if
//.........这里部分代码省略.........
0.665407, -0.818123, -10, 0.693768, -0.763582, 0.857393, -0.730857, -10, 0.861756, -0.805033, 0.831213, -0.87921, 1.0472, -0.885755, 1.0712,
-0.944659, 1.2021, -0.966476, 1.34172, -0.951204, 1.39626, -0.885755, 1.53589, -0.857393, 1.71042, -0.872665, 1.72569, -0.909753, 1.91986,
-0.859575, 2.03767, -0.870483, 2.08131, -0.872665, 2.09658, -0.922843, 2.19693, -0.925025, 2.23184, -0.86612, 2.34747, -0.842121, 2.32129,
-0.785398, 2.28638, -0.783217, 2.27984, -0.73522, 2.16857, -0.698132, -10, 1.88277, -0.375246, 1.8435, -0.407971, 1.77587, -0.370882,
1.73006, -0.386154, 1.72569, -0.423242, 1.7017, -0.418879, 1.72569, -0.477784, 1.69515, -0.475602, -10, 1.59916, -0.488692, 1.55116,
-0.490874, -10, 1.54025, -0.488692, 1.41154, -0.530144, -10, 1.35918, -0.61741, 1.28064, -0.687223, 1.40499, -0.737402, 1.39626, -0.785398,
1.4399, -0.78758, 1.44644, -0.824668, 1.49662, -0.822486, 1.50753, -0.857393, 1.53589, -0.857393, 1.5817, -0.789761, 1.67988, -0.746128,
1.8326, -0.724312, 1.95477, -0.7614, 1.95695, -0.785398, 2.09221, -0.815941, 2.02022, -0.833395, 2.03767, -0.870483, -20
};
Polyline *l = 0;
int start = 0;
for (int i = 0; lines[i] > -19.999; ++i)
{
if (lines[i] < -9.999 && lines[i] > -10.001)
{
if (l != 0)
{
_polylines.push_back(l);
}
int points = 0;
for (int j = i + 1; lines[j] > -9.999; ++j)
{
points++;
}
points /= 2;
l = new Polyline(points);
start = i + 1;
}
else
{
if ((i - start) % 2 == 0)
{
l->setLongitude((i - start) / 2, lines[i]);
}
else
{
l->setLatitude((i - start) / 2, lines[i]);
}
}
}
_polylines.push_back(l);
if (!Options::getBool("mute"))
{
// Load musics
std::string mus[] = {"GMDEFEND",
"GMENBASE",
"GMGEO1",
"GMGEO2",
"GMGEO3",
"GMGEO4",
"GMINTER",
"GMINTRO1",
"GMINTRO2",
"GMINTRO3",
"GMLOSE",
"GMMARS",
"GMNEWMAR",
"GMSTORY",
"GMTACTIC",
"GMTACTIC2",
"GMWIN"
};
std::string exts[] = {"flac", "ogg", "mp3", "mod"};
int tracks[] = {3, 6, 0, 18, -1, -1, 2, 19, 20, 21, 10, 9, 8, 12, 17, -1, 11};