I have a set of Latlng coordinates that I want to place on a Google Map, but instead of the usual markers, I want to create an overlay where a higher density of these latlng points will create a redder color overlay, while a lower density will give a greener overlay, everywhere in between will be a shade in between red and green. How can I achieve this?
You could try to build heat map with data stored in Google Fusion Tables.
Also, have a look at this question from GIS SE:
How could I turn my data into a heatmap / intensity map?
Related
Is it possible to draw a custom text overlay on a google map via a kml file. I'm drawing several polygons (e.g. linear ring) that separate a region into districts and I want to indicate what district the polygon is and without an marker pin.
KML does not have a native way to draw text or fonts directly on the map.
Your options include:
Add a Point/Placemark with a Label at the center of your polygon. In the IconStyle, set scale to zero, so that you only see the label.
Use a GroundOverlay image that contains the text and has a transparent background
Find a way to generate KML lines or polygons in the shape of your letters/text, and place those on the map.
I have a database with various map locations (latitude, longitude).
I've been using a map api (e.g. google maps) to plot these locations.
I am now experimenting to see if I can totally remove dependency of map apis and simply replace the map control with an image (an .png image).
Question:
How can I translate the map locations to be displayed properly onto this map image?
More details:
Basically, the map will be a rectangular area (i.e. Div element), where the top-left corner of the rectangle is obviously (0, 0). So basically the map locations will be displayed with respect to this top-left corner.
First off, where are you getting your geocodes from? If they are from Bing or Google Maps then you can only use those coordinates with those map controls. Using this coordinates without the map controls is against the terms of use of these API's. Assuming that these coordinates come from somewhere else you can overlay them on an image by first knowing some information about the image. At a minimium you will need to know two coordinates on the image and their relative pixel locations. From that you can then determine the scale and top left coordinate of the image. With this you can then fairly accurately position coordinates on the image using a lot of math. You can find a lot of useful math for this here: http://msdn.microsoft.com/en-us/library/bb259689.aspx I've writing a few blog posts on this a while back which you can find here: http://rbrundritt.wordpress.com/2008/10/25/ve-imagery-service-and-custom-icons/
If these coordinates come from Bing Maps you can easily display them on a map image using the Bing Maps Imagery Service: http://msdn.microsoft.com/en-us/library/ff701724.aspx
I have a list of markers that I want to create a polygon around (showing the area around the markers and not the markers themselves). So instead of having the poly points be the direct lat/long of the markers, I want the poly to "wrap" around the markers to show the relative area around them.
Any ideas on how I could accomplish something like this?
This is called a convex hull. There's an example at http://www.geocodezip.com/v3_map-markers_ConvexHull.asp which uses the algorithm described at http://softsurfer.com/Archive/algorithm_0203/algorithm_0203.htm
Is it possible to make Panoramio Pictures and WeatherLayer icons appear above (have a higher zIndex than) a polygon?
I have a map with transparent Polygon Overlays, and when I add the Panoramio or WeatherLayers to the map, the Panoramio photos and weather icons appear below the polygon overlays.
The pictures and weather icons can be seen below the polygon because the polygon is partially transparent, but the user cannot interact with those photos or icons because the polygon is on top of them.
The screen shot below shows an example of this:
You can view an example page here.
You can add and remove the different overlays/layers. I've tried setting the zIndex of the polygon to negative numbers, but they always appear above the Panoramio and WeatherLayer icons.
The PanoramioLayer and PanoramioLayerOptions API references don't say anything about a zIndex. The same goes for the WeatherLayer and WeatherLayerOptions API references.
You're need to set option to the polygon:
clickable: false
But all polygon's mouse events won't work
I would like to create polygon which shape are area that input by user. For example, user input Chicago. Then map will show polygon like below image :
I cant show image because i dont have enough reputation
Is anybody know how to do it? I don't know to get latitude and longitude of edge the area that needed to draw polygon?
Thanks