30 std::numeric_limits<double>::quiet_NaN(),
31 std::numeric_limits<double>::quiet_NaN(),
34 std::vector<std::string> geo_ref_splitted;
37 for (
auto element: geo_ref_splitted) {
38 std::vector<std::string> geo_ref_key_value;
40 if (geo_ref_key_value.size() != 2u) {
44 if (geo_ref_key_value[0] ==
"+lat_0") {
45 result.latitude =
ParseDouble(geo_ref_key_value[1]);
46 }
else if (geo_ref_key_value[0] ==
"+lon_0") {
47 result.longitude =
ParseDouble(geo_ref_key_value[1]);
51 if (std::isnan(result.latitude) || std::isnan(result.longitude)) {
52 log_warning(
"cannot parse georeference: '" + geo_reference_string +
"'. Using default values.");
53 result.latitude = 42.0;
54 result.longitude = 2.0;
57 log_debug(
"map geo reference: latitude ", result.latitude,
", longitude ", result.longitude);