The present technology relates to mapping software and computer-based mapping and, in particular, to application programming interfaces (APIs) for generating maps.
Conventionally, application developers wishing to provide a static bitmap for an application that they are developing must program the application to make a server call to a map server or web site to request generation and delivery of the static bitmap. To make this server call requires that the developer provide a chunk of code for making the call to the correct uniform resource locator (URL) and then for specifying how to interact with the web site in order to obtain the bitmap of the correct location, of the desired size, of the proper zoom level, etc. Further complication arises if the developer wishes to overlay any additional customized data on the bitmap generated by the map server.
A more efficient technique for generating a static bitmap would thus be highly desirable.
Further features and advantages of the present technology will become apparent from the following detailed description, taken in combination with the appended drawings, in which:
It will be noted that throughout the appended drawings, like features are identified by like reference numerals.
In general, the present technology provides an innovative technique for efficiently generating a static bitmap. This enables the application developer to generate a static bitmap without having to initialize the entire mapping system. This is accomplished by providing a specific application programming interface (API) that makes a single, simplified server call to a map server (or map service hosted at a web site). The single, simplified server call specifies the location of the map (e.g. the latitude and longitude of the center of the map, the width of the map, the height of the map, the image format and any customized overlay data). The server call containing this map data request is sent to the map server. The computing device receives the raw map data from the map server and then generates the bitmap locally, using any customized overlay data if requested and available.
The request for customized overlay data may be made to a server clustered with the map server, to a third-party server distinct from the map server, or it may already reside on the computing device. For example, the customized data may also be stored in a local cache or memory on the device.
Thus, an aspect of the present technology is a method, performed on a computing device, of generating a bitmap. The method entails generating a bitmap by transmitting a request for map data from a computing device to a map server, the request comprising a location for a map, a height of the map, a width of the map, and an image format. The method further entails receiving the map data for the map in response to transmitting the request for map data, and generating the bitmap locally on the computing device.
Another aspect of the present technology is a computer readable medium (or machine readable medium) comprising instructions in code which when loaded into memory and executed on a processor of a computing device causes the steps of the foregoing method to be performed.
Yet another aspect of the present technology is a computing device a memory coupled to a processor for executing an application programming interface (API). The device includes a user interface for receiving user input to cause the device to transmit a request for map data to a map server, the request comprising a location for a map, a height of the map, a width of the map, and an image format and receive the map data for the map. The processor and memory generate the bitmap locally on the computing device based on the map data received.
The details and particulars of these aspects of the technology will now be described below, by way of example, with reference to the attached drawings.
In one implementation, the novel method further involves a step 40 of obtaining customized overlay map data. This is done, as shown in
In one implementation, the novel method further involves obtaining the customized overlay map data by first checking a local cache on the computing device for the customized overlay map data (step 10). Where the local cache contains the customized overlay map data, retrieving the customized overlay map data from the cache. Where the local cache does not contain the customized overlay map data, fetching the customized overlay map data from a customized overlay map data server.
The server call is thus one single line of code as opposed to multiple lines of code, which is much simpler and more efficient for the developer. For example, the server call may be in the form: call_map_server[lat, long, width, height, format, customized data].
As shown schematically in
Alternatively, this customized or third-party overlay map data may be preloaded or cached on the device. Overlay map data may be stored permanently in a non-volatile memory such as, for example, ROM, PROM, EPROM, Flash memory. Alternatively, a volatile memory such as, for example, RAM (e.g. DRAM, SRAM) may be used to cache the overlay map data on the device after it is received from an outside source such as the overlay map server 300.
In one specific implementation, the computing device consults its local cache to determine if the map data (“basic map data”) and/or the customized overlay map data is already stored locally.
A settings, preferences or options page or menu may be accessible in the API to configure static map to be generated in a different format (i.e. a format other than a bitmap in the .bmp file format). The static map image may be generated in any number of file formats such as, for example, .png, .gif, .jpg, etc.
In another implementation of this technology, the location parameter that is sent (in the server call) to the map server and/or third-party overlay data server may be based on a variable location such as, for example, a set of location coordinates determined based on the current location of the computing device (e.g. using GPS or any other position-determining subsystem), a set of location coordinates of a mobile device being tracked by the computing device, or a set of location coordinates received in a communication. In other words, the location parameter may optionally be a variable where the variable is determined by the computing device before making the server call.
In another implementation, the height and width parameters may be variables that are determined by another application executing on the computing device. In other words, the size of the bitmap may be determined by another application which may allocate a certain amount of space for the bitmap.
In another implementation, the format may be determined by another application executing on the computing device.
Thus, while the server call may be manually coded with specific parameters to provide a specific bitmap of a specific location having specific height and width, the server call may also be coded with variables that are determined by the computing device.
In another implementation, there may be more than one available map server. As depicted by way of example in
In one particular implementation, the computing device may select one of a plurality of available map servers for obtaining the map data. Selection of the appropriate one of the map servers may be based on any number of criteria or conditions, including time, location, network congestion, etc.
The server call may specify a priority of map servers or may delegate the decision to an algorithm that determines which map server to contact.
The server call may optionally specify whether third-party overlay data is to be obtained in addition to the basic map data.
Third-party overlay data may be requested manually or automatically. If requested manually, the server call is coded with the appropriate information to request specific third-party overlay data from a specific data overlay server. If requested automatically, the computing device may rely on conditions that are predetermined, for example, by the user, system administrator or any other entity. For example, the overlay data may be requested based on time and/or location. In other words, time-based and/or location-based conditions may be used to trigger the request for overlay data. For example, if the computing device is located in a certain location (e.g. a certain neighbourhood, city, province, state, country, area code, etc.) that satisfies a location condition, then the overlay data may be requested. In this example, if the current location does not satisfy the location condition, no request is made.
Alternatively, and still with reference to
Therefore, the decisions whether to request overlay data, from which server to request this overlay data, and which type of overlay data to request can be made intelligently by the computing device based on predetermined conditions (e.g. predetermined time and/or location conditions).
In another implementation, the device may be configured to make a first server call to obtain a first set of third party overlay data from a first overlay data server 430 (for a first type of data) based on certain conditions and/or to make a second server call to obtain a second set of third party overlay data from a second server 432 (for a second, different type of data). For example, the user may wish to have pushpin icons 450 showing the locations of all establishments and retail outlets belonging to Company A on the map (as shown by way of example in
The foregoing examples illustrate that the server call may be dynamically adapted based on various conditions to select map data and overlay data from any one of a plurality of available sources.
The foregoing method steps can be implemented in hardware, software, firmware or as any suitable combination thereof. These method steps may be implemented as software, i.e. as coded instructions stored on a computer readable medium which performs the foregoing steps when the computer readable medium is loaded into memory and executed by the microprocessor of the computing device. A computer-readable medium can be any means that contain, store, communicate, propagate or transport the program for use by or in connection with the instruction execution system, apparatus or device. The computer-readable medium may be electronic, magnetic, optical, electromagnetic, infrared or any semiconductor system or device. For example, computer executable code to perform the methods disclosed herein may be tangibly recorded on a computer-readable medium including, but not limited to, a floppy-disk, a CD-ROM, a DVD, RAM, ROM, EPROM, Flash Memory or any suitable memory card, etc. The method may also be implemented in hardware. A hardware implementation might employ discrete logic circuits having logic gates for implementing logic functions on data signals, an application-specific integrated circuit (ASIC) having appropriate combinational logic gates, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
This new technology has been described in terms of specific implementations and configurations which are intended to be exemplary only. Persons of ordinary skill in the art will appreciate that many obvious variations, refinements and modifications may be made without departing from the inventive concepts presented in this application. The scope of the exclusive right sought by the Applicant(s) is therefore intended to be limited solely by the appended claims.
This application claims priority from U.S. Provisional Patent Application 61/364,617 filed Jul. 15, 2010.
Number | Date | Country | |
---|---|---|---|
61364617 | Jul 2010 | US |