本文整理汇总了C++中GeoPoint::Parametric方法的典型用法代码示例。如果您正苦于以下问题:C++ GeoPoint::Parametric方法的具体用法?C++ GeoPoint::Parametric怎么用?C++ GeoPoint::Parametric使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类GeoPoint
的用法示例。
在下文中一共展示了GeoPoint::Parametric方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: v
void
TrackLineRenderer::DrawProjected(Canvas &canvas,
const WindowProjection &projection,
const NMEAInfo &basic,
const DerivedInfo &calculated,
const MapSettings &settings,
bool wind_relative)
{
// projection.GetMapScale() <= 6000;
GeoPoint traildrift;
if (calculated.wind_available && !wind_relative) {
GeoPoint tp1 = FindLatitudeLongitude(basic.location,
calculated.wind.bearing,
calculated.wind.norm);
traildrift = basic.location - tp1;
} else {
traildrift = GeoPoint(Angle::Zero(), Angle::Zero());
}
auto dt = ARC_SWEEP/ARC_STEPS/
std::max(MIN_RATE,calculated.turn_rate_heading_smoothed.Absolute());
Angle heading = basic.attitude.heading;
GeoPoint loc = basic.location;
RasterPoint pts[ARC_STEPS+1];
pts[0] = projection.GeoToScreen(loc);
int i = 1;
while (i <= ARC_STEPS) {
GeoVector v(basic.true_airspeed*dt, heading);
loc = v.EndPoint(loc.Parametric(traildrift, dt));
pts[i] = projection.GeoToScreen(loc);
heading += calculated.turn_rate_heading_smoothed*dt;
i++;
}
canvas.Select(look.track_line_pen);
canvas.DrawPolyline(pts, i);
}