SlideShare a Scribd company logo
1 of 38
When Google Maps
Gives You Lemons,
 Make Lemonade
     Wm Leler
   Flightstats Inc.
Google Maps
               (the good)
• 7 years old, used by 350,000 websites
• Free (until recently)
• Far better than what was available before
• Continuously improved:
 • Street view, 3D buildings, traffic, routing ...
• Brought map-based apps to the Internet
 • Enabled explosion of map mashups
Google Maps
               (the bad)
• Closed, proprietary system
  • no source
  • difficult to fix bugs or add features
  • Poor separation of maps from API
• Generic, one-size-fits-all
 • Three basemaps: street, satellite, terrain
 • Automobile centric
Google Maps
               (the evil)
• The first one is free
 • Now charging heavy users
 • Advertising
• Suppressed development of alternatives
• Google owns you and controls you
 • V2 to V3 API bungle
Maps in 3 Parts
               Imagery Geography
          Maps & Info & Routes
 Data


Server     Map Tiles, Geom, etc.


                                   • User controls
 Client
            JavaScript Map API
                                   • Loads Map Tiles
Browser                            • Markers and
                                    annotations
Sources of Map Data
• Not free: Navteq, Navinfo, DigitalGlobe,
  SRTM, Planetary Visions, Google
• OpenStreetMap, US Census TIGER
• NASA/JPL, US Dept. of Agriculture
• Natural Earth, CGIAR-CSI
• any geographic source
Rendering Map Data
Map Data: roads, boundaries, names, ...
                               Styles:
                               colors,
Zoom
               Render          line widths,
levels
                               fonts,
                 Tile          hill shading,
                               visibility,
                               detail, ...
          Map Tiles to Serve
Map Tiles
• Slice up large maps into square pieces
• Don’t have to download entire map into
  the browser
• Enables interactivity, smooth scrolling
 • use AJAX calls to download tiles
 • lowers resource needs for browser and
    server, lowers bandwidth demands
The Tao of Tiles
• 256 x 256 pixels
• Zoom level 0 has one
  tile for entire world
• Longitude (x) goes
  from -180º to 180º

• Latitude (y) goes from
  85.051º to -85.051º
  (arctan sinh π)
Zoom level 1 has 4 tiles
                 number of tiles
                           zoom
                   =   4
                       1
                   4 =4
Tile Explosion
• City level (11) = 4,194,304 tiles

• Street level (16) =
  4,294,967,296 tiles


• Google maps goes
  to level 22 =
  > 17 trillion tiles
Subdomains
• Browsers used to be limited to 2 network
  connections per domain. (Recent browsers
  raised limit as high as 6.)
• To get around this limitation, map servers
  generally point multiple (3 or 4) subdomains
  at a single tile server.
  http://mt0.google.com/
  http://mt1.google.com/
  http://mt2.google.com/
  http://mt3.google.com/
Map Tile Servers
1. Use a public map server:
  • Open MapQuest, CloudMade, MapBox
2. Use someone else’s map server
3. Your own server
  • or cloud storage
Open Mapquest
• http://open.mapquest.com/
• OpenStreetMap, aerial, and overlay tiles
• Free!
• Supports high bandwidth on request
   • reliability is not guaranteed
• Satellite imagery is seasonal!
CloudMade
• Has a large number of maps, or
• Map Studio allows you to create your own
  map styles
• Based on OSM data
• CloudMade will host your map tiles ($)
 • or you can download and host yourself
MapBox
• TileMill allows you to create maps, using
  any data
  • not just styles
• MapBox will host your tiles ($)
 • or you can download and host yourself
• They have created a large number of maps
• Can dynamically modify tiles
Someone Else’s Server
• Almost all map tile servers are unsecured
• You are identified by the referrer header
• OK for low volume use
• No reliability guarantees
• Just need to determine server URL
 • (except for Microsoft Bing maps)
Map Server URLs
Easy to determine URL using browser debugger

                         Google Maps

                         Safari Browser
                            debugger
Constructing
            Tile URLs
http://mt1.google.com/vt/lyrs=m@174227760&hl=en&

                src=app&x=81&y=183&z=9&s=Ga
  subdomain
                    column      row    zoom
new L.TileLayer(
'http://mt{s}.google.com/vt/lyrs=m@174227760&hl=en&
  src=app&x={x}&y={y}&z={z}&s=Ga',
{ subdomains:'0123', attribution:'© Google' })

