--debugMsg;
This commit is contained in:
parent
cf279e320b
commit
e0b6ee9d5d
1 changed files with 11 additions and 6 deletions
|
@ -219,18 +219,23 @@ void FGATCManager::update ( double time ) {
|
||||||
double speed = fgGetDouble("/velocities/groundspeed-kt");
|
double speed = fgGetDouble("/velocities/groundspeed-kt");
|
||||||
double altitude = fgGetDouble("/position/altitude-ft");
|
double altitude = fgGetDouble("/position/altitude-ft");
|
||||||
|
|
||||||
|
/*
|
||||||
SGGeod me(SGGeod::fromDegM(longitude,
|
SGGeod me(SGGeod::fromDegM(longitude,
|
||||||
latitude,
|
latitude,
|
||||||
altitude));
|
altitude));
|
||||||
SGGeod wpt(SGGeod::fromDegM(fp->getWayPoint(1)->getLongitude(),
|
SGGeod wpt1(SGGeod::fromDegM(fp->getWayPoint(1)->getLongitude(),
|
||||||
fp->getWayPoint(1)->getLatitude(),
|
fp->getWayPoint(1)->getLatitude(),
|
||||||
fp->getWayPoint(1)->getAltitude()));
|
fp->getWayPoint(1)->getAltitude()));
|
||||||
|
SGGeod wpt2(SGGeod::fromDegM(fp->getWayPoint(1)->getLongitude(),
|
||||||
|
fp->getWayPoint(1)->getLatitude(),
|
||||||
|
fp->getWayPoint(1)->getAltitude()));
|
||||||
|
|
||||||
|
double course1, az1, dist1;
|
||||||
|
double course2, az2, dist2;
|
||||||
|
SGGeodesy::inverse(me, wpt1, course1, az1, dist1);
|
||||||
|
|
||||||
double course, az2, dist;
|
cerr << "Bearing to nearest waypoint : " << course1 << " " << dist1 << ". (course " << course2 << ")." << endl;
|
||||||
SGGeodesy::inverse(me, wpt, course, az2, dist);
|
*/
|
||||||
|
|
||||||
cerr << "Bearing to nearest waypoint : " << course << endl;
|
|
||||||
|
|
||||||
ai_ac.setLatitude(latitude);
|
ai_ac.setLatitude(latitude);
|
||||||
ai_ac.setLongitude(longitude);
|
ai_ac.setLongitude(longitude);
|
||||||
ai_ac.setAltitude(altitude);
|
ai_ac.setAltitude(altitude);
|
||||||
|
|
Loading…
Add table
Reference in a new issue