OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
ossimTieGptSet.h
Go to the documentation of this file.
1 #ifndef ossimTieGptSet_HEADER
2 #define ossimTieGptSet_HEADER
3 
4 #include <iostream>
5 #include <vector>
9 #include <ossim/matrix/newmat.h>
10 
11 class ossimDpt;
12 
28 {
29 public:
30 
31  inline ossimTieGptSet() {}
32 
33  inline ossimTieGptSet(const ossimTieGptSet& aSet)
34  :
35  theTies(aSet.getTiePoints()),
36  theMasterPath(aSet.getMasterPath()),
37  theSlavePath(aSet.getSlavePath()),
38  theImageCov(aSet.getImageCov()),
39  theGroundCov(aSet.getGroundCov())
40  {}
41 
42  inline ~ossimTieGptSet() {}
43 
44  const ossimTieGptSet& operator=(const ossimTieGptSet&);
45 
46  // accessors
47  inline void setTiePoints(const vector<ossimRefPtr<ossimTieGpt> >& aTieSet) { theTies = aTieSet; }
48  inline const vector<ossimRefPtr<ossimTieGpt> >& getTiePoints()const { return theTies; }
49  inline vector<ossimRefPtr<ossimTieGpt> >& refTiePoints() { return theTies; }
50 
51  inline void setMasterPath(const ossimString& aPath) { theMasterPath = aPath; }
52  inline const ossimString& getMasterPath()const { return theMasterPath; }
53 
54  inline void setSlavePath(const ossimString& aPath) { theSlavePath = aPath; }
55  inline const ossimString& getSlavePath()const { return theSlavePath; }
56 
57  inline void setImageCov(const NEWMAT::SymmetricMatrix& aCovMat) { theImageCov = aCovMat; }
58  inline const NEWMAT::SymmetricMatrix& getImageCov()const { return theImageCov; }
59  inline NEWMAT::SymmetricMatrix& refImageCov() { return theImageCov; }
60 
61  inline void setGroundCov(const NEWMAT::SymmetricMatrix& aCovMat) { theGroundCov = aCovMat; }
62  inline const NEWMAT::SymmetricMatrix& getGroundCov()const { return theGroundCov; }
63  inline NEWMAT::SymmetricMatrix& refGroundCov() { return theGroundCov; }
64 
65  void getSlaveMasterPoints(std::vector<ossimDpt>& imv, std::vector<ossimGpt>& gdv)const;
66 
67  inline unsigned int size()const { return (unsigned int)theTies.size(); }
68 
72  void addTiePoint(ossimRefPtr<ossimTieGpt> aTiePt);
73  void clearTiePoints();
74 
75  void getGroundBoundaries(ossimGpt& gBoundInf, ossimGpt& gBoundSup)const;
76 
80  std::ostream& printTab(std::ostream& os) const;
81 
85  ossimRefPtr<ossimXmlNode> exportAsGmlNode(ossimString aGmlVersion="2.1.2")const;
86  bool importFromGmlNode(ossimRefPtr<ossimXmlNode> aGmlNode, ossimString aGmlVersion="2.1.2");
87 
91  static const char* TIEPTSET_TAG;
92 
93 protected:
97  std::vector<ossimRefPtr<ossimTieGpt> > theTies; //store by reference so derived classes can be used
100  NEWMAT::SymmetricMatrix theImageCov;
101  NEWMAT::SymmetricMatrix theGroundCov;
102 
106  ossimString symMatrixToText(const NEWMAT::SymmetricMatrix& sym,
107  const ossimString& el_sep=" ",
108  const ossimString& row_sep=";")const;
109 
110  NEWMAT::SymmetricMatrix textToSymMatrix(const ossimString& text,
111  unsigned int dim,
112  const ossimString& seps=" ;\t\r\n")const; //list of possible elements or row separators
113 
114 };
115 
116 #endif /* #ifndef ossimTieGptSet_HEADER */
unsigned int size() const
#define OSSIMDLLEXPORT
static const char * TIEPTSET_TAG
Public data members.
NEWMAT::SymmetricMatrix & refImageCov()
NEWMAT::SymmetricMatrix & refGroundCov()
ossimString theMasterPath
NEWMAT::SymmetricMatrix theGroundCov
image error covariance matrix
std::vector< ossimRefPtr< ossimTieGpt > > theTies
Protected data members.
void setMasterPath(const ossimString &aPath)
vector< ossimRefPtr< ossimTieGpt > > & refTiePoints()
ossimString theSlavePath
full or relative path to master dataset
ossimTieGptSet(const ossimTieGptSet &aSet)
const vector< ossimRefPtr< ossimTieGpt > > & getTiePoints() const
const NEWMAT::SymmetricMatrix & getGroundCov() const
storage class for a set of geographic tie points, between master and slave images ...
void setSlavePath(const ossimString &aPath)
const NEWMAT::SymmetricMatrix & getImageCov() const
void setTiePoints(const vector< ossimRefPtr< ossimTieGpt > > &aTieSet)
const ossimString & getSlavePath() const
const ossimString & getMasterPath() const
NEWMAT::SymmetricMatrix theImageCov
full or relative path to slave dataset
void setGroundCov(const NEWMAT::SymmetricMatrix &aCovMat)
std::basic_ostream< char > ostream
Base class for char output streams.
Definition: ossimIosFwd.h:23
void setImageCov(const NEWMAT::SymmetricMatrix &aCovMat)