I write to ask you if did you ever used the new API in GDAL for geocoding.
(Link for description: http://www.gdal.org/ogr/ogr__geocoding_8h.html#a2b0382ceb7e3935d7fe1da2adada564e ).
Do you know what is the method with gdal can associate a location with specific coordinates? I ask you because I don’t understand what does it means : “It runs a geocoding request.If the result is not found in cache, a GET request will be sent to resolve the query”. I found a simple code to require a location coordinates:
/* Create a session with default options */
OGRGeocodingSessionH hSession = OGRGeocodeCreateSession(NULL);
/* Now query the service */
OGRLayerH hLayer = OGRGeocode(hSession, "Paris", NULL, NULL);
/* Use the result layer (the first feature is generally the most relevant) */
/* Cleanup */
OGRGeocodeFreeResult(hLayer);
OGRGeocodeDestroySession(hSession);
Do you confirm this is the code to require a location coordinates?
And if I want to find coordinates of a street adress?