Satellite.cpp   Satellite.cpp 
skipping to change at line 388 skipping to change at line 388
tleElements.second.append(tle2); tleElements.second.append(tle2);
pSatWrapper = new gSatWrapper(id, tle1, tle2); pSatWrapper = new gSatWrapper(id, tle1, tle2);
orbitPoints.clear(); orbitPoints.clear();
} }
void Satellite::update(double) void Satellite::update(double)
{ {
if (pSatWrapper && orbitValid) if (pSatWrapper && orbitValid)
{ {
epochTime = StelApp::getInstance().getCore()->getJDay(); StelCore* core = StelApp::getInstance().getCore();
double JD = core->getJDay();
epochTime = JD - core->getDeltaT(JD)/86400; // Delta T anti-
correction for artificial satellites
pSatWrapper->setEpoch(epochTime); pSatWrapper->setEpoch(epochTime);
position = pSatWrapper->getTEMEPos(); position = pSatWrapper->getTEMEPos();
velocity = pSatWrapper->getTEMEVel(); velocity = pSatWrapper->getTEMEVel();
latLongSubPointPosition = pSatWrapper->getSubPoint(); latLongSubPointPosition = pSatWrapper->getSubPoint();
height = latLongSubPointPosition[2]; height = latLongSubPointPosition[2];
if (height <= 0.0) if (height <= 0.0)
{ {
// The orbit is no longer valid. Causes include ver y out of date // The orbit is no longer valid. Causes include ver y out of date
// TLE, system date and time out of a reasonable ran ge, and orbital // TLE, system date and time out of a reasonable ran ge, and orbital
 End of changes. 1 change blocks. 
1 lines changed or deleted 4 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/