Incorporating google maps and google earth into your remote sensing applications
Download
1 / 65

Incorporating Google Maps and Google Earth into your Remote Sensing Applications - PowerPoint PPT Presentation


  • 904 Views
  • Uploaded on

Incorporating Google Maps and Google Earth into your Remote Sensing Applications J. Freemantle OARS Technical Meeting, Dec 11, 2006 Outline Overview of Google Earth Simple examples using keyhole markup language (kml) Using the Google Maps/Earth API Some community examples Questions?

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Incorporating Google Maps and Google Earth into your Remote Sensing Applications' - jacob


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
Incorporating google maps and google earth into your remote sensing applications l.jpg

Incorporating Google Maps and Google Earth into your Remote Sensing Applications

J. Freemantle

OARS Technical Meeting,

Dec 11, 2006


Outline l.jpg
Outline Sensing Applications

  • Overview of Google Earth

  • Simple examples using keyhole markup language (kml)

  • Using the Google Maps/Earth API

  • Some community examples

  • Questions?


Google earth l.jpg
Google Earth Sensing Applications

  • Client/Server Application

  • Free for basic version

  • Works on Windows (2000/XP), Mac OS 10.3.9, Linux


Google earth overview l.jpg
Google Earth Overview Sensing Applications

  • Satellite and Airborne Imagery 1-3 years old

  • Spatial resolution in countryside < 15 m. Major US cities less than 1-2 feet (20-40 cm).

  • Parts of Manhattan (Fulton Co.) 10 cm!


York university l.jpg
York University Sensing Applications


Newmarket l.jpg
Newmarket Sensing Applications


Low vs high res data aurora l.jpg
Low vs high res. data (Aurora) Sensing Applications


Toronto l.jpg
Toronto Sensing Applications


New york city 20 cm l.jpg
New York City (20 cm) Sensing Applications


New york city 10 cm l.jpg
New York City (10 cm) Sensing Applications


10 and 20 cm images compared l.jpg
10 and 20 cm images compared Sensing Applications


Primary data roads etc l.jpg
Primary Data (roads etc) Sensing Applications


Boundary errors l.jpg
Boundary Errors Sensing Applications


Why google l.jpg
Why Google? Sensing Applications

  • Its free!!!

  • Generally up to date

  • Large user community

  • Developer/programmer friendly

  • Easy to learn

  • Platform independent

  • Its cool!


Assumptions caveats l.jpg
Assumptions/Caveats Sensing Applications

  • Check the fine print of End User License (EUL) for your situation.

  • Google Earth 4.0 (Beta), free version.

  • Public/Private data? (choose wisely).


Simple examples using kml l.jpg
Simple Examples using KML Sensing Applications

  • Point

  • Pictures

  • Tracks

  • Overlays

  • Links to external data


Warning code examples l.jpg
Warning Code Examples! Sensing Applications


Keyhole markup language kml l.jpg
Keyhole Markup Language (kml) Sensing Applications

  • Xml grammar and file format for describing geographic features in google earth/maps

    • Points

    • Lines

    • Polygons

    • Models

    • links


Keyhole markup language kml20 l.jpg
Keyhole Markup Language (KML) Sensing Applications

  • KML files can be shared.

  • KMZ files are a compressed version of KML files.

  • Google Earth processes kml files like web browsers process html files.


Kml example simple point l.jpg
Kml example: Simple point Sensing Applications

<?xml version="1.0" encoding="UTF-8"?>

<kml xmlns="http://earth.google.com/kml/2.0">

<Placemark>

<name>OARS Meeting</name>

<description><![CDATA[Incorporating Google Maps and Google Earth into your Remote Sensing Applications <br>

Presented by Jim Freemantle <br>Dec 11, 2006 7:00 pm <br>

Room 129 Chemistry Building, York University, Toronto. <br>]]></description>

<Point id="khPoint616">

<coordinates>-79.508,43.773225,0</coordinates>

</Point>

</Placemark>

</kml>


Simple point l.jpg
Simple Point Sensing Applications


Simple point23 l.jpg
Simple Point Sensing Applications


Simple point with link l.jpg
Simple point, with link Sensing Applications

<?xml version="1.0" encoding="UTF-8"?>

<kml xmlns="http://earth.google.com/kml/2.0">

<Placemark>

<name>OARS Meeting</name>

