Google Static Maps Problem

classic Classic list List threaded Threaded
28 messages Options
12
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Google Static Maps Problem

Richmond Mathewson via use-livecode
Folks:
I’ve found a way to display an image of a google static map, in my app. It’s quite easy and well-documented. However, I need to get the lat and lon values of the corners of the map, at the displayed zoom level. There is a simple-looking javascript example for doing this at:
https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map <https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map>
My javascript knowledge is totally minimal and I am loath to learn javascript just to get this one handler into livecode script.

What I have is an application that plots geophysical data on a world map. The map kind of ugly at very high magnifications and I thought the google map would give me a nice map image, with a wider range of magnifications, and minimize local storage space. What I will do is display the map image (centered on a particular lat/lon and magnification) in a rectangle, then take a snapshot, then copy my data symbols and images into the resulting snapshot. This works very will with my current map. I know that I can draw symbols directly on a google map using the map api, but it will be much more direct, and build on existing code, if I do it as described.

So if anyone who is familiar with javascript has a few moments to give me some pointers on how I might convert this to LCS, I’d very much appreciate it. What I’m scratching my head over is how to access the parameters from the Google API to do the needed calculations. The link above is to the javascript example.

Thanks in advance,
Bill P

William A. Prothero
http://earthlearningsolution.org/

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Hi Bill,

Can you share the LC code and JS you are using?

Sent from my iPhone

> On Jun 29, 2017, at 9:59 PM, William Prothero via use-livecode <[hidden email]> wrote:
>
> Folks:
> I’ve found a way to display an image of a google static map, in my app. It’s quite easy and well-documented. However, I need to get the lat and lon values of the corners of the map, at the displayed zoom level. There is a simple-looking javascript example for doing this at:
> https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map <https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map>
> My javascript knowledge is totally minimal and I am loath to learn javascript just to get this one handler into livecode script.
>
> What I have is an application that plots geophysical data on a world map. The map kind of ugly at very high magnifications and I thought the google map would give me a nice map image, with a wider range of magnifications, and minimize local storage space. What I will do is display the map image (centered on a particular lat/lon and magnification) in a rectangle, then take a snapshot, then copy my data symbols and images into the resulting snapshot. This works very will with my current map. I know that I can draw symbols directly on a google map using the map api, but it will be much more direct, and build on existing code, if I do it as described.
>
> So if anyone who is familiar with javascript has a few moments to give me some pointers on how I might convert this to LCS, I’d very much appreciate it. What I’m scratching my head over is how to access the parameters from the Google API to do the needed calculations. The link above is to the javascript example.
>
> Thanks in advance,
> Bill P
>
> William A. Prothero
> http://earthlearningsolution.org/
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Jonathan:
Here is a link to my test stack and some files I found that have various code to find the corners of the downloaded map.
https://www.dropbox.com/s/8xle2hrltx9ll0d/googleMapsAPiTests.zip?dl=0 <https://www.dropbox.com/s/8xle2hrltx9ll0d/googleMapsAPiTests.zip?dl=0>
My start on a conversion is in the script of the “Get Corners” button. I can get an xml file from the regular maps api, but the “bounds” property doesn’t change with zoom, which makes it not obvious how to convert that to what is being displayed, to get the corners. I have no problem converting pixels to mercator lat/lon, but until I can figure out the relationship between pixels and zoom levels, I’m stuck.

Thanks for any help. I know your augmented Earth application uses these maps too, and I’m also willing to share code when I get this working.

Bill P

> On Jun 30, 2017, at 3:50 AM, Jonathan Lynch via use-livecode <[hidden email]> wrote:
>
> Hi Bill,
>
> Can you share the LC code and JS you are using?
>
> Sent from my iPhone
>
>> On Jun 29, 2017, at 9:59 PM, William Prothero via use-livecode <[hidden email]> wrote:
>>
>> Folks:
>> I’ve found a way to display an image of a google static map, in my app. It’s quite easy and well-documented. However, I need to get the lat and lon values of the corners of the map, at the displayed zoom level. There is a simple-looking javascript example for doing this at:
>> https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map <https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map>
>> My javascript knowledge is totally minimal and I am loath to learn javascript just to get this one handler into livecode script.
>>
>> What I have is an application that plots geophysical data on a world map. The map kind of ugly at very high magnifications and I thought the google map would give me a nice map image, with a wider range of magnifications, and minimize local storage space. What I will do is display the map image (centered on a particular lat/lon and magnification) in a rectangle, then take a snapshot, then copy my data symbols and images into the resulting snapshot. This works very will with my current map. I know that I can draw symbols directly on a google map using the map api, but it will be much more direct, and build on existing code, if I do it as described.
>>
>> So if anyone who is familiar with javascript has a few moments to give me some pointers on how I might convert this to LCS, I’d very much appreciate it. What I’m scratching my head over is how to access the parameters from the Google API to do the needed calculations. The link above is to the javascript example.
>>
>> Thanks in advance,
>> Bill P
>>
>> William A. Prothero
>> http://earthlearningsolution.org/
>>
>> _______________________________________________
>> use-livecode mailing list
>> [hidden email]
>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
The google maps API has a function for getting the bounds of a map, which adjusts at each level.

