Projection.h
1 /*
2 
3 MIT License
4 
5 Copyright (c) 2017 FMI Open Development / Markus Peura, first.last@fmi.fi
6 
7 Permission is hereby granted, free of charge, to any person obtaining a copy
8 of this software and associated documentation files (the "Software"), to deal
9 in the Software without restriction, including without limitation the rights
10 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 copies of the Software, and to permit persons to whom the Software is
12 furnished to do so, subject to the following conditions:
13 
14 The above copyright notice and this permission notice shall be included in all
15 copies or substantial portions of the Software.
16 
17 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23 SOFTWARE.
24 
25 */
26 /*
27 Part of Rack development has been done in the BALTRAD projects part-financed
28 by the European Union (European Regional Development Fund and European
29 Neighbourhood Partnership Instrument, Baltic Sea Region Programme 2007-2013)
30 */
31 #ifndef DRAIN_Projection_H_
32 #define DRAIN_Projection_H_
33 
34 
35 #include <string>
36 #include <iostream>
37 #include <stdexcept>
38 
39 
40 // // using namespace std;
41 
42 
43 namespace drain
44 {
45 
51 {
52 public:
53 
54  Projection();
55 
56  Projection(const Projection &p);
57 
58  virtual ~Projection();
59 
60 
62  virtual virtual
63  void projectFwd(double & x, double & y) const {};
64 
66  virtual virtual
67  void projectFwd(const double & x, const double & y, double & x2, double & y2) const {};
68 
70  virtual virtual
71  void projectFwd(double & x, double & y, double & z) const {};
72 
73 
75  virtual inline
76  void projectInv(double & x, double & y) const {};
77 
78 
80  virtual inline
81  void projectInv(const double & x2, const double & y2, double & x, double & y) const {};
82 
84  virtual inline
85  void projectInv(double & x, double & y, double & z) const {};
86 
87 
88 
90 
92  // const std::string & getProjectionSrc() const {};
93 
94  /*
95  inline
96  std::string getErrorString() const {
97  //projErrorStr = pj_strerrno(*pj_get_errno_ref());
98  return std::string(pj_strerrno(*pj_get_errno_ref()));
99  };
100  */
101 
102 
103 };
104 
105 // std::ostream & operator<<(std::ostream & ostr, const Projection &p);
106 
107 }
108 
109 #endif /*Projection_H_*/
110 
111 // Drain
Definition: Projection.h:51
virtual void projectInv(double &x, double &y) const
Inverse projection.
Definition: Projection.h:76
virtual void projectInv(double &x, double &y, double &z) const
Inverse projection.
Definition: Projection.h:85
virtual virtual void projectFwd(double &x, double &y) const
Forward projection.
Definition: Projection.h:63
virtual virtual void projectFwd(double &x, double &y, double &z) const
Forward projection.
Definition: Projection.h:71
virtual void projectInv(const double &x2, const double &y2, double &x, double &y) const
Inverse projection from (x2,y2) to (x,y).
Definition: Projection.h:81
virtual virtual void projectFwd(const double &x, const double &y, double &x2, double &y2) const
Forward projection.
Definition: Projection.h:67
Definition: DataSelector.cpp:1277