<description><![CDATA[Incorporating Google Maps and Google Earth into your Remote Sensing Applications <br>

<a href=“http://www.oars.on.ca/meetings.php”> details </a>

<br>]]></description>

<Point id="khPoint616">

<coordinates>-79.508,43.773225,0</coordinates>

</Point>

</Placemark>

</kml>


Simple point with link25 l.jpg
Simple point with link Sensing Applications


Simple point with image l.jpg
Simple point, with image Sensing Applications

<?xml version="1.0" encoding="UTF-8"?>

<kml xmlns="http://earth.google.com/kml/2.0">

<Placemark>

<name>OARS Meeting</name>

<description><![CDATA[Incorporating Google Maps and Google Earth into your Remote Sensing Applications <br>

<a href=“http://www.oars.on.ca/meetings.php”> details </a>

<br>

<img src="c:/documents and settings/user/my documents/my pictures/jim_pic.jpg"/>]]></description>

<Point id="khPoint616">

<coordinates>-79.508,43.773225,0</coordinates>

</Point>

</Placemark>

</kml>


Simple point with image27 l.jpg
Simple point with image Sensing Applications


Track l.jpg
Track Sensing Applications

<?xml version="1.0" encoding="UTF-8"?>

<kml xmlns="http://earth.google.com/kml/2.0">

<Document>

<name>t0490f13</name>

<Placemark>

<name>t0490f13</name>

<description><![CDATA[Flight Line 13 tape 490 CASI 2001 <br>]]></description>

<LineString>

<coordinates>-68.8911,48.79734,2470.74 -68.8947,48.79449,2471.35 </coordinates>

<coordinates> -68.9127, 48.78028,2466.96,-68.9164,48.77747,2469.82 </coordinates>

</LineString>

</Placemark>

</Document>

</kml>


Track29 l.jpg
Track Sensing Applications


Track30 l.jpg
Track Sensing Applications


Geotagging l.jpg
GeoTagging Sensing Applications


Geotagging32 l.jpg
GeoTagging Sensing Applications

  • Requirements

    • GPS device

    • Camera with EXIF format jpg files and internal clock

    • Software to sync gps track with time of photo

    • Software to create google earth file (.kml)


Geotagging33 l.jpg
GeoTagging Sensing Applications

  • GPS Devices Used

Garmin Forerunner 201

Runners GPS ($159.00)

Sony GPS-SC1 ($129.00)


Geotagging34 l.jpg
GeoTagging Sensing Applications

  • Software Used

    • GPSBabel (NMEA to GPX)

    • GPS Image Tracker (Sony) (Not required)

    • iTag


Geotagging35 l.jpg
GeoTagging Sensing Applications


Geotagging36 l.jpg
GeoTagging Sensing Applications


Geotagging37 l.jpg
GeoTagging Sensing Applications


Overlays l.jpg
Overlays Sensing Applications

  • Getting your georeferenced data into Google Earth

    • Need georeferenced data

    • Manually imported, as a jpg image, and matched to Google Earth


Overlays39 l.jpg
Overlays Sensing Applications


Overlays40 l.jpg
Overlays Sensing Applications


Links l.jpg
Links Sensing Applications

  • Images

  • External websites via url

  • Databases


Track with link l.jpg
Track with link Sensing Applications

<?xml version="1.0" encoding="UTF-8"?>

<kml xmlns="http://earth.google.com/kml/2.0">

<Document>

<name>t0489f06</name>

<Placemark>

<name>t0489f06</name>

<description><![CDATA[Flight Line 06 tape 489 CASI 2001 <br>

<a href="http://www.aerocan.net/tapedb.xml#489"> Link to Flight Log </a> <br>]]></description>

<LineString>

<coordinates>-68.8911,48.79734,2470.74 -68.8947,48.79449,2471.35 </coordinates>

<coordinates> -68.9127, 48.78028,2466.96,-68.9164,48.77747,2469.82 </coordinates>

</LineString>

</Placemark>

</Document>

</kml>


Track with link43 l.jpg
Track with link Sensing Applications


Point with link l.jpg
Point with link Sensing Applications

<?xml version="1.0" encoding="UTF-8"?>

<kml xmlns="http://earth.google.com/kml/2.0">

<Placemark>

<name>Waskesiu</name>