So, this is just a matter of calling on that function every time, so you get current bounds.

I will look at the stack later today.

Just be careful with bounds. They can cause confusion with changes in the orientation of the map.

Sent from my iPhone

> On Jun 30, 2017, at 10:10 AM, William Prothero via use-livecode <[hidden email]> wrote:
>
> Jonathan:
> Here is a link to my test stack and some files I found that have various code to find the corners of the downloaded map.
> https://www.dropbox.com/s/8xle2hrltx9ll0d/googleMapsAPiTests.zip?dl=0 <https://www.dropbox.com/s/8xle2hrltx9ll0d/googleMapsAPiTests.zip?dl=0>
> My start on a conversion is in the script of the “Get Corners” button. I can get an xml file from the regular maps api, but the “bounds” property doesn’t change with zoom, which makes it not obvious how to convert that to what is being displayed, to get the corners. I have no problem converting pixels to mercator lat/lon, but until I can figure out the relationship between pixels and zoom levels, I’m stuck.
>
> Thanks for any help. I know your augmented Earth application uses these maps too, and I’m also willing to share code when I get this working.
>
> Bill P
>
>> On Jun 30, 2017, at 3:50 AM, Jonathan Lynch via use-livecode <[hidden email]> wrote:
>>
>> Hi Bill,
>>
>> Can you share the LC code and JS you are using?
>>
>> Sent from my iPhone
>>
>>> On Jun 29, 2017, at 9:59 PM, William Prothero via use-livecode <[hidden email]> wrote:
>>>
>>> Folks:
>>> I’ve found a way to display an image of a google static map, in my app. It’s quite easy and well-documented. However, I need to get the lat and lon values of the corners of the map, at the displayed zoom level. There is a simple-looking javascript example for doing this at:
>>> https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map <https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map>
>>> My javascript knowledge is totally minimal and I am loath to learn javascript just to get this one handler into livecode script.
>>>
>>> What I have is an application that plots geophysical data on a world map. The map kind of ugly at very high magnifications and I thought the google map would give me a nice map image, with a wider range of magnifications, and minimize local storage space. What I will do is display the map image (centered on a particular lat/lon and magnification) in a rectangle, then take a snapshot, then copy my data symbols and images into the resulting snapshot. This works very will with my current map. I know that I can draw symbols directly on a google map using the map api, but it will be much more direct, and build on existing code, if I do it as described.
>>>
>>> So if anyone who is familiar with javascript has a few moments to give me some pointers on how I might convert this to LCS, I’d very much appreciate it. What I’m scratching my head over is how to access the parameters from the Google API to do the needed calculations. The link above is to the javascript example.
>>>
>>> Thanks in advance,
>>> Bill P
>>>
>>> William A. Prothero
>>> http://earthlearningsolution.org/
>>>
>>> _______________________________________________
>>> use-livecode mailing list
>>> [hidden email]
>>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>
>> _______________________________________________
>> use-livecode mailing list
>> [hidden email]
>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Jonathon.
In the stack I sent, I display the xml from the maps API, that includes the bounds. I'm confused, tho, by the lack of any change when I change the zoom level. Perhaps I'm not calling it with the proper parameters. I like the static maps API because it gives me an image that I can display without a browser.

Bill

William Prothero
http://es.earthednet.org

> On Jun 30, 2017, at 7:48 AM, Jonathan Lynch via use-livecode <[hidden email]> wrote:
>
> The google maps API has a function for getting the bounds of a map, which adjusts at each level.
>
> So, this is just a matter of calling on that function every time, so you get current bounds.
>
> I will look at the stack later today.
>
> Just be careful with bounds. They can cause confusion with changes in the orientation of the map.
>
> Sent from my iPhone
>
>> On Jun 30, 2017, at 10:10 AM, William Prothero via use-livecode <[hidden email]> wrote:
>>
>> Jonathan:
>> Here is a link to my test stack and some files I found that have various code to find the corners of the downloaded map.
>> https://www.dropbox.com/s/8xle2hrltx9ll0d/googleMapsAPiTests.zip?dl=0 <https://www.dropbox.com/s/8xle2hrltx9ll0d/googleMapsAPiTests.zip?dl=0>
>> My start on a conversion is in the script of the “Get Corners” button. I can get an xml file from the regular maps api, but the “bounds” property doesn’t change with zoom, which makes it not obvious how to convert that to what is being displayed, to get the corners. I have no problem converting pixels to mercator lat/lon, but until I can figure out the relationship between pixels and zoom levels, I’m stuck.
>>
>> Thanks for any help. I know your augmented Earth application uses these maps too, and I’m also willing to share code when I get this working.
>>
>> Bill P
>>
>>> On Jun 30, 2017, at 3:50 AM, Jonathan Lynch via use-livecode <[hidden email]> wrote:
>>>
>>> Hi Bill,
>>>
>>> Can you share the LC code and JS you are using?
>>>
>>> Sent from my iPhone
>>>
>>>> On Jun 29, 2017, at 9:59 PM, William Prothero via use-livecode <[hidden email]> wrote:
>>>>
>>>> Folks:
>>>> I’ve found a way to display an image of a google static map, in my app. It’s quite easy and well-documented. However, I need to get the lat and lon values of the corners of the map, at the displayed zoom level. There is a simple-looking javascript example for doing this at:
>>>> https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map <https://stackoverflow.com/questions/12507274/how-to-get-bounds-of-a-google-static-map>
>>>> My javascript knowledge is totally minimal and I am loath to learn javascript just to get this one handler into livecode script.
>>>>
>>>> What I have is an application that plots geophysical data on a world map. The map kind of ugly at very high magnifications and I thought the google map would give me a nice map image, with a wider range of magnifications, and minimize local storage space. What I will do is display the map image (centered on a particular lat/lon and magnification) in a rectangle, then take a snapshot, then copy my data symbols and images into the resulting snapshot. This works very will with my current map. I know that I can draw symbols directly on a google map using the map api, but it will be much more direct, and build on existing code, if I do it as described.
>>>>
>>>> So if anyone who is familiar with javascript has a few moments to give me some pointers on how I might convert this to LCS, I’d very much appreciate it. What I’m scratching my head over is how to access the parameters from the Google API to do the needed calculations. The link above is to the javascript example.
>>>>
>>>> Thanks in advance,
>>>> Bill P
>>>>
>>>> William A. Prothero
>>>> http://earthlearningsolution.org/
>>>>
>>>> _______________________________________________
>>>> use-livecode mailing list
>>>> [hidden email]
>>>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>>
>>> _______________________________________________
>>> use-livecode mailing list
>>> [hidden email]
>>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>
>> _______________________________________________
>> use-livecode mailing list
>> [hidden email]
>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
In reply to this post by Richmond Mathewson via use-livecode
You may use the technique of a stack I made in April 2017 on base of
a discussion started by you in the list:
http://lists.runrev.com/pipermail/use-livecode/2017-April/236632.html

