将Google地图与C ++程序集成 [英] Integrating Google maps with C++ Program
问题描述
我正在用c ++语言制作两点之间基于人工智能的最短距离查找器.我对此的编码是完整的并且可以正常工作.现在,我想将其与Google Maps Api集成.我想在Google地图上以图形方式显示最短距离,该距离与Google地图的显示方向完全相同.我被困住了,找不到任何帮助.我知道我必须为此做套接字编程.请通过正确的步骤和代码段引导我.预先感谢!
I am making an artificial intelligence based shortest distance finder between two points in c++ language. My coding for that is complete and working fine. Now I want to integrate it with Google Maps Api. I want to show the shortest distance graphically on google maps exactly same as google maps show directions. I am stuck and can't find any help. I know I have to do socket programming for this. Please guide me with proper steps and coding snippets. Thanks in advance!
推荐答案
查看官方api: https://cloud.google.com/maps-platform/
要与http api进行交互,您可以使用curl等客户端( http://curl.haxx.se/),或者如果您正在使用boost,还可以使用boost asio.请参阅以下问题:基于Boost.ASIO的HTTP客户端库(例如libcurl)
For interaction with the http api you could use a client such as curl (http://curl.haxx.se/) or maybe boost asio if your are using boost. see this question at SO: Boost.ASIO-based HTTP client library (like libcurl)
这篇关于将Google地图与C ++程序集成的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!