<description><![CDATA[Aeronet Sites Worldwide

<br><a href="http://aeronet.gsfc.nasa.gov/cgi-bin/

type_one_station_opera_v2_new?site=Waskesiu&nachal=2&aero_water=0&level=1

&if_day=0&year_or_month=0">Link to Waskesiu data</a><br>]]></description>

<Point id="khPoint616">

<coordinates>-106.083,53.916698,550</coordinates>

</Point>

</Placemark>

</kml>


Point with link45 l.jpg
Point Sensing Applicationswith Link


Google earth map application programmer interface api l.jpg
Google Earth/Map Application Programmer Interface (API) Sensing Applications

  • Sign up for your key

  • Can be used only on requested web accessible directory eg. http://www.example.com/gmaps

  • Receive example script and put it in that directory

  • Build Google Map applications from there


Slide47 l.jpg

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" Sensing Applications

"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="content-type" content="text/html; charset=utf-8"/>

<title>Jim's Google Maps JavaScript API Example from M. Brown</title>

<script src="http://maps.google.com/maps?file=api&amp;v=2&amp;key=xxx"

type="text/javascript"></script>

<script type="text/javascript">

//<![CDATA[

var largemapcontrol = new GLargeMapControl();

function load() {

if (GBrowserIsCompatible()) {

var map = new GMap(document.getElementById("map"));

GEvent.addListener(map,'click',function(overlay,point) {

var latLngStr = '(' + point.x + ', '+ point.y + ')<br/>';

var message = document.getElementById("message");

message.innerHTML = latLngStr;

});

map.centerAndZoom(new GPoint(-79.505, 43.77382), 4);

map.addControl(largemapcontrol);

}

}

//]]>

</script>

</head>

<body onload="load()" onunload="GUnload()">

<div id="map" style="width: 500px; height: 300px"></div>

<div id="message"></div>

</body>

</html>


Google map api l.jpg
Google Map API Sensing Applications


Google earth api l.jpg
Google Earth API Sensing Applications

  • Link to dynamically generated kml

  • No API key required

  • See http://earth.google.com/kml/kml_tut.html#tracking_point


Google earth example l.jpg
Google Earth Example Sensing Applications

<?php

// get the time

$timesnap = date("H:i:s");

$BOX=$_GET[BBOX];

// split the client's BBOX return by commas and spaces to obtain an array of coordinates

$coords = preg_split('/,|\s/', $BOX);

// for clarity, place each coordinate into a clearly marked bottom_left or top_right variable

$bl_lon = $coords[0];

$bl_lat = $coords[1];

$tr_lon = $coords[2];

$tr_lat = $coords[3];

// calculate the approx center of the view -- note that this is innaccurate if the user is not looking straight down

$userlon = (($coords[2] - $coords[0])/2) + $coords[0];

$userlat = (($coords[3] - $coords[1])/2) + $coords[1];

$response = '<?xml version="1.0" encoding="UTF-8"?>';

$response .= '<kml xmlns="http://earth.google.com/kml/2.0">';

$response .= '<Placemark>';

$response .= '<name>'.$timesnap.'</name>';

$response .= '<Point>';

$response .= "<coordinates>$userlon,$userlat,0</coordinates>";

$response .= '</Point>';

$response .= '</Placemark>';

$response .= '</kml>';

echo $response;

?>


Examples from the community l.jpg
Examples from the Community Sensing Applications

  • “Mashups”


Acknowledgements l.jpg
Acknowledgements Sensing Applications

  • Data providers

    • J. Miller (York U), A. Smith (Agr. Canada)

  • Colleagues

    • I. Lumb, L. Gray


Resources l.jpg
Resources Sensing Applications

  • http://earth.google.com

  • http://maps.google.com

  • http://www.oars.on.ca

  • “Hacking Google Maps and Google Earth” by Martin C. Brown

  • Check back on the OARS website for a copy of these slides and list url of useful links


Resources64 l.jpg
Resources Sensing Applications

Interesting links

GeoTagging "adding location information to pictures"

http://www.iceburnslair.com/mapper/

http://wwmx.org/Download.aspx

http://www.oziphototool.com//

http://www.gpsbabel.org/

http://itagsoftware.awswa.com/

Interesting discussion at Canadian Canoe Routes on this topic:

http://www.myccr.com/SectionForums/viewtopic.php?p=183038

Mashups:

http://www.beerhunter.ca/OttawaArea

http://googlemapsmania.blogspot.com/


Questions l.jpg
Questions? Sensing Applications


ad