• Leaflet plugs in the values for you
Slippy Maps

• “slippy” naming convention for map tiles:
http://<sub>.domain.com/.../<zoom>/<x>/<y>.png

http://otile1.mqcdn.com/tiles/1.0.0/osm/4/63/99.png

• Tiles can be served as normal files
   No need for a special tile server
MapsGL
               (side note)

• Google has introduced MapsGL, which uses
  WebGL to draw streets, buildings, and
  other features directly in a canvas
• Does not use image-based map tiles
• Won’t work for satellite or other imagery
• Currently works only on a few browsers
• (alternatively, can use GeoJSON)
JavaScript Map APIs
• Proprietary:
 • Google Maps API
 • Mapquest, Microsoft Bing, Nokia OVI, ...
• Open:
 • OpenLayers - http://openlayers.org/
 • Leaflet - http://leaflet.cloudmade.com/
 • Modest Maps - http://modestmaps.com/
 • Polymaps - http://polymaps.org/ (SVG)
Google Maps
<html style="height:100%"><head>
<title>Google Maps Example</title>
<script src="http://maps.googleapis.com/maps/api/js?
key=API_KEY&sensor=false"></script>
</head><body style="height:100%;margin:0;padding:0">
  <div id="map" style="width:100%; height:100%"></div>
<script type="text/javascript">
  var pdx = new google.maps.LatLng(45.53, -122.67);
  var map = new google.maps.Map(
    document.getElementById('map'),
    { center: pdx, zoom: 14,
      mapTypeID: google.maps.MapTypeId.ROADMAP) } );
</script>
</body></html>
OpenLayers
<html style="height:100%"><head>
<title>OpenLayers Example</title>
<script src="http://openlayers.org/api/OpenLayers.js">
</script>
</head><body style="height:100%;margin:0;padding:0">
  <div id="map" style="width:100%; height:100%"></div>
<script type="text/javascript">
  var map = new OpenLayers.Map('map');
  var mapnik = new OpenLayers.Layer.OSM();
  map.addLayer(mapnik);
  var pdx = new OpenLayers.LonLat(-122.67, 45.53).
    transform(new OpenLayers.Projection("EPSG:4326"),
    map.getProjectionObject());
  map.setCenter(pdx, 14);
</script>
</body></html>
Leaflet
<html style="height:100%"><head>
  <title>Leaflet Example</title>
  <link rel="stylesheet" href="leaflet.css" />
  <!--[if lte IE 8]><link rel="stylesheet"
href="leaflet.ie.css" /><![endif]-->
  <script type="text/javascript" src="leaflet.js"></script>
</head><body style="height:100%;margin:0;padding:0">
<div id="map" style="height: 100%;width:100%"></div>
<script type="text/javascript">
  var map = new L.Map('map');
  var tiles = new L.TileLayer(
'http://mt{s}.google.com/vt/v=w2.106&x={x}&y={y}&z={z}&s=',
{ subdomains:'0123', attribution:'&copy; Google 2011' });
  var pdx = new L.LatLng(45.58961, -122.592121);
  map.addLayer(tiles).setView(pdx, 14);
</script>
</body></html>
What should you do?
• Just want to put a simple map on a web
  page or blog post?
 • Keep using Google Maps (or Bing, OVI,
    MapQuest, etc.), especially if you need
    traffic data
 • Use a static image of a map
 • Mapbox Embed (no JavaScript!) -
    http://mapbox.com/hosting/embedding/
If you want more
• More Flexibility
 • Leaflet with Open MapQuest
 • CloudMade or MapBox
• More volume
 • your hosting on cloud
 • open (CC) maps (or your own)
http://rtp.trimet.org/
• Multi-modal regional trip planner
 • car, bus, light rail, streetcar, trolley,
   commuter train, aerial tram, bicycle, walk
 • Open data allows customization
• OpenLayers software on the browser
• Open Mapquest servers, OpenStreetMap
• Developing their own map
Foursquare
• Leaflet on the browser
• Mapbox servers (paid)
• Mapbox “Streets” map
  (based on OSM data)
Flightstats
• Leaflet
• Amazon S3 and CloudFront servers
• various open maps:
 • Stamen Design Terrain map
 • University of Heidelberg Open Map Surfer
 • NASA Blue Marble
 • our own maps
http://zat.com/talks/webvisions

     http://flightstats.com
   http://flightstats-inc.com

