Isis 3 Developer Reference
Target.h
Go to the documentation of this file.
1 #ifndef Target_h
2 #define Target_h
3 
26 #include <QSharedPointer>
27 
28 #include <vector>
29 
30 #include <SpiceUsr.h>
31 #include <SpiceZfc.h>
32 #include <SpiceZmc.h>
33 
34 class QString;
35 
36 namespace Isis {
37  class Angle;
38  class Distance;
39  class Pvl;
40  class PvlGroup;
41  class ShapeModel;
42  class Spice;
43 
76  class Target {
77 
78  public:
79  // constructors
80  Target(Spice *spice, Pvl &label);
81  Target();
82 
84  ~Target();
85 
86  void init();
87  bool isSky() const;
88  SpiceInt naifBodyCode() const;
89  SpiceInt naifPlanetSystemCode() const;
90  QString name() const;
91  QString systemName() const;
92  std::vector<Distance> radii() const;
93  void restoreShape();
94  void setShapeEllipsoid();
95  void setRadii(std::vector<Distance> radii);
96  ShapeModel *shape() const;
97  Spice *spice() const;
98 
99  int frameType();
100 
101  std::vector<Angle> poleRaCoefs();
102  std::vector<Angle> poleDecCoefs();
103  std::vector<Angle> pmCoefs();
104 
105  static SpiceInt lookupNaifBodyCode(QString name);
106  // Static conversion methods
107  static PvlGroup radiiGroup(QString target);
108  static PvlGroup radiiGroup(Pvl &cubeLab, const PvlGroup &mapGroup);
109 
110  std::vector<double> poleRaNutPrecCoefs();
111  std::vector<double> poleDecNutPrecCoefs();
112 
113  std::vector<double> pmNutPrecCoefs();
114 
115  std::vector<Angle> sysNutPrecConstants();
116  std::vector<Angle> sysNutPrecCoefs();
117 
118  private:
119  SpiceInt lookupNaifBodyCode(Pvl &lab) const;
120  static PvlGroup radiiGroup(int bodyFrameCode);
121  SpiceInt *m_bodyCode;
125  SpiceInt *m_systemCode;
127  QString *m_name;
128  QString *m_systemName;
129  std::vector<Distance> m_radii;
130  ShapeModel *m_originalShape;
131  ShapeModel *m_shape;
132  bool m_sky;
133 
134  // TODO should this be an enum(ring, sky, or naifBody), created Naif body for sky, or ???
135  // TODO should the target body kernels go in here too bodyRotation and position??? I don't
136  // think so. They are SPICE kernels and belong in the Spice class (DAC). What do others
137  // think.
138  Spice *m_spice;
140  };
141 
143 }
144 
145 #endif
std::vector< double > pmNutPrecCoefs()
Definition: Target.cpp:557
std::vector< Angle > poleRaCoefs()
Definition: Target.cpp:532
std::vector< double > poleRaNutPrecCoefs()
Definition: Target.cpp:547
static SpiceInt lookupNaifBodyCode(QString name)
This returns the NAIF body code of the target indicated in the labels.
Definition: Target.cpp:234
~Target()
Destroys the Target.
Definition: Target.cpp:152
Spice * spice() const
Return the spice object
Definition: Target.cpp:623
void init()
Initialize member variables.
Definition: Target.cpp:142
bool isSky() const
Return if our target is the sky.
Definition: Target.cpp:180
std::vector< double > poleDecNutPrecCoefs()
Definition: Target.cpp:552
QString systemName() const
Return planet system name.
Definition: Target.cpp:512
void restoreShape()
Restores the shape to the original after setShapeEllipsoid has overridden it.
Definition: Target.cpp:575
Target()
Constructs an empty Target object.
Definition: Target.cpp:124
SpiceInt naifPlanetSystemCode() const
This returns the NAIF planet system body code of the target.
Definition: Target.cpp:500
Contains multiple PvlContainers.
Definition: PvlGroup.h:57
SpiceInt naifBodyCode() const
This returns the NAIF body code of the target.
Definition: Target.cpp:487
static PvlGroup radiiGroup(QString target)
Creates a Pvl Group with keywords TargetName, EquitorialRadius, and PolarRadius.
Definition: Target.cpp:393
QString name() const
Return target name.
Definition: Target.cpp:506
ShapeModel * shape() const
Return the shape.
Definition: Target.cpp:615
std::vector< Angle > sysNutPrecCoefs()
Definition: Target.cpp:567
Container for cube-like labels.
Definition: Pvl.h:135
std::vector< Angle > sysNutPrecConstants()
Definition: Target.cpp:562
This class is used to create and store valid Isis3 targets.
Definition: Target.h:76
Define shapes and provide utilities for Isis3 targets.
Definition: ShapeModel.h:78
int frameType()
Definition: Target.cpp:527
void setShapeEllipsoid()
Set the shape to the ellipsoid and save the original shape.
Definition: Target.cpp:593
Namespace for ISIS/Bullet specific routines.
Definition: Apollo.h:31
Obtain SPICE information for a spacecraft.
Definition: Spice.h:294
std::vector< Angle > pmCoefs()
Definition: Target.cpp:542
void setRadii(std::vector< Distance > radii)
Sets the radii of the body.
Definition: Target.cpp:605
QSharedPointer< Target > TargetQsp
Definition: Target.h:142
std::vector< Angle > poleDecCoefs()
Definition: Target.cpp:537
std::vector< Distance > radii() const
Returns the radii of the body in km.
Definition: Target.cpp:522