从QGC中剥离出来的locationPlugin
Map {
id:map
anchors.fill: parent
plugin: Plugin {
name: "QGroundControl" // 使用 OpenStreetMap 插件
PluginParameter {
name: "TiandiTuKey"
value: "************************************************"
}
PluginParameter {
name: "tmsUrl"
value: "file:///E:/out/tms.xml"
}
}
// 设置初始中心点
center: QtPositioning.coordinate(38.045474, 114.502461) // 石家庄
zoomLevel: 8
activeMapType:supportedMapTypes[39];
Component.onCompleted: {
console.log("Supported map types:")
for (var i = 0; i < supportedMapTypes.length; ++i) {
var t = supportedMapTypes[i]
console.log(
i,
t.name,
t.description,
t.style
)
}
}
}Warning
使用此代码务必遵循以下许可
QGroundControl is licensed under a dual-license system to allow maximum flexibility for users and contributors.
QGroundControl is available under both the Apache License 2.0 and the GNU General Public License v3 (GPL v3). You may choose which license you want to use based on your use case.
The Apache 2.0 License is a permissive license which allows QGroundControl to be built and used in any environment, including proprietary > applications. It allows QGroundControl to be built for mobile app stores.
Note: When building with Apache 2.0, a commercial Qt license is required.
Full License: See LICENSE-APACHE in the root directory.
The GPL v3 License is a strong copyleft license. When building QGroundControl under this license, the open source version of Qt can be used.
Our licensing grants the permission to use a later version of the license; however, contributions must be made under GPL v3.
Full License: See LICENSE-GPL in the root directory.
Contributions must be made under QGroundControl's dual-license system (both GPL v3 AND Apache 2.0). This by definition rules out the re-use of any copyleft (e.g., GPL-only) licensed code.
All contributions must be:
- Original work, OR
- From a compatible license: BSD 2-clause, BSD 3-clause, MIT, or Apache 2.0
For contribution guidelines, see CONTRIBUTING.md.
If you have questions regarding the licensing, please contact the maintainer:
- Lorenz Meier: lm@qgroundcontrol.org
Quick Summary:
- Use GPL v3 if you want to use the open-source Qt version (copyleft)
- Use Apache 2.0 if you need to use QGroundControl in proprietary applications (requires commercial Qt license)
- Contributing requires code compatible with BOTH licenses