I am Developing Android application in which i need to show available destinations to the user in Google Maps and provide route optimization with near and far destinations.
And Also set priorities to each and every destination LIKE eg:(1,5,3,2,4,6,7) etc.
Please can anyone help me on this topic.
I think this tutorial can help you with your problem. It uses a Google Maps JavaScript Direction Service. What you need is to create a structure request object and pass it into to a Direction Service Object and wait for Google's servers to respond via your callback function. After checking that the directions are "OK", you can iterate through the results object or pass it to a DirectionsRenderer Object provided by the Google API.
This tutorial gives you a sample code that will serve as a guide for you. For more information, you can also check this related SO question:
Using Google Maps 3 API to get multiple routes on a Map
Google maps API - adding multiple destinations
Related
I want to use only place autocomplete for lat/long data.
But cannot understand this paragraph from "license agreement" disallow me to use it?
present or alert an end user to individual maneuvers of a route in any
way that is synchronized with the end-user’s sensor-based position
along the route, (e.g. “real-time” navigation);
I want to build the route with help of Bing Maps (Autocomplete API for addressees) and then trigger the GPS navigation without any use of Bing Maps's data.
That line is simply saying that you're not allowed to use their data to create your own turn-by-turn navigation app. It doesn't sound like you're doing that, so it's probably fine.
Using Bing maps controls or services to build an application that provides turn-by-turn guidance directly to the user in that application is prohibited by the terms of use.
If you are using Bing maps services to determine the lat/long of a destination and then handing that position off to some other application (like the built-in maps app) to do the turn-by-turn guidance, that would be permitted.
I have collected data of specific restricted zones in Google Maps. Now I want that when a user opens my app for getting directions for a Point B from Point A, he should be shown an alternative direction which does not include the restricted zones which I have mentioned.
How should I proceed?
What steps should I follow such that those restricted zones get ignored while showing alternative directions from Point A to Point B?
To get alternative direction, you can use the Google Maps Direction API which is a service that calculates directions between locations using an HTTP request.
You can use the optional parameters alternative to provide one or more alternative route.
alternatives — If set to true, specifies that the Directions service may provide more than one route alternative in the response. Note that providing route alternatives may increase the response time from the server.
I have done some research and i found that adding multiple destination is possible through google map website and one can send the entire navigation plan to google map android app it works perfect.
But in my case i want to generate multiple destination navigation url dynamically through my app and pass it via intent to open google map app in phone.
How can this be achieved any ideas would be helpfull .
You may generate multiple destination by requesting 'https://maps.googleapis.com/maps/api/directions/json?'. However, you are limited up to 8 waypoints. To get more waypoints for a request, you'll need to get Google Maps API for Work which will allow you up to 23 waypoints.
Regarding Google Maps Intents, in order to launch Maps with an intent, you must first create an Intent object specifying its action, URI and package. For more details, check this link: https://developers.google.com/maps/documentation/android-api/intents
I've read Google's API policy on Location Services & Maps API, they do not allow one to make an app that provides directions to a user's location. I however wish to make such an app. I know I need to use a third party Maps API, but im unsure if this sort of app would be allowed on the play store.
I've searched extensively. The only references to this not being allowed in the the Maps API terms of service, but no where else. +
The idea is simple, one person sends a request to another, and they track each other with directions provided to find them.
Revalent reddit post by myself.
http://www.reddit.com/r/androiddev/comments/2qcm22/would_i_get_in_trouble_w_googles_policys_if_i/
I do not understand that it is difficult , you can use Google maps , first try to get another exact coordinates of latitude and longitude , and put them on a Google map , then make getting location via satellite.
I am trying to launch the google maps app from my iOS/Android app in respective mobiles.
URLs to launch the app : comgooglemaps://?q=lat+long
But I need to know if I can pass multiple location coordinates so that multiple pins would appear in the google maps app after launching.
I can find URL scheme for directions and single location to launch the app, multiple locations for static map . But I couldn't find any references in the web for URL schemes to have multiple location coordinates.
Can anyone please help me ?
As per documentation here there is no parameter for that. Also the maps-URL does not have a parameter for that as you can see here. Maybe an embedded map can be a solution for you as the static maps API has a parameter for this here.