Constellation.cpp   Constellation.cpp 
skipping to change at line 29 skipping to change at line 29
#include <algorithm> #include <algorithm>
#include <QString> #include <QString>
#include <QTextStream> #include <QTextStream>
#include <QDebug> #include <QDebug>
#include <QFontMetrics> #include <QFontMetrics>
#include "StelProjector.hpp" #include "StelProjector.hpp"
#include "Constellation.hpp" #include "Constellation.hpp"
#include "StarMgr.hpp" #include "StarMgr.hpp"
#include "StelNavigator.hpp"
#include "StelTexture.hpp" #include "StelTexture.hpp"
#include "StelPainter.hpp" #include "StelPainter.hpp"
#include "StelApp.hpp" #include "StelApp.hpp"
#include "StelCore.hpp" #include "StelCore.hpp"
Vec3f Constellation::lineColor = Vec3f(0.4,0.4,0.8); Vec3f Constellation::lineColor = Vec3f(0.4,0.4,0.8);
Vec3f Constellation::labelColor = Vec3f(0.4,0.4,0.8); Vec3f Constellation::labelColor = Vec3f(0.4,0.4,0.8);
Vec3f Constellation::boundaryColor = Vec3f(0.8,0.3,0.3); Vec3f Constellation::boundaryColor = Vec3f(0.8,0.3,0.3);
bool Constellation::singleSelected = false; bool Constellation::singleSelected = false;
skipping to change at line 91 skipping to change at line 91
qWarning() << "Error in Constellation " << abbreviat ion << " asterism : can't find star HP= " << HP; qWarning() << "Error in Constellation " << abbreviat ion << " asterism : can't find star HP= " << HP;
// TODO: why is this delete commented? // TODO: why is this delete commented?
// delete[] asterism; // delete[] asterism;
return false; return false;
} }
} }
XYZname.set(0.,0.,0.); XYZname.set(0.,0.,0.);
for(unsigned int ii=0;ii<numberOfSegments*2;++ii) for(unsigned int ii=0;ii<numberOfSegments*2;++ii)
{ {
XYZname+= asterism[ii]->getJ2000EquatorialPos(StelApp::getIn stance().getCore()->getNavigator()); XYZname+= asterism[ii]->getJ2000EquatorialPos(StelApp::getIn stance().getCore());
} }
XYZname.normalize(); XYZname.normalize();
return true; return true;
} }
void Constellation::drawOptim(StelPainter& sPainter, const StelNavigator* n av, const SphericalCap& viewportHalfspace) const void Constellation::drawOptim(StelPainter& sPainter, const StelCore* core, const SphericalCap& viewportHalfspace) const
{ {
if (lineFader.getInterstate()<=0.0001f) if (lineFader.getInterstate()<=0.0001f)
return; return;
sPainter.setColor(lineColor[0], lineColor[1], lineColor[2], lineFade r.getInterstate()); sPainter.setColor(lineColor[0], lineColor[1], lineColor[2], lineFade r.getInterstate());
Vec3d star1; Vec3d star1;
Vec3d star2; Vec3d star2;
for (unsigned int i=0;i<numberOfSegments;++i) for (unsigned int i=0;i<numberOfSegments;++i)
{ {
star1=asterism[2*i]->getJ2000EquatorialPos(nav); star1=asterism[2*i]->getJ2000EquatorialPos(core);
star2=asterism[2*i+1]->getJ2000EquatorialPos(nav); star2=asterism[2*i+1]->getJ2000EquatorialPos(core);
star1.normalize(); star1.normalize();
star2.normalize(); star2.normalize();
sPainter.drawGreatCircleArc(star1, star2, &viewportHalfspace ); sPainter.drawGreatCircleArc(star1, star2, &viewportHalfspace );
} }
} }
void Constellation::drawName(StelPainter& sPainter) const void Constellation::drawName(StelPainter& sPainter) const
{ {
if (!nameFader.getInterstate()) if (!nameFader.getInterstate())
return; return;
 End of changes. 4 change blocks. 
5 lines changed or deleted 5 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/