iobject.net 进行飞行管理时沿直线飞行时没问题,有多个站点的折线时,在没有到达中间端点前就已经改变了方向,没有沿线飞行。如何设置可以一直沿线飞行,到达端点后才改变方向
好的,主要代码如下,我在最后有加入了update
GeoLine3D geoLine3D = new GeoLine3D(point3Ds); route = new Route(); route.FromGeoLine3D(geoLine3D); route.IsFlyAlongTheRoute = true; int routestopCount = route.Stops.Count; for (int i = 0; i < routestopCount; i++) { stop = route.Stops[i]; stop.TurnTime = 0.1; stop.IsSlowTurning = false; } route.IsTiltFixed = true; route.IsHeadingFixed = true; route.IsAltitudeFixed = true; route.Speed = m_flySpeed; route.IsLinesVisible = true; route.IsStopsVisible = true; m_CurFlyManager.Routes.Add(route); m_CurFlyManager.PlayRate = 5; m_CurFlyManager.Scene = m_sceneControl.Scene; m_CurFlyManager.Update();