1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133 | /* ============================================================
*
* This file is a part of digiKam project
* https://www.digikam.org
*
* Date : 2023-05-15
* Description : geolocation engine based on Marble.
* (c) 2007-2022 Marble Team
* https://invent.kde.org/education/marble/-/raw/master/data/credits_authors.html
*
* SPDX-FileCopyrightText: 2023-2024 by Gilles Caulier <caulier dot gilles at gmail dot com>
*
* SPDX-License-Identifier: LGPL-2.1-or-later
*
* ============================================================ */
#pragma once
// Local includes
#include "GeoDataAbstractView.h"
#include "GeoDataCoordinates.h"
#include "digikam_export.h"
namespace Marble
{
class GeoDataLookAtPrivate;
/**
*/
class DIGIKAM_EXPORT GeoDataLookAt : public GeoDataAbstractView
{
public:
GeoDataLookAt();
GeoDataLookAt(const GeoDataLookAt& other);
GeoDataLookAt& operator=(const GeoDataLookAt& other);
bool operator==(const GeoDataLookAt& other) const;
bool operator!=(const GeoDataLookAt& other) const;
~GeoDataLookAt() override;
GeoDataAbstractView* copy() const override;
/**
* @brief set the altitude in a GeoDataLookAt object
* @param altitude latitude
*
*/
void setAltitude(qreal altitude);
/**
* @brief retrieves the altitude of the GeoDataLookAt object
* @return latitude
*/
qreal altitude() const;
/**
* @brief set the latitude in a GeoDataLookAt object
* @param latitude latitude
* @param unit units that lon and lat get measured in
* (default for Radian: north pole at pi/2, southpole at -pi/2)
*/
void setLatitude(qreal latitude, GeoDataCoordinates::Unit unit = GeoDataCoordinates::Radian);
/**
* @brief retrieves the latitude of the GeoDataLookAt object
* use the unit parameter to switch between Radian and DMS
* @param unit units that lon and lat get measured in
* (default for Radian: north pole at pi/2, southpole at -pi/2)
* @return latitude
*/
qreal latitude(GeoDataCoordinates::Unit unit = GeoDataCoordinates::Radian) const;
/**
* @brief set the longitude in a GeoDataLookAt object
* @param longitude longitude
* @param unit units that lon and lat get measured in
* (default for Radian: north pole at pi/2, southpole at -pi/2)
*/
void setLongitude(qreal longitude, GeoDataCoordinates::Unit unit = GeoDataCoordinates::Radian);
/**
* @brief retrieves the longitude of the GeoDataLookAt object
* use the unit parameter to switch between Radian and DMS
* @param unit units that lon and lat get measured in
* (default for Radian: north pole at pi/2, southpole at -pi/2)
* @return latitude
*/
qreal longitude(GeoDataCoordinates::Unit unit = GeoDataCoordinates::Radian) const;
/**
* @brief retrieve the lat/lon/alt triple as a GeoDataCoordinates object
* @return GeoDataCoordinates
* @see longitude latitude altitude
*/
GeoDataCoordinates coordinates() const;<--- Derived function 'GeoDataLookAt::coordinates'<--- Derived function 'GeoDataLookAt::coordinates'
/**
* @brief Change the distance (in meters) between the camera and the object looked at
* @see range
*/
void setRange(qreal range);
/**
* @brief Retrieve the distance (in meters) between the camera and the object looked at
* @see setRange
*/
qreal range() const;
/**
* @brief set the GeoDataCoordinates object
* @param coordinates GeoDataCoordinates
* @see GeoDataCoordinates
*/
void setCoordinates(const GeoDataCoordinates& coordinates);
/// Provides type information for downcasting a GeoNode
const char* nodeType() const override;
void detach();
private:
GeoDataLookAtPrivate* d = nullptr;
};
} // namespace Marble
Q_DECLARE_METATYPE(Marble::GeoDataLookAt)
|