I'm interested in adding a Google Maps feature to a program I'm writing. I would start with a historic GPS log file containing a record of my changing GPS location and date/time - for example as I drive along the road. Later on I would like to feed this log file into a windows program which would display the GPS position as a marker in the center of a Google Map that is displayed in a window on screen. The Google Map would be automatically scrolled horizontally or vertically in historic "real time" as the GPS position changed so that the marker always stays in the center of the map.
Below is a YouTube video of an existing program which already does exactly what I want, so it must be possible (it's the pane in the bottom right of the video frame)
http://www.youtube.com/watch?feature=player_embedded&v=r4rwMV7hhaY#at=840
Effectively the user would be playing-back their recorded movements in real-time from days or months ago. It would not be for tracking current movements.
I don't know much about the Google API yet, but I think that the Google maps would have to be running in a desktop program, and not on a web site.
Are there any pre-built modules which already do this (perhaps just feeding it a list of coordinates and times)?
If not, what API would I need to use to reproduce the map behavior shown in the video?
Also are there any licensing issues with doing this in a desktop program which would only be seen by 1 user rather than on a publicly available web site?
I have used the Google Maps API for creating an embedded GPS window like the one you referenced in your link, but basically it was embedding a browser window and linking it up to Google Maps. You can manage the data yourself and pump it over to the browser. This can be done locally.
You'll need to do a few things.
Define the map scripts (with an html/Javascript file). These scripts will allow you to update the location you are displaying on the map which you will hook into code side to control.
In your GUI define a browser object and set it to navigate to the html file you've made and then use the document portion of that object to invoke scripts.
You should be able to control the GPS location once you've done that. The Google Maps API is referenced in your html file. That html file is key, it will need to have all the functions you want to use to update the GPS location and display it on the map.
As per pre-built modules an/or licensing I do not know.
Related
I'm trying to create a link in a web page that permit to open google maps and/or google earth loading the kml file specified.
I see here geouri method but don't seems working anymore with kml file
I also saw for example this:
https://earth.google.com/web/?kml=https://tourbuilder.withgoogle.com/tours/ahJzfmd3ZWItdG91cmJ1aWxkZXJyEQsSBFRvdXIYgICg6vjqywkM/earth
but this method seems working only with specific sites like tourbuilder, and for what I need, kml generated dynamically from the web pages, possibly updated over time and numerous kml (almost 200) would take a long time to create a "tour" for each (if that is possible) and would restrict the possible changes to the web page and to kml.
Can someone tell me if there is another way to create a link in a web page that permit to open google maps and/or google earth loading the kml file specified please?
Maps.google.com used to support loading public KMLs via the search bar or via a URL parameter, but not anymore. To load a KML in Google Maps, you need a web site (can be very simple) that uses the Maps API and loads a KML Layer. Sounds like not your use-case, but if it was a simple KML that wouldn't be changing often, you could consider uploading it to a MyMap and sharing that.
Google Earth for web & mobile (as opposed to the Earth Pro desktop application) does not currently support loading arbitrary KMLs via URL either, except for certain KML sources (as you saw with tourbuilder).
I need to generate a GIS map showing some points and polygons. This map generation process has to run in the background so that every day at a certain time of the day a map is made and stored at a certain location in the file system.
I don't think leaflet can be used for this as it runs on the browser.
Not sure how will this happen in QGIS also....any light in this direction will be helpful.
My requirement is to generate a HTML report which contains a map. I cannot do it on the browser because the user will not use the browser and want the report to be inn his mailbox every day automatically.
I will be using node js to generate HTML.
How can this be achieved? Please save my life.
Thanks
I suggest you use something like phantom.js to perform what is essentially a screen capture of the map you generate in a web page that is 'displayed' on a headless, off-screen web page. What sort of map server you use to generate the maps is up to you; but that would let you capture a browser view of the map and re-package it in a PDF or an image that is embedded in an email.
Make that PDF or image a GeoPDF or a GeoTIFF or example and the result would retain some geospatial aspects instead of being a dumb screen capture.
I would use something capable of delivering a map tiling service (like wms) which you can then query server-side and piece together the tiles. I've had good luck with geoserver (http://geoserver.org/) but there are other solutions as well. I'm not sure if you can can query Google maps api or Open Street Map like this. The nice thing about your own map server is that you can completely define the map you want on it in one place. Aside from this, I would browse the npm repository to see if anyone has tackled this problem before.
I have been behind the 8-ball all quarter for my class some how I am supposed to be able to do this in 4 hours.
My Assignment
The purpose of this assignment is to utilize a map to display a route using overlays/polylines.
The goal of this assignment is to enhance the assignment from week 5 (web service to retrieve directions) to display the retrieved directions as a route on a map in addition to a list of steps.
You are required to write a single application that runs on a tablet configuration (Nexus 10 or some variation of a 10 inch screen tablet)
User Interface Requirements
The left side of the screen (ListView, left-pane) will contain the interface outlined in the week 5 assignment. A user can enter a source and destination and retrieve a list of directions based on that input. So, the interface is a couple textfields, a button, and a list.
The right side of the screen (right-pane, details view) will contain a Map that displays the directions as a segmented line (route). The map and route gets updated/displayed after the directions are retrieved (selection of the button). An initial map should be displayed with some default settings when the screen is first loaded.
Other Requirements
The Map should display the entire route (start and end point) at the appropriate zoom level (depending on the distance). The correct map type should also be used depending on the distance.
You are required to use a Marker to display the starting point and ending destination.
You are required to use the MapFragment class.
You are required to use API V2 from Google Maps and the Google Play Services API.
You are required to use the XMLPullParser class for parsing the XML.
This application will look very similar to the Google maps application that is used on the web (with a lot less detail, no zooming in out of the map, etc), concerning the route displayed, and left pane to enter source / destination and direction list.
Using Android Studio I have tried Creating an Application using the Map Activity, but it creates and application that will not compile and it looks like it wants me to use Google Keys. I can't hand in an assignment that requires Keys assigned to me.
I already have 4 hours into this and I can't even get started. I read that v3 of googles map API's doesn't need keys, but I can't find anything that tells me how to use them and Android Studio Doesn't seem to give you options as to what to download and use.
I really need help.
Im working on a project to create a google map of an internal floorplan of my company's buildings. I dont want to use google's new indoor maps features as we dont want the floorplans available to the public. I was wanting to create an entirely custom map and just use the google maps engine and strip away the traditional world map tileset. Is this possible and how would I go about do it? Currently our floorplans are in an image file so a way to import those easily would be ideal.
I faced this problem creating an app last summer. It does not look like Google Maps (at least at that time) allowed for custom map tiles. I ended up implementing my own Map function, however I used XML files to create colored maps. The functionality would be the same if you wanted to use images, however.
The only drawback is that the features do not have such things that are built in with Google Maps, like dropped pins, etc. due to the fact that it is a custom built module. The repo is on GitHub here: https://github.com/krmannix/SmartMart
The Android Activity that holds the map is located within SmartMart/SmartMart/src/com/example/searchcell3/MapListActivity.java
I am developing GPS based Location reminder in j2me. I am little bit confuse to which maps i use??.....Google maps & Nokia maps. Which one allows me good working... The working of my app are as follows :-
-User will provide a string to app to search a place of his/her desire.
-Then according to given string app will show a place on map by pointing marker on map.
-User can save that place or he/she can select a near by place rather than searched place by clicking on map or any other way.
-app will save that searched place coordinates & remind when it reached to near that place.
-When app remind to user about already stored place... that place should show on map by pointing an marker along with the how far he is from his destination.
The real choice here lies in whether to use a RESTful API like the Google Static Maps (or Nokia's RESTful Maps) or to use a native Java ME mapping library plugin such as the Nokia Maps API for Java ME. The latter has several major advantages:
Static mapping services such as the Google Static Maps API or Nokia's
RESTful Map API do not cache or tile the images when requested,
therefore each request involves a round trip to the server. If the
map on a mobile application needs to be refreshed at any time, using
a caching library will result in a reduction in network traffic after
around three maps have been displayed. An explanation of this can be
found here
As the name implies, Google's Static Maps API can only retrieve over
http static images for a requested coordinate point, image size,
image type and zoom level. Newer libraries offer additional
functionality out of the box offering dynamic Map content and touch
support, where the user can move around his/her current position,
zoom in, zoom out, modify the view mode to satellite or translate an
address to a coordinate point and show that on the map, among others.
This abstraction of the underlying functionality is hidden from the
developer so much less coding is needed in order to achieve the same
result .
Terms and Conditions for Nokia Maps are easier to fulfil than
Google - No legal restrictions of using the API outside a web browser
application or need to provide a link to the native Google Maps App
(if there is one), or to Google Maps (if there isn't one).
Nokia currently offer higher free daily request limits. Nokia Maps
API for Java ME supports up to 50,000 render requests per day and per
unique IP address (as of January 2012), for Nokia Developer
registered users (free of charge) while the limit for Google's Static
Maps API is currently 1000 unique (different) image requests per
viewer per day.
A couple of years ago there wouldn't be a choice, only RESTful solutions existed, but these days I would say a static http solution should only be used if you want a simple single image
As an abstraction of the underlying services, there are already a full set of examples to cover most of your use cases:
-User will provide a string to app to search a place of his/her desire.
-Then according to given string app will show a place on map by pointing marker on map.
http://www.developer.nokia.com/Commu...PI_for_Java_ME
-User can save that place or he/she can select a near by place rather than searched place by clicking on map or any other way.
Maybe you need to use a draggable marker:
http://www.developer.nokia.com/Devel...ples/#standard
Or react to the touch and find a Geocoordinate:
http://www.developer.nokia.com/Commu...PI_for_Java_ME
-app will save that searched place coordinates & remind when it reached to near that place.
This is known as geofencing and is covered by the Location API:
- http://www.developer.nokia.com/Resou...ty-events.html
-When app remind to user about already stored place... that place should show on map by pointing an marker along with the how far he is
from his destination.
Showing a Map with a Marker
http://www.developer.nokia.com/Devel...ples/#standard
For distance calculations, I guess you'd be after the ROUTING example
http://www.developer.nokia.com/Devel...mples/#routing
http://www.developer.nokia.com/Commu...g_with_Java_ME
Now you could re-write and all these services from scratch using RESTful APIs (and then go about debugging your code) , but I'm sure you'll agree it would be much easier to use an existing, working and tested framework for the low level plumbing and then just write your code on top using the services.
It is possible to encapsulate RESTful service in Java ME. As an example, added below is a screenshot from an app encapsulating the suggestion service
It is just a lot easier when someone else has already done this work for you and placed it in a library.