-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Add TianDiTu(map provider in china) supports #13430
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
add tianditu(map provider in china) supports.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Adds support for the TianDiTu map provider, including token-based configuration and tile URL generation, enabling map usage within China.
- Introduces a new tiandituToken app setting and UI field.
- Adds TianDiTu Road and Satellite providers to the Qt Location plugin.
- Wires provider sources into build and provider list.
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 5 comments.
Show a summary per file
File | Description |
---|---|
src/UI/AppSettings/MapSettings.qml | Adds TianDiTu token input to settings UI and a new property for the token. |
src/Settings/AppSettings.h | Declares tiandituToken as a setting. |
src/Settings/AppSettings.cc | Registers tiandituToken setting. |
src/Settings/App.SettingsGroup.json | Defines tiandituToken metadata. |
src/QtLocationPlugin/QGCMapUrlEngine.cpp | Registers TianDiTu providers in the provider list. |
src/QtLocationPlugin/Providers/TianDiMapProvider.h | Implements TianDiTu provider classes and configuration. |
src/QtLocationPlugin/Providers/TianDiMapProvider.cpp | Implements tile URL generation using the TianDiTu token. |
src/QtLocationPlugin/CMakeLists.txt | Adds TianDiTu provider sources to the plugin build. |
src/QmlControls/OfflineMapEditor.qml | Adds TianDiTu token property to offline map editor. |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
TianDiRoadMapProvider() | ||
: TianDiMapProvider( | ||
QObject::tr("TianDi Road"), | ||
QStringLiteral("cia_w"), |
Copilot
AI
Oct 6, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The map type code for the road map uses 'cia_w', which is the annotations/labels layer in TianDiTu, not the base road tiles. Use 'vec_w' for the street/vector base layer so the Road provider returns actual base map tiles.
QStringLiteral("cia_w"), | |
QStringLiteral("vec_w"), |
Copilot uses AI. Check for mistakes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
according the http://lbs.tianditu.gov.cn/server/MapService.html ,
vec_w
is 矢量底图(Vector base map), there is no streat name in it.
cia_w
is 影像注记(Image annotation), there is streat name in it.
I don't know much about map development, but we want the road with streat name.
example: use cia_w
, and change 'Road' to a more suitable Provider type, is there any suggestion for it?
Co-authored-by: Copilot <[email protected]>
add tianditu(map provider in china) supports.
Description
add tianditu(map provider in china) supports. refer #13429
Test Steps
Web App
.Checklist:
Related Issue
Closes #13429
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.