More Related Content

Recently uploaded

Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESmohitsingh558521
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 

Recently uploaded (20)

Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 

Featured

Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 

Featured (20)

Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 

Webvisions: When Google Maps gives you Lemons, Make Lemonade

  • 1. When Google Maps Gives You Lemons, Make Lemonade Wm Leler Flightstats Inc.
  • 2. Google Maps (the good) • 7 years old, used by 350,000 websites • Free (until recently) • Far better than what was available before • Continuously improved: • Street view, 3D buildings, traffic, routing ... • Brought map-based apps to the Internet • Enabled explosion of map mashups
  • 3. Google Maps (the bad) • Closed, proprietary system • no source • difficult to fix bugs or add features • Poor separation of maps from API • Generic, one-size-fits-all • Three basemaps: street, satellite, terrain • Automobile centric
  • 4. Google Maps (the evil) • The first one is free • Now charging heavy users • Advertising • Suppressed development of alternatives • Google owns you and controls you • V2 to V3 API bungle
  • 5.
  • 6. Maps in 3 Parts Imagery Geography Maps & Info & Routes Data Server Map Tiles, Geom, etc. • User controls Client JavaScript Map API • Loads Map Tiles Browser • Markers and annotations
  • 7. Sources of Map Data • Not free: Navteq, Navinfo, DigitalGlobe, SRTM, Planetary Visions, Google • OpenStreetMap, US Census TIGER • NASA/JPL, US Dept. of Agriculture • Natural Earth, CGIAR-CSI • any geographic source
  • 8. Rendering Map Data Map Data: roads, boundaries, names, ... Styles: colors, Zoom Render line widths, levels fonts, Tile hill shading, visibility, detail, ... Map Tiles to Serve
  • 9. Map Tiles • Slice up large maps into square pieces • Don’t have to download entire map into the browser • Enables interactivity, smooth scrolling • use AJAX calls to download tiles • lowers resource needs for browser and server, lowers bandwidth demands
  • 10. The Tao of Tiles • 256 x 256 pixels • Zoom level 0 has one tile for entire world • Longitude (x) goes from -180º to 180º • Latitude (y) goes from 85.051º to -85.051º (arctan sinh π)
  • 11. Zoom level 1 has 4 tiles number of tiles zoom = 4 1 4 =4
  • 12. Tile Explosion • City level (11) = 4,194,304 tiles • Street level (16) = 4,294,967,296 tiles • Google maps goes to level 22 = > 17 trillion tiles
  • 13. Subdomains • Browsers used to be limited to 2 network connections per domain. (Recent browsers raised limit as high as 6.) • To get around this limitation, map servers generally point multiple (3 or 4) subdomains at a single tile server. http://mt0.google.com/ http://mt1.google.com/ http://mt2.google.com/ http://mt3.google.com/
  • 14. Map Tile Servers 1. Use a public map server: • Open MapQuest, CloudMade, MapBox 2. Use someone else’s map server 3. Your own server • or cloud storage
  • 15. Open Mapquest • http://open.mapquest.com/ • OpenStreetMap, aerial, and overlay tiles • Free! • Supports high bandwidth on request • reliability is not guaranteed • Satellite imagery is seasonal!
  • 16.
  • 17. CloudMade • Has a large number of maps, or • Map Studio allows you to create your own map styles • Based on OSM data • CloudMade will host your map tiles ($) • or you can download and host yourself
  • 18.
  • 19. MapBox • TileMill allows you to create maps, using any data • not just styles • MapBox will host your tiles ($) • or you can download and host yourself • They have created a large number of maps • Can dynamically modify tiles
  • 20. Someone Else’s Server • Almost all map tile servers are unsecured • You are identified by the referrer header • OK for low volume use • No reliability guarantees • Just need to determine server URL • (except for Microsoft Bing maps)
  • 21. Map Server URLs Easy to determine URL using browser debugger Google Maps Safari Browser debugger
  • 22. Constructing Tile URLs http://mt1.google.com/vt/lyrs=m@174227760&hl=en& src=app&x=81&y=183&z=9&s=Ga subdomain column row zoom new L.TileLayer( 'http://mt{s}.google.com/vt/lyrs=m@174227760&hl=en& src=app&x={x}&y={y}&z={z}&s=Ga', { subdomains:'0123', attribution:'&copy; Google' }) • Leaflet plugs in the values for you
  • 23. Slippy Maps • “slippy” naming convention for map tiles: http://<sub>.domain.com/.../<zoom>/<x>/<y>.png http://otile1.mqcdn.com/tiles/1.0.0/osm/4/63/99.png • Tiles can be served as normal files No need for a special tile server
  • 24. MapsGL (side note) • Google has introduced MapsGL, which uses WebGL to draw streets, buildings, and other features directly in a canvas • Does not use image-based map tiles • Won’t work for satellite or other imagery • Currently works only on a few browsers • (alternatively, can use GeoJSON)
  • 25. JavaScript Map APIs • Proprietary: • Google Maps API • Mapquest, Microsoft Bing, Nokia OVI, ... • Open: • OpenLayers - http://openlayers.org/ • Leaflet - http://leaflet.cloudmade.com/ • Modest Maps - http://modestmaps.com/ • Polymaps - http://polymaps.org/ (SVG)
  • 26. Google Maps <html style="height:100%"><head> <title>Google Maps Example</title> <script src="http://maps.googleapis.com/maps/api/js? key=API_KEY&sensor=false"></script> </head><body style="height:100%;margin:0;padding:0"> <div id="map" style="width:100%; height:100%"></div> <script type="text/javascript"> var pdx = new google.maps.LatLng(45.53, -122.67); var map = new google.maps.Map( document.getElementById('map'), { center: pdx, zoom: 14, mapTypeID: google.maps.MapTypeId.ROADMAP) } ); </script> </body></html>
  • 27.
  • 28. OpenLayers <html style="height:100%"><head> <title>OpenLayers Example</title> <script src="http://openlayers.org/api/OpenLayers.js"> </script> </head><body style="height:100%;margin:0;padding:0"> <div id="map" style="width:100%; height:100%"></div> <script type="text/javascript"> var map = new OpenLayers.Map('map'); var mapnik = new OpenLayers.Layer.OSM(); map.addLayer(mapnik); var pdx = new OpenLayers.LonLat(-122.67, 45.53). transform(new OpenLayers.Projection("EPSG:4326"), map.getProjectionObject()); map.setCenter(pdx, 14); </script> </body></html>
  • 29.
  • 30. Leaflet <html style="height:100%"><head> <title>Leaflet Example</title> <link rel="stylesheet" href="leaflet.css" /> <!--[if lte IE 8]><link rel="stylesheet" href="leaflet.ie.css" /><![endif]--> <script type="text/javascript" src="leaflet.js"></script> </head><body style="height:100%;margin:0;padding:0"> <div id="map" style="height: 100%;width:100%"></div> <script type="text/javascript"> var map = new L.Map('map'); var tiles = new L.TileLayer( 'http://mt{s}.google.com/vt/v=w2.106&x={x}&y={y}&z={z}&s=', { subdomains:'0123', attribution:'&copy; Google 2011' }); var pdx = new L.LatLng(45.58961, -122.592121); map.addLayer(tiles).setView(pdx, 14); </script> </body></html>
  • 31.
  • 32. What should you do? • Just want to put a simple map on a web page or blog post? • Keep using Google Maps (or Bing, OVI, MapQuest, etc.), especially if you need traffic data • Use a static image of a map • Mapbox Embed (no JavaScript!) - http://mapbox.com/hosting/embedding/
  • 33. If you want more • More Flexibility • Leaflet with Open MapQuest • CloudMade or MapBox • More volume • your hosting on cloud • open (CC) maps (or your own)
  • 34. http://rtp.trimet.org/ • Multi-modal regional trip planner • car, bus, light rail, streetcar, trolley, commuter train, aerial tram, bicycle, walk • Open data allows customization • OpenLayers software on the browser • Open Mapquest servers, OpenStreetMap • Developing their own map
  • 35.
  • 36. Foursquare • Leaflet on the browser • Mapbox servers (paid) • Mapbox “Streets” map (based on OSM data)
  • 37. Flightstats • Leaflet • Amazon S3 and CloudFront servers • various open maps: • Stamen Design Terrain map • University of Heidelberg Open Map Surfer • NASA Blue Marble • our own maps
  • 38. http://zat.com/talks/webvisions http://flightstats.com http://flightstats-inc.com

Editor's Notes

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n
  26. \n
  27. \n
  28. \n
  29. \n
  30. \n
  31. \n
  32. \n
  33. \n
  34. \n
  35. \n
  36. \n
  37. \n
  38. \n