QGroundControl
Ground Control Station for MAVLink Drones
Loading...
Searching...
No Matches
FlyViewGeoMap.qml
Go to the documentation of this file.
1/****************************************************************************
2 *
3 * (c) 2009-2024 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
4 *
5 * QGroundControl is licensed according to the terms in the file
6 * COPYING.md in the root of the source code directory.
7 *
8 ****************************************************************************/
9
10import QtPositioning
11
12import QGroundControl
13import QGroundControl.GeoMap
14
15/// Fly-view 2D/3D map: the GeoMap-engine counterpart of FlyViewMap.
16/// Fly-view specific map content (vehicle items, trajectory, ...) lands here.
17GeoMap {
18 id: root
19
20 allowGCSLocationCenter: true
21 allowVehicleLocationCenter: true
22 keepVehicleCentered: QGroundControl.settingsManager.flyViewSettings.keepMapCenteredOnVehicle.rawValue
23
24 readonly property var _activeVehicle: QGroundControl.multiVehicleManager.activeVehicle
25
26 // Vehicle home (launch) location
27 GeoMapPin {
28 scene: root.scene
29 surfaceModel: root.surfaceModel
30 coordinate: root._activeVehicle ? root._activeVehicle.homePosition : QtPositioning.coordinate()
31 visible: root._activeVehicle && root._activeVehicle.homePosition.isValid
32 label: qsTr("L")
33 }
34
35 Repeater {
36 model: QGroundControl.multiVehicleManager.vehicles
37
38 GeoMapVehicleItem {
39 scene: root.scene
40 surfaceModel: root.surfaceModel
41 vehicle: object
42 }
43 }
44
45 GeoMapFlightPath {
46 scene: root.scene
47 surfaceModel: root.surfaceModel
48 vehicle: root._activeVehicle
49 }
50}