alnickels 0 Posted September 8, 2020 I want to start working with GPS systems. Its a new environment for me and I am running into things some have nothing to do with maps and other issues do. I want to understand rendering maps from provided coordinates onto a VCL form. Do I use a twebbrowser or is there a control that can be provided coordinates that will render the map? Do I have to acquire a mapcontrol from a 3rd party? I want to use google or here for map technology. I noticed that one vendor had a request that included a curl command. What does this curl request return? curl -H "Authorization: Bearer TOKEN_HERE" "https://vector.hereapi.com/v2/vectortiles/base/mc/11/1100/673/omv" Share this post Link to post
Henk Post 3 Posted September 8, 2020 I use ECNativeMap. It is quite cheap and before buying you can ask for a full working trial version. Share this post Link to post
FPiette 383 Posted September 8, 2020 You can use Google maps. There is an API at google to display tracks or symbols above their maps of satellite view. For that, within a Delphi program, you can embed a browser component and write a lot of JavaScript. There are commercial components already made. Among them is one from TMS Software: http://www.tmssoftware.biz/Download/Manuals/TMSFNCMapsDevGuide.pdf But there are alternative. You can also use OpenStreetMap which is an open source map project. Maps are available and as well as documentation to use it. It even exists Delphi source code to handle it. See one by @Fr0sT.Brutal here: https://github.com/Fr0sT-Brutal/Delphi_OSMMap 1 Share this post Link to post
dummzeuch 1505 Posted September 8, 2020 Have you checked the map provider's license terms? Map data is usually not free. OpenStreetMap is free, but there are of course still conditions. If you have an internet connection, you can download our rendered tiles from there. You need to calculate the right coordinates, construct the download URLs, download the tiles and display them. It's not rocket science, but also not as easy as it sounds. We use an internally developed map component, which can display data from various sources (including OpenStreetMap). Developing that definitely wasn't simple. Be prepared to learn a lot about different geographical coordinate systems. Probably more than you ever wanted to know. Also, rendering map data in a way that looks nice is not simple. Our component is still far from looking nice. Using pre-rendered tiles makes that a lot easier. Share this post Link to post
Anders Melander 1784 Posted September 8, 2020 I would be very careful with basing something on Google Maps. They have already deprecated their API several times and it appears that there's currently no official public API. https://stackoverflow.com/questions/44520345/how-do-i-enable-google-maps-tile-api https://stackoverflow.com/questions/58846393/how-to-apply-api-key-to-google-maps-tile-server-url https://supportcenter.devexpress.com/ticket/details/t817015/can-i-use-google-or-naver-maps-from-the-map-control-or-dashboard-map-in-winform https://cloud.google.com/maps-platform/terms/ DevExpress has a map control that supports OpenStreetMap and Bing Maps. OpenStreetMap: http://wiki.openstreetmap.org/wiki/Tile_usage_policy http://wiki.openstreetmap.org/wiki/Legal_FAQ Bing Maps (most of the links you'll find with Google are currently dead for some reason): http://www.mapslicensing.com/ Quote The ExpressMap Control allows you to embed multi-layered maps into your VCL applications (be it raster maps provided by popular web mapping resources, vector maps built with elements stored in map files, or a combination of both), add image and text overlays, and pinpoint specific locations on your map with indicators of your choice. With a comprehensive set of customization options, built-in navigation tools and animation support, the ExpressMap Control helps you create interactive map interfaces with ease.Main features include: Capability to simultaneously display an unlimited number of layers painted with image tiles (Image Tile Layer), vector items (Item Layer), and/or shapes loaded from the Esri shapefiles and KML map files (Item File Layer); Support for the Bing Maps™ and OpenStreetMap online map providers (see the licensing information below); A set of UI elements that allow your end-users to scroll, zoom in and out, and see detailed information about the current view; Smooth scroll and zoom animation; Map element highlighting; Support for skins provided with the ExpressSkins Library. Share this post Link to post
Rollo62 536 Posted September 8, 2020 8 hours ago, alnickels said: Its a new environment for me .... I want to understand rendering maps from provided coordinates onto a VCL form. Do you know that FMX instead of VCL basically has maps for iOS and Android included ? In a new project, maybe FMX makes sense for you too ? Share this post Link to post
Anders Melander 1784 Posted September 8, 2020 5 hours ago, Rollo62 said: Do you know that FMX instead of VCL basically has maps for iOS and Android included ? In a new project, maybe FMX makes sense for you too ? Since he's asking about VCL I think we can assume that it will not be running on iOS or Android. Share this post Link to post
Rollo62 536 Posted September 8, 2020 If its a new project, then its still time to change to FMX. Share this post Link to post
Anders Melander 1784 Posted September 8, 2020 29 minutes ago, Rollo62 said: If its a new project, then its still time to change to FMX. My point was that if we're talking about VCL then the platform must be Windows. If the platform is Windows then the FMX TMapView control can't be used since it only supports iOS and Android. Share this post Link to post
Guest Posted September 8, 2020 47 minutes ago, Anders Melander said: If the platform is Windows then the FMX TMapView control can't be used since it only supports iOS and Android. That's "multi-platform" up front! Share this post Link to post
alnickels 0 Posted September 8, 2020 Can somebody explain curl in the original post please? Share this post Link to post
Anders Melander 1784 Posted September 8, 2020 1 hour ago, alnickels said: Can somebody explain curl in the original post please? Have you read the documentation? https://developer.here.com/documentation/vector-tiles-api/dev_guide/topics/send-request.html or are you asking what curl is? Share this post Link to post
alnickels 0 Posted September 14, 2020 (edited) On 9/8/2020 at 4:59 PM, Anders Melander said: Have you read the documentation? https://developer.here.com/documentation/vector-tiles-api/dev_guide/topics/send-request.html or are you asking what curl is? Anders, Yes I am wanting to take the next step and understand executing the curl request within delphi and taking the next steps. I am sure that I want to use here, but they mention executing thic curl statement and then there is some other operation to take next with the results. Some of the other answers are great pieces to solving this problem, but my next steps will be following the curl part of the next step. Then they follow this with Decode the tile using the related Protobuf schema. I will have to discover what the protobuf schema means. Edited September 14, 2020 by alnickels Share this post Link to post