Marble

GeoDataCamera.h
1// SPDX-License-Identifier: LGPL-2.1-or-later
2//
3// SPDX-FileCopyrightText: 2013 Mayank Madan <maddiemadan@gmail.com>
4//
5
6#ifndef MARBLE_GEODATACAMERA_H
7#define MARBLE_GEODATACAMERA_H
8
9#include "geodata_export.h"
10#include "GeoDataAbstractView.h"
11#include "GeoDataCoordinates.h"
12
13namespace Marble
14{
15class GeoDataCameraPrivate;
16
17/**
18 */
19class GEODATA_EXPORT GeoDataCamera : public GeoDataAbstractView
20{
21public:
22 GeoDataCamera();
23
24 GeoDataCamera(const GeoDataCamera& other);
25
26 GeoDataCamera& operator=(const GeoDataCamera &other);
27 bool operator==( const GeoDataCamera &other ) const;
28 bool operator!=( const GeoDataCamera &other ) const;
29
30 ~GeoDataCamera() override;
31
32 GeoDataAbstractView *copy() const override;
33
34 /**
35 * @brief set the altitude in a GeoDataCamera object
36 * @param altitude latitude
37 *
38 */
39 void setAltitude( qreal altitude);
40
41 /**
42 * @brief retrieves the altitude of the GeoDataCamera object
43 * @return latitude
44 */
45 qreal altitude( ) const;
46
47 /**
48 * @brief set the latitude in a GeoDataCamera object
49 * @param latitude latitude
50 * @param unit units that lon and lat get measured in
51 * (default for Radian: north pole at pi/2, southpole at -pi/2)
52 */
53 void setLatitude( qreal latitude,GeoDataCoordinates::Unit unit = GeoDataCoordinates::Radian );
54
55 /**
56 * @brief retrieves the latitude of the GeoDataCamera object
57 * use the unit parameter to switch between Radian and DMS
58 * @param unit units that lon and lat get measured in
59 * (default for Radian: north pole at pi/2, southpole at -pi/2)
60 * @return latitude
61 */
62 qreal latitude( GeoDataCoordinates::Unit unit = GeoDataCoordinates::Radian ) const;
63
64 /**
65 * @brief set the longitude in a GeoDataCamera object
66 * @param longitude longitude
67 * @param unit units that lon and lat get measured in
68 * (default for Radian: north pole at pi/2, southpole at -pi/2)
69 */
70 void setLongitude( qreal longitude,GeoDataCoordinates::Unit unit = GeoDataCoordinates::Radian );
71
72 /**
73 * @brief retrieves the longitude of the GeoDataCamera object
74 * use the unit parameter to switch between Radian and DMS
75 * @param unit units that lon and lat get measured in
76 * (default for Radian: north pole at pi/2, southpole at -pi/2)
77 * @return latitude
78 */
79 qreal longitude( GeoDataCoordinates::Unit unit = GeoDataCoordinates::Radian ) const;
80
81 /**
82 * @brief retrieve the lat/lon/alt triple as a GeoDataCoordinates object
83 * @return GeoDataCoordinates
84 * @see longitude latitude altitude
85 */
86 GeoDataCoordinates coordinates() const;
87
88 void setRoll( qreal roll );
89
90 qreal roll() const;
91
92 qreal heading() const;
93
94 void setHeading(qreal heading);
95
96 qreal tilt() const;
97
98 void setTilt(qreal tilt);
99
100 void setCoordinates( const GeoDataCoordinates& coordinates );
101
102 /// Provides type information for downcasting a GeoNode
103 const char* nodeType() const override;
104
105 void detach();
106private:
107 GeoDataCameraPrivate *d;
108
109};
110
111}
112
113Q_DECLARE_METATYPE( Marble::GeoDataCamera )
114
115#endif
QAction * roll(const QObject *recvr, const char *slot, QObject *parent)
QAction * copy(const QObject *recvr, const char *slot, QObject *parent)
Binds a QML item to a specific geodetic location in screen coordinates.
bool operator==(const QGraphicsApiFilter &reference, const QGraphicsApiFilter &sample)
bool operator!=(const QGraphicsApiFilter &reference, const QGraphicsApiFilter &sample)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Jun 14 2024 11:54:16 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.