map.h File Reference

This file includes functions related with map generation. More...

#include <stdbool.h>
#include "platform.h"
Include dependency graph for map.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Enumerations

enum  ast_map_service_t {
  AST_MAP_NIL, AST_MAP_GOOGLE, AST_MAP_OSM, AST_MAP_AMAP,
  AST_MAP_BAIDU
}
 Map service. More...
 

Functions

const char * ast_map_get_service_name (const ast_map_service_t service)
 Get name of of online map service. More...
 
bool ast_map_get_link_url (char *url, const size_t url_size, const ast_map_service_t service, const double latitude, const double longitude)
 Get link URL of online map service. More...
 

Detailed Description

This file includes functions related with map generation.

Enumeration Type Documentation

◆ ast_map_service_t

Map service.

Enumerator
AST_MAP_NIL 
AST_MAP_GOOGLE 
AST_MAP_OSM 
AST_MAP_AMAP 
AST_MAP_BAIDU 

Function Documentation

◆ ast_map_get_link_url()

bool ast_map_get_link_url ( char *  url,
const size_t  url_size,
const ast_map_service_t  service,
const double  latitude,
const double  longitude 
)

Get link URL of online map service.

Parameters
urlBuffer to save return url
url_sizeUrl buffer size
serviceMap service
latitudeLatitude of map center
longitudeLongitude of map center
Returns
If map url is successfully built.

If return true, the url shall be filled with URL of the map service like http://maps.google.com/.

◆ ast_map_get_service_name()

const char* ast_map_get_service_name ( const ast_map_service_t  service)

Get name of of online map service.

Parameters
serviceMap service