I posted it just now here (Raspi stacks collection #100)
http://forums.livecode.com/viewtopic.php?p=155414#p155414

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Hermann:
I got your stack. It pretty much is where I am at now. However, it doesn’t solve my problem. If you notice the “geocode” call output, nothing changes when the zoom level changes. This isn’t much help when trying to find the lat/lon values of the corners of the image. That’s what I need. Neither the “bounds” parameters nor the “viewport” parameters change with zoom level. So, it doesn’t help when trying to get the corner lat/lons, which change with zoom level.

Best,
Bill

> On Jun 30, 2017, at 8:32 AM, hh via use-livecode <[hidden email]> wrote:
>
> You may use the technique of a stack I made in April 2017 on base of
> a discussion started by you in the list:
> http://lists.runrev.com/pipermail/use-livecode/2017-April/236632.html
>
> I posted it just now here (Raspi stacks collection #100)
> http://forums.livecode.com/viewtopic.php?p=155414#p155414
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Bill,

The bounds will only give you the corners of the image if you are facing exactly North, south, east, or west,

I am sorry I have not had a chance to check out your stack - will do so shortly

Sent from my iPhone

> On Jun 30, 2017, at 7:56 PM, William Prothero via use-livecode <[hidden email]> wrote:
>
> Hermann:
> I got your stack. It pretty much is where I am at now. However, it doesn’t solve my problem. If you notice the “geocode” call output, nothing changes when the zoom level changes. This isn’t much help when trying to find the lat/lon values of the corners of the image. That’s what I need. Neither the “bounds” parameters nor the “viewport” parameters change with zoom level. So, it doesn’t help when trying to get the corner lat/lons, which change with zoom level.
>
> Best,
> Bill
>
>> On Jun 30, 2017, at 8:32 AM, hh via use-livecode <[hidden email]> wrote:
>>
>> You may use the technique of a stack I made in April 2017 on base of
>> a discussion started by you in the list:
>> http://lists.runrev.com/pipermail/use-livecode/2017-April/236632.html
>>
>> I posted it just now here (Raspi stacks collection #100)
>> http://forums.livecode.com/viewtopic.php?p=155414#p155414
>>
>> _______________________________________________
>> use-livecode mailing list
>> [hidden email]
>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Hi Bill,

I am looking at your stack now. I don't see any place where you use JavaScript to get get the bounds from the Google maps API.

I think you would have to do it that way to get a reliable result.

That won't give you corners, exactly, but it will give you a minimum bounding rectangle that contains your map.

Sent from my iPhone

> On Jun 30, 2017, at 8:02 PM, [hidden email] wrote:
>
> Bill,
>
> The bounds will only give you the corners of the image if you are facing exactly North, south, east, or west,
>
> I am sorry I have not had a chance to check out your stack - will do so shortly
>
> Sent from my iPhone
>
>> On Jun 30, 2017, at 7:56 PM, William Prothero via use-livecode <[hidden email]> wrote:
>>
>> Hermann:
>> I got your stack. It pretty much is where I am at now. However, it doesn’t solve my problem. If you notice the “geocode” call output, nothing changes when the zoom level changes. This isn’t much help when trying to find the lat/lon values of the corners of the image. That’s what I need. Neither the “bounds” parameters nor the “viewport” parameters change with zoom level. So, it doesn’t help when trying to get the corner lat/lons, which change with zoom level.
>>
>> Best,
>> Bill
>>
>>> On Jun 30, 2017, at 8:32 AM, hh via use-livecode <[hidden email]> wrote:
>>>
>>> You may use the technique of a stack I made in April 2017 on base of
>>> a discussion started by you in the list:
>>> http://lists.runrev.com/pipermail/use-livecode/2017-April/236632.html
>>>
>>> I posted it just now here (Raspi stacks collection #100)
>>> http://forums.livecode.com/viewtopic.php?p=155414#p155414
>>>
>>> _______________________________________________
>>> use-livecode mailing list
>>> [hidden email]
>>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>
>> _______________________________________________
>> use-livecode mailing list
>> [hidden email]
>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Jonathon and hh:
Ok, it looks like I’ve made some progress, Googling around in the static maps api. I found that it is possible to directly set the lat lon bounds of the map I get. That’s even better than letting Google decide how much of the map to display and working backwards to get the corners. If I use the path= parameter and don’t specify zoom and center, I get exactly the map with the specified lat/lon bounds. Whoopee!

I’m testing it more.

However, if I do:
put "https://maps.googleapis.com/maps/api/staticmap?path=color:0x0000ff80|weight:1|34.0,-122.0|34.0,-120.0|32.0,-120.0|32.0,-122.0|34.0,-122.0&size=400x400&maptype=satellite&key=myAPIKey <https://maps.googleapis.com/maps/api/staticmap?path=color:0x0000ff80%7Cweight:1%7C34.0,-122.0%7C34.0,-120.0%7C32.0,-120.0%7C32.0,-122.0%7C34.0,-122.0&size=400x400&maptype=satellite&key=myAPIKey>" into retURL, I get a map with 34,122 (NW corner) and 32,120 (SE corner).

This is much more direct and I will use this, assuming my further tests look good.

Best,
Bill


> On Jun 30, 2017, at 6:02 PM, Jonathan Lynch via use-livecode <[hidden email]> wrote:
>
> Hi Bill,
>
> I am looking at your stack now. I don't see any place where you use JavaScript to get get the bounds from the Google maps API.
>
> I think you would have to do it that way to get a reliable result.
>
> That won't give you corners, exactly, but it will give you a minimum bounding rectangle that contains your map.
>
> Sent from my iPhone
>
>> On Jun 30, 2017, at 8:02 PM, [hidden email] wrote:
>>
>> Bill,
>>
>> The bounds will only give you the corners of the image if you are facing exactly North, south, east, or west,
>>
>> I am sorry I have not had a chance to check out your stack - will do so shortly
>>
>> Sent from my iPhone
>>
>>> On Jun 30, 2017, at 7:56 PM, William Prothero via use-livecode <[hidden email]> wrote:
>>>
>>> Hermann:
>>> I got your stack. It pretty much is where I am at now. However, it doesn’t solve my problem. If you notice the “geocode” call output, nothing changes when the zoom level changes. This isn’t much help when trying to find the lat/lon values of the corners of the image. That’s what I need. Neither the “bounds” parameters nor the “viewport” parameters change with zoom level. So, it doesn’t help when trying to get the corner lat/lons, which change with zoom level.
>>>
>>> Best,
>>> Bill
>>>
>>>> On Jun 30, 2017, at 8:32 AM, hh via use-livecode <[hidden email]> wrote:
>>>>
>>>> You may use the technique of a stack I made in April 2017 on base of
>>>> a discussion started by you in the list:
>>>> http://lists.runrev.com/pipermail/use-livecode/2017-April/236632.html
>>>>
>>>> I posted it just now here (Raspi stacks collection #100)
>>>> http://forums.livecode.com/viewtopic.php?p=155414#p155414
>>>>
>>>> _______________________________________________
>>>> use-livecode mailing list
>>>> [hidden email]
>>>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>>
>>> _______________________________________________
>>> use-livecode mailing list
>>> [hidden email]
>>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Whoops! Spoke too soon. It puts a box on the map, which is centered on the box, but the map bounds are outside of the box I specified.

Still looking.
Bill

> On Jun 30, 2017, at 6:12 PM, William Prothero via use-livecode <[hidden email]> wrote:
>
> Jonathon and hh:
> Ok, it looks like I’ve made some progress, Googling around in the static maps api. I found that it is possible to directly set the lat lon bounds of the map I get. That’s even better than letting Google decide how much of the map to display and working backwards to get the corners. If I use the path= parameter and don’t specify zoom and center, I get exactly the map with the specified lat/lon bounds. Whoopee!
>
> I’m testing it more.
> Bill P
>
>> On Jun 30, 2017, at 6:02 PM, Jonathan Lynch via use-livecode <[hidden email]> wrote:
>>
>> Hi Bill,
>>
>> I am looking at your stack now. I don't see any place where you use JavaScript to get get the bounds from the Google maps API.
>>
>> I think you would have to do it that way to get a reliable result.
>>
>> That won't give you corners, exactly, but it will give you a minimum bounding rectangle that contains your map.
>>
>> Sent from my iPhone
>>
>>> On Jun 30, 2017, at 8:02 PM, [hidden email] wrote:
>>>
>>> Bill,
>>>
>>> The bounds will only give you the corners of the image if you are facing exactly North, south, east, or west,
>>>
>>> I am sorry I have not had a chance to check out your stack - will do so shortly
>>>
>>> Sent from my iPhone
>>>
>>>> On Jun 30, 2017, at 7:56 PM, William Prothero via use-livecode <[hidden email]> wrote:
>>>>
>>>> Hermann:
>>>> I got your stack. It pretty much is where I am at now. However, it doesn’t solve my problem. If you notice the “geocode” call output, nothing changes when the zoom level changes. This isn’t much help when trying to find the lat/lon values of the corners of the image. That’s what I need. Neither the “bounds” parameters nor the “viewport” parameters change with zoom level. So, it doesn’t help when trying to get the corner lat/lons, which change with zoom level.
>>>>
>>>> Best,
>>>> Bill
>>>>
>>>>> On Jun 30, 2017, at 8:32 AM, hh via use-livecode <[hidden email]> wrote:
>>>>>
>>>>> You may use the technique of a stack I made in April 2017 on base of
>>>>> a discussion started by you in the list:
>>>>> http://lists.runrev.com/pipermail/use-livecode/2017-April/236632.html
>>>>>
>>>>> I posted it just now here (Raspi stacks collection #100)
>>>>> http://forums.livecode.com/viewtopic.php?p=155414#p155414
>>>>>
>>>>> _______________________________________________
>>>>> use-livecode mailing list
>>>>> [hidden email]
>>>>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>>>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>>>
>>>> _______________________________________________
>>>> use-livecode mailing list
>>>> [hidden email]
>>>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>
>> _______________________________________________
>> use-livecode mailing list
>> [hidden email]
>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
In reply to this post by Richmond Mathewson via use-livecode
This is the LC translation of the linked javascript from stackoverflow:
(I checked and simplfied a little bit the math, the Mercator projection is OK,
very clever there!):

It works here, happy mapping:

local MERCATOR_RANGE=256, pixelOrigin, pixelsPerLonDegree, pixelsPerLonRadian

on mouseUp
  put (55.9537534,-3.1988236) into centerPoint -- LC Home coords
  put 10 into zom   -- zoom
  put 600 into wdth -- image width
  put 450 into hght -- image height
  put getCorners (centerpoint,zom,wdth,hght)
  -- result is: "SW: 28.207002,-3.610811,NE: 28.262167,-2.786836"
end mouseUp

function getCorners center,zom,mapWidth,mapHeight
  put (MERCATOR_RANGE/2, MERCATOR_RANGE/2) into pixelOrigin
  put MERCATOR_RANGE/360 into pixelsPerLonDegree
  put pi*MERCATOR_RANGE/2 into pixelsPerLonRadian
  put 2^zom into scle
  put fromLatLngToPoint(center) into centerPx
  put ( (item 1 of centerPx)-(mapWidth/2)/scle, \
        (item 2 of centerPx)+(mapHeight/2)/scle ) into SWPoint
  put fromPointToLatLng(SWPoint) into SWLatLon
  put ( (item 1 of centerPx)+(mapWidth/2)/scle, \
        (item 2 of centerPx)-(mapHeight/2)/scle ) into NEPoint
  put fromPointToLatLng(NEPoint) into NELatLon
  return ("SW: " & SWLatLon, "NE: "& NELatLon)
end getCorners
   
function bound val, opt_min, opt_max
  if (opt_min is not empty) then put max(val, opt_min) into val
  if (opt_max is not empty) then put min(val, opt_max) into val
  return val
end bound

function degreesToRadians deg
  return deg * pi / 180;
end degreesToRadians

function radiansToDegrees rad
  return 180 * rad / pi
end radiansToDegrees

function fromLatLngToPoint latLng, opt_point
  put opt_point into point
  put pixelOrigin into origin
  put (item 1 of origin)+(item 2 of latLng)*pixelsPerLonDegree into item 1 of point
  put bound(sin(degreesToRadians(item 1 of latLng)), -0.9999, 0.9999) into siny
  put (item 2 of origin)+0.5*log10((1-siny)/(1+siny))*pixelsPerLonRadian into item 2 of point
  return point
end fromLatLngToPoint
   
function fromPointToLatLng point
  put pixelOrigin into origin
  put (item 1 of point -item 1 of origin)/pixelsPerLonDegree into lng
  put (item 2 of origin-item 2 of  point)/pixelsPerLonRadian into latRadians
  put radiansToDegrees(2*atan(exp(latRadians))-pi/2) into lat
  return (lat,lng)
end fromPointToLatLng
 
// pixelCoordinate = worldCoordinate * 2^zoomLevel
_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
In reply to this post by Richmond Mathewson via use-livecode
William,
sorry I made a mistake, you have to replace "log10" by "ln".

Hermann

=============
Here the full correct script:

local MERCATOR_RANGE=256, pixelOrigin, pixelsPerLonDegree, pixelsPerLonRadian

on mouseUp
  put (55.9537534, -3.1988236) into centerPoint -- LC Home
  put 10 into zom   -- zoom
  put 600 into wdth -- image width
  put 450 into hght -- image height
  put getCorners (centerpoint,zom,wdth,hght)
  -- result is "SW: 55.936222,-3.610811,NE: 55.971277,-2.786836"
end mouseUp

function getCorners center,zom,mapWidth,mapHeight
  put (MERCATOR_RANGE/2, MERCATOR_RANGE/2) into pixelOrigin
  put MERCATOR_RANGE/360 into pixelsPerLonDegree
  put pi*MERCATOR_RANGE/2 into pixelsPerLonRadian
  put 2^zom into scle
  put fromLatLngToPoint(center) into centerPx
  put ( (item 1 of centerPx)-(mapWidth/2)/scle, \
        (item 2 of centerPx)+(mapHeight/2)/scle ) into SWPoint
  put fromPointToLatLng(SWPoint) into SWLatLon
  put ( (item 1 of centerPx)+(mapWidth/2)/scle, \
        (item 2 of centerPx)-(mapHeight/2)/scle ) into NEPoint
  put fromPointToLatLng(NEPoint) into NELatLon
  return ("SW: " & SWLatLon, "NE: "& NELatLon)
end getCorners
   
function bound val, opt_min, opt_max
  if (opt_min is not empty) then put max(val, opt_min) into val
  if (opt_max is not empty) then put min(val, opt_max) into val
  return val
end bound

function degreesToRadians deg
  return deg * pi / 180;
end degreesToRadians

function radiansToDegrees rad
  return 180 * rad / pi
end radiansToDegrees

function fromLatLngToPoint latLng, opt_point
  put opt_point into point
  put pixelOrigin into origin
  put (item 1 of origin)+(item 2 of latLng)*pixelsPerLonDegree into item 1 of point
  put bound(sin(degreesToRadians(item 1 of latLng)), -0.9999, 0.9999) into siny
  put (item 2 of origin)+0.5*ln((1-siny)/(1+siny))*pixelsPerLonRadian into item 2 of point
  return point
end fromLatLngToPoint
   
function fromPointToLatLng point
  put pixelOrigin into origin
  put (item 1 of point -item 1 of origin)/pixelsPerLonDegree into lng
  put (item 2 of origin-item 2 of  point)/pixelsPerLonRadian into latRadians
  put radiansToDegrees(2*atan(exp(latRadians))-pi/2) into lat
  return (lat,lng)
end fromPointToLatLng
 
// pixelCoordinate = worldCoordinate * 2^zoomLevel


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
In reply to this post by Richmond Mathewson via use-livecode
Sorry all, I'm used to work in the forums where one can easily edit posts to
remove errors and typos.

So here another correction, a constant (pixelsPerLonRadian) was wrong in the
first two versions above.

My last version, hope it's all correct now:

local MERCATOR_RANGE=256, pixelOrigin, pixelsPerLonDegree, pixelsPerLonRadian

on mouseUp
  put (55.9537534, -3.1988236) into centerPoint -- LC Home
  put trunc(the thumbpos of sb "zoom") into zom   -- zoom
  put 600 into wdth -- image width
  put 450 into hght -- image height
  put getCorners (centerpoint,zom,wdth,hght)
  -- result is "SW: 55.780374,-3.610811,NE: 56.126359,-2.786836"
end mouseUp

function getCorners center,zom,mapWidth,mapHeight
  put (MERCATOR_RANGE/2, MERCATOR_RANGE/2) into pixelOrigin
  put MERCATOR_RANGE/360 into pixelsPerLonDegree
  put MERCATOR_RANGE/2/pi into pixelsPerLonRadian
  put 2^zom into scle
  put fromLatLngToPoint(center) into centerPx
  put ( (item 1 of centerPx)-(mapWidth/2)/scle, \
        (item 2 of centerPx)+(mapHeight/2)/scle ) into SWPoint
  put fromPointToLatLng(SWPoint) into SWLatLon
  put ( (item 1 of centerPx)+(mapWidth/2)/scle, \
        (item 2 of centerPx)-(mapHeight/2)/scle ) into NEPoint
  put fromPointToLatLng(NEPoint) into NELatLon
  return ("SW: " & SWLatLon, "NE: "& NELatLon)
end getCorners
   
function bound val, opt_min, opt_max
  if (opt_min is not empty) then put max(val, opt_min) into val
  if (opt_max is not empty) then put min(val, opt_max) into val
  return val
end bound

function degreesToRadians deg
  return deg * pi / 180;
end degreesToRadians

function radiansToDegrees rad
  return 180 * rad / pi
end radiansToDegrees

function fromLatLngToPoint latLng, opt_point
  put opt_point into point
  put pixelOrigin into origin
  put (item 1 of origin)+(item 2 of latLng)*pixelsPerLonDegree into item 1 of point
  put bound(sin(degreesToRadians(item 1 of latLng)), -0.9999, 0.9999) into siny
  put (item 2 of origin)+0.5*ln((1-siny)/(1+siny))*pixelsPerLonRadian into item 2 of point
  return point
end fromLatLngToPoint
   
function fromPointToLatLng point
  put pixelOrigin into origin
  put (item 1 of point -item 1 of origin)/pixelsPerLonDegree into lng
  put (item 2 of origin-item 2 of  point)/pixelsPerLonRadian into latRadians
  put radiansToDegrees(2*atan(exp(latRadians))-pi/2) into lat
  return (lat,lng)
end fromPointToLatLng
 
// pixelCoordinate = worldCoordinate * 2^zoomLevel


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Herman,
I can't begin to tell you how much I appreciate you doing this! Thanks so much!!

I'm off my computer for the day, but will run it through its paces tomorrow.

Thanks again!

Bill P

William Prothero
http://es.earthednet.org

> On Jun 30, 2017, at 8:27 PM, hh via use-livecode <[hidden email]> wrote:
>
> Sorry all, I'm used to work in the forums where one can easily edit posts to
> remove errors and typos.
>
> So here another correction, a constant (pixelsPerLonRadian) was wrong in the
> first two versions above.
>
> My last version, hope it's all correct now:
>
> local MERCATOR_RANGE=256, pixelOrigin, pixelsPerLonDegree, pixelsPerLonRadian
>
> on mouseUp
>  put (55.9537534, -3.1988236) into centerPoint -- LC Home
>  put trunc(the thumbpos of sb "zoom") into zom   -- zoom
>  put 600 into wdth -- image width
>  put 450 into hght -- image height
>  put getCorners (centerpoint,zom,wdth,hght)
>  -- result is "SW: 55.780374,-3.610811,NE: 56.126359,-2.786836"
> end mouseUp
>
> function getCorners center,zom,mapWidth,mapHeight
>  put (MERCATOR_RANGE/2, MERCATOR_RANGE/2) into pixelOrigin
>  put MERCATOR_RANGE/360 into pixelsPerLonDegree
>  put MERCATOR_RANGE/2/pi into pixelsPerLonRadian
>  put 2^zom into scle
>  put fromLatLngToPoint(center) into centerPx
>  put ( (item 1 of centerPx)-(mapWidth/2)/scle, \
>        (item 2 of centerPx)+(mapHeight/2)/scle ) into SWPoint
>  put fromPointToLatLng(SWPoint) into SWLatLon
>  put ( (item 1 of centerPx)+(mapWidth/2)/scle, \
>        (item 2 of centerPx)-(mapHeight/2)/scle ) into NEPoint
>  put fromPointToLatLng(NEPoint) into NELatLon
>  return ("SW: " & SWLatLon, "NE: "& NELatLon)
> end getCorners
>
> function bound val, opt_min, opt_max
>  if (opt_min is not empty) then put max(val, opt_min) into val
>  if (opt_max is not empty) then put min(val, opt_max) into val
>  return val
> end bound
>
> function degreesToRadians deg
>  return deg * pi / 180;
> end degreesToRadians
>
> function radiansToDegrees rad
>  return 180 * rad / pi
> end radiansToDegrees
>
> function fromLatLngToPoint latLng, opt_point
>  put opt_point into point
>  put pixelOrigin into origin
>  put (item 1 of origin)+(item 2 of latLng)*pixelsPerLonDegree into item 1 of point
>  put bound(sin(degreesToRadians(item 1 of latLng)), -0.9999, 0.9999) into siny
>  put (item 2 of origin)+0.5*ln((1-siny)/(1+siny))*pixelsPerLonRadian into item 2 of point
>  return point
> end fromLatLngToPoint
>
> function fromPointToLatLng point
>  put pixelOrigin into origin
>  put (item 1 of point -item 1 of origin)/pixelsPerLonDegree into lng
>  put (item 2 of origin-item 2 of  point)/pixelsPerLonRadian into latRadians
>  put radiansToDegrees(2*atan(exp(latRadians))-pi/2) into lat
>  return (lat,lng)
> end fromPointToLatLng
>
> // pixelCoordinate = worldCoordinate * 2^zoomLevel
>
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Hermann:
This is looking really good! I will be doing more testing as I integrate it into my project, but at this stage, it is behaving as expected.

Thanks so much. Hoping I can repay you in some way. Let me know.

Best,
Bill P

> On Jun 30, 2017, at 8:58 PM, prothero--- via use-livecode <[hidden email]> wrote:
>
> Herman,
> I can't begin to tell you how much I appreciate you doing this! Thanks so much!!
>
> I'm off my computer for the day, but will run it through its paces tomorrow.
>
> Thanks again!
>
> Bill P
>
> William Prothero
> http://es.earthednet.org
>
>> On Jun 30, 2017, at 8:27 PM, hh via use-livecode <[hidden email]> wrote:
>>
>> Sorry all, I'm used to work in the forums where one can easily edit posts to
>> remove errors and typos.
>>
>> So here another correction, a constant (pixelsPerLonRadian) was wrong in the
>> first two versions above.
>>
>> My last version, hope it's all correct now:
>>
>> local MERCATOR_RANGE=256, pixelOrigin, pixelsPerLonDegree, pixelsPerLonRadian
>>
>> on mouseUp
>> put (55.9537534, -3.1988236) into centerPoint -- LC Home
>> put trunc(the thumbpos of sb "zoom") into zom   -- zoom
>> put 600 into wdth -- image width
>> put 450 into hght -- image height
>> put getCorners (centerpoint,zom,wdth,hght)
>> -- result is "SW: 55.780374,-3.610811,NE: 56.126359,-2.786836"
>> end mouseUp
>>
>> function getCorners center,zom,mapWidth,mapHeight
>> put (MERCATOR_RANGE/2, MERCATOR_RANGE/2) into pixelOrigin
>> put MERCATOR_RANGE/360 into pixelsPerLonDegree
>> put MERCATOR_RANGE/2/pi into pixelsPerLonRadian
>> put 2^zom into scle
>> put fromLatLngToPoint(center) into centerPx
>> put ( (item 1 of centerPx)-(mapWidth/2)/scle, \
>>       (item 2 of centerPx)+(mapHeight/2)/scle ) into SWPoint
>> put fromPointToLatLng(SWPoint) into SWLatLon
>> put ( (item 1 of centerPx)+(mapWidth/2)/scle, \
>>       (item 2 of centerPx)-(mapHeight/2)/scle ) into NEPoint
>> put fromPointToLatLng(NEPoint) into NELatLon
>> return ("SW: " & SWLatLon, "NE: "& NELatLon)
>> end getCorners
>>
>> function bound val, opt_min, opt_max
>> if (opt_min is not empty) then put max(val, opt_min) into val
>> if (opt_max is not empty) then put min(val, opt_max) into val
>> return val
>> end bound
>>
>> function degreesToRadians deg
>> return deg * pi / 180;
>> end degreesToRadians
>>
>> function radiansToDegrees rad
>> return 180 * rad / pi
>> end radiansToDegrees
>>
>> function fromLatLngToPoint latLng, opt_point
>> put opt_point into point
>> put pixelOrigin into origin
>> put (item 1 of origin)+(item 2 of latLng)*pixelsPerLonDegree into item 1 of point
>> put bound(sin(degreesToRadians(item 1 of latLng)), -0.9999, 0.9999) into siny
>> put (item 2 of origin)+0.5*ln((1-siny)/(1+siny))*pixelsPerLonRadian into item 2 of point
>> return point
>> end fromLatLngToPoint
>>
>> function fromPointToLatLng point
>> put pixelOrigin into origin
>> put (item 1 of point -item 1 of origin)/pixelsPerLonDegree into lng
>> put (item 2 of origin-item 2 of  point)/pixelsPerLonRadian into latRadians
>> put radiansToDegrees(2*atan(exp(latRadians))-pi/2) into lat
>> return (lat,lng)
>> end fromPointToLatLng
>>
>> // pixelCoordinate = worldCoordinate * 2^zoomLevel
>>
>>
>> _______________________________________________
>> use-livecode mailing list
>> [hidden email]
>> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
In reply to this post by Richmond Mathewson via use-livecode
@Bill.
No thank for that. I started to work with javascript in November 2016 when
the HTML5 standalone builder introduced "do as javascript". It was now a
good exercise because your javascript source is by an expert, written very
clear and clean.

Please show us your final product (doesn't matter if code is protected),
your project sounds very interesting. Or give a 7-15 minute talk on the
principles? AFAIK there are still some slots open in LC GLobal.

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Problem

Richmond Mathewson via use-livecode
Hermann,
I'll definitely share a demo. Re a LC Global talk, I'm unable to commit full day slots this summer, so sorry for that. I'm hoping I can get some of the new techniques and info from future docs and discussions and, except for this Google maps issue, I'm on top of my project.

Thanks again for your help.
Bill P

William Prothero
http://es.earthednet.org

> On Jul 1, 2017, at 12:17 PM, hh via use-livecode <[hidden email]> wrote:
>
> @Bill.
> No thank for that. I started to work with javascript in November 2016 when
> the HTML5 standalone builder introduced "do as javascript". It was now a
> good exercise because your javascript source is by an expert, written very
> clear and clean.
>
> Please show us your final product (doesn't matter if code is protected),
> your project sounds very interesting. Or give a 7-15 minute talk on the
> principles? AFAIK there are still some slots open in LC GLobal.
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Google Static Maps Demo Available

Richmond Mathewson via use-livecode
Folks:
Thanks to help from Hermann, I am sharing a demo stack that accesses the Google Static Maps API to display maps. This API allows me to display a terrain map, and determine the lat/lon values of any point on the map, I will take a snapshot of the map image and draw symbols on it that will represent geophysical data.

You can download the demo at:
http://earthlearningsolutions.org/google-static-maps-demo/ <http://earthlearningsolutions.org/google-static-maps-demo/>

I hope you find it useful.
Bill P

William A. Prothero
http://earthlearningsolution.org/

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Google Static Maps Demo Available

Richmond Mathewson via use-livecode
Thanks for this, Bill

Sent from my iPhone

> On Jul 6, 2017, at 8:31 PM, William Prothero via use-livecode <[hidden email]> wrote:
>
> Folks:
> Thanks to help from Hermann, I am sharing a demo stack that accesses the Google Static Maps API to display maps. This API allows me to display a terrain map, and determine the lat/lon values of any point on the map, I will take a snapshot of the map image and draw symbols on it that will represent geophysical data.
>
> You can download the demo at:
> http://earthlearningsolutions.org/google-static-maps-demo/ <http://earthlearningsolutions.org/google-static-maps-demo/>
>
> I hope you find it useful.
> Bill P
>
> William A. Prothero
> http://earthlearningsolution.org/
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
12
Loading...