Google Maps: Draw polygon surrounding random locations - google-maps

I have a set of random locations. The location set will keep changing. I would like to draw a polygon surrounding these locations.
Can this be done in Google Maps and how? The map will be displayed on a website only, no mobile api required.

It's called a convex hull. Here:
http://www.geocodezip.com/v3_map-markers_convexhull.asp
I would cite the code but it belongs to #geocodezip who is the authority on google maps and runs an excellent site of examples. I suggest you check it out.

Related

Google Maps API V3 - Highlight a single road/street

Is there a way to highlight a specified road or street using Google Maps API V3?
Here is an example of what I am trying to get (image from searching a place in google): example
Styled maps does not do what I want since it will apply to all roads. Polylines is an option but finding the coordinates can be a bit of a pain since they are not always complete.
Thanks.
It has already been discussed and I'm afraid you'll have to use polylines.
This might be useful though : Highlighting whole street with some maps API

How to retrieve a static map showing city or municipality boundaries

I'm not sure where to start looking in the documentation, but I'm trying to load map images of cities with their boundaries outlined.
Like this...
Any help getting started would be greatly appreciated, I'm pretty new to the maps api.
Thanks
There is currently no way to request a map with boundaries automatically rendered on it. Your best bet is to pull the polygon information from another system and render using an encoded polyline if you're using the Static Map API or regular overlays in the JavaScript API.
Google Static Map API
Here it is
here, some links to help you:
Geographical boundaries of states/provinces -> Google Maps Polygon
EInsert extension
Boundary Draw - Google Map Application
Getting neighbourhood boundaries from Google Maps API
https://stackoverflow.com/questions/8441467/can-you-draw-custom-search-boundaries-in-google-map
Ability to draw boundaries on Google Maps

Is google maps api the right tool for the job? For something like wikimapia

This is how last part of my application(php/mysql website) is supposed to work:
BackEnd for the Admin : a standard zoomable (google?) map of a city on which polygons(or circles) representing colonies can be drawn using a pen tool .(like wikimapia)
Database: the location and shape of the drawn city block is stored.
UI for the user: the user can see the standard zoomable google map along with the drawn colonies in his browser. He can then select a colony, enter a radius and gets a list of all colonies lying within the circle.
Is google maps api and javascript right tools for the job ? If so how difficult does this sound ? if not , then what else? pure javascript combined with static google maps api ?
Any other suggestions ?
I am a beginner-intermediate php programmer at best, know a little of a few languages (C#).
Thanks
Why wouldn't it? Yes, I think google maps is right tool for the job. I've seen similar things done in google maps API:
http://www.wikiloc.org/ (drawing polylines)
http://telmee.nl/ (drawing polygons and polylines)

Search a google map I have created and embedded into my website

I have a Google map I have created to highlight the location of several support groups by adding my own pins using my maps and embedding this into my website.
Is there a Google widget of any description to allows people to search my custom map and find their nearest support group (or nearest pin).
I have read through the Google maps stuff but cant seem to find anything that meets my requirements.
Any help appreciated.
The map has no clue about which markers or overlays you have put on it. Therefore there are no way you can do what you want using Google Maps directly. You can however do something else.
When you create your markers/overlays and place them on the map you can add them to an array. When you users then enters a location you can search through that array to find the markers that are closest to the location the user has entered. Google Maps API has a method for getting the distance between two latlngs, but you can also use an ordinary Haversine formula for calculating it.
Once you have found the closest markers it is not hard making sure they are the only ones that are shown on the map.

Google Maps - Online Map Marker to mark polygons and shapes onto the map

I'm looking looking for a tool that will allow me to make a map exactly like this:
http://datasearch.uts.edu.au/about/mapsdirections/map.cfm
Basically I need to put shapes around buildings in the satellite view and then slap a marker and information window on them so that I can specify the building name and contents.
So the main issue is that I need the ability to draw shapes directly onto the maps as I don't fancy taking down the lat lng of each corner of the polygon.
Ideally what I'd like to do is have an online application that exports those points to KML, and then I would display google maps on my site and import that kml to display it.
Other suggestions welcome!
Jason
Found a polygon creator
http://www.the-di-lab.com/polygon/
It's simple to use and allows you to copy and paste straight into your code. Would be nice if it had a button that said sent to kml though..