changed attributes of header files
[platform/core/location/maps-plugin-here.git] / inc / engine / maps / GeoProjection.h
1 /*
2  * Copyright (C) 2013 HERE Global B.V. All rights reserved.
3  * This software, including documentation, is protected by copyright controlled by
4  * HERE Global B.V. (“Software”). All rights are reserved. Copying, including reproducing,
5  * storing, adapting or translating, any or all of this material requires the prior
6  * written consent of HERE Global B.V. You may use this
7  * Software in accordance with the terms and conditions defined in the
8  * HERE Location Platform Services Terms and Conditions, available at
9  * http://developer.here.com/terms-conditions-base
10  *
11  * As an additional permission to the above, you may distribute Software,
12  * in object code format as part of an Application, according to, and subject to, terms and
13  * conditions defined in the Tizen Software Development kit (“SDK”) License Agreement.
14  * You may distribute such object code format Application under terms of your choice,
15  * provided that the header and source files of the Software have not been modified.
16  */
17
18 #ifndef GEOPROJECTION_H
19 #define GEOPROJECTION_H
20
21 #include <vector>
22
23 #include "common/HereMaps_global.h"
24
25 #ifdef TIZEN_MIGRATION
26 #include "graphic/DoubleMatrix4.h"
27 #include "graphic/Dimension.h"
28 #include "graphic/Point.h"
29 #else
30 #include <FGraphics.h>
31 #include <FBaseDoubleMatrix4.h>
32 #endif
33
34 HERE_MAPS_BEGIN_NAMESPACE
35
36 class DoublePoint;
37 class DoublePoint3;
38 class GeoCoordinates;
39 class GeoProjectionNode;
40
41 class GeoProjection
42 {
43 public:
44     GeoProjection();
45     virtual ~GeoProjection();
46
47     virtual Tizen::Maps::Point geoToPixel(const GeoCoordinates& geo) const = 0;
48     virtual GeoCoordinates pixelToGeo(const Tizen::Maps::Point& pixel) const = 0;
49
50     virtual std::vector<GeoProjectionNode*> projectRoot();
51     virtual GeoProjectionNode* projectQuad(GeoProjectionNode* parent, int quad);
52
53     virtual void setTileSize(const Tizen::Maps::Dimension& size);
54     Tizen::Maps::Dimension tileSize() const;
55
56     virtual void setScreenSize(const Tizen::Maps::Dimension& size);
57     Tizen::Maps::Dimension screenSize() const;
58
59     virtual void setLevel(double value);
60     double level() const;
61
62     virtual void setMaximumLevel(double value);
63     double maximumLevel() const;
64
65     virtual void setMinimumLevel(double value);
66     double minimumLevel() const;
67
68     virtual void setHeading(double value);
69     double heading() const;
70
71     virtual void setGeoCenter(const GeoCoordinates& value);
72     GeoCoordinates geoCenter() const;
73
74     virtual bool setGeoCenterInPx(const Tizen::Maps::Point& value);
75     Tizen::Maps::Point screenCenter() const;
76
77     DoublePoint projectPoint(const DoublePoint& point) const;
78
79 protected:
80     virtual void filter(GeoProjectionNode& transform,const std::vector<DoublePoint3>& points) = 0;
81     virtual DoublePoint3 projectPoint(double x, double y, double z=0) const = 0;
82
83     Tizen::Maps::DoubleMatrix4& GetMatrix();
84     const Tizen::Maps::DoubleMatrix4& GetMatrix() const;
85     Tizen::Maps::DoubleMatrix4& GetInverse();
86     const Tizen::Maps::DoubleMatrix4& GetInverse() const;
87
88     Tizen::Maps::Dimension& GetTileSize();
89     Tizen::Maps::Dimension& GetScreenSize();
90     GeoCoordinates& GetGeoCenter();
91     double& GetLevel();
92 #ifdef TIZEN_MIGRATION
93 public:
94     double getScale();
95     void setScale(double scale);
96 #endif
97     double& GetHeading();
98
99 private:
100     HERE_MAPS_NO_COPY_NO_ASSIGN(GeoProjection);
101     friend class TestGeoProjection;
102
103     class GeoProjectionImpl;
104     GeoProjectionImpl* m_pImpl;
105 };
106
107 HERE_MAPS_END_NAMESPACE
108
109 #endif // GEOPROJECTION_P_H