{"id":4063,"date":"2015-02-03T12:14:07","date_gmt":"2015-02-03T03:14:07","guid":{"rendered":"https:\/\/gunmagisgeek.com\/wordpress\/?p=4063"},"modified":"2017-02-03T01:19:54","modified_gmt":"2017-02-02T16:19:54","slug":"post-4063","status":"publish","type":"post","link":"https:\/\/gunmagisgeek.com\/blog\/google-map-api\/4063","title":{"rendered":"\u5730\u56f3\u4e0a\u306b\u30b0\u30ea\u30c3\u30c9\u3092\u66f8\u3044\u3066\u8272\u5857\u308a(\u6a21\u7d22\u4e2d)"},"content":{"rendered":"<p><a href=\"http:\/\/shimz.me\/example\/gmapv3\/gridjson\/\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/gunmagisgeek.com\/blog\/wp-content\/uploads\/2015\/02\/gmapgrid140203.jpg\" alt=\"Google Maps GeoJSON Grid\" width=\"690\" height=\"365\" class=\"aligncenter size-full wp-image-4065 border\" srcset=\"https:\/\/gunmagisgeek.com\/blog\/wp-content\/uploads\/2015\/02\/gmapgrid140203.jpg 690w, https:\/\/gunmagisgeek.com\/blog\/wp-content\/uploads\/2015\/02\/gmapgrid140203-284x150.jpg 284w\" sizes=\"auto, (max-width: 690px) 100vw, 690px\" \/><\/a><\/p>\n<p><a href=\"http:\/\/shimz.me\/example\/gmapv3\/gridjson\/\">example<\/a><\/p>\n<p>100m \u00d7 100m\u306e\u30b0\u30ea\u30c3\u30c9\u3092Google Maps\u4e0a\u306b\u8868\u793a\u3057\u3066\u3001\u5404\u30bb\u30eb\u3092\u30e9\u30f3\u30c0\u30e0\u306b\u8272\u5857\u308a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u5730\u56f3\u4e0a\u306b\u30b0\u30ea\u30c3\u30c9\u3092\u8868\u793a\u3059\u308b\u306b\u306f\u3044\u304f\u3064\u304b\u9078\u629e\u80a2\u304c\u3042\u3063\u3066\u3001\u300c\u30b0\u30ea\u30c3\u30c9\u3092\u305d\u3082\u305d\u3082\u30c7\u30fc\u30bf\u3068\u3057\u3066\u7528\u610f\u3057\u3066\u304a\u304f or \u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u5074\u3067\u8a08\u7b97\u3057\u3066\u63cf\u753b\u3059\u308b\u300d\u3068\u3044\u3046\uff12\u7a2e\u985e\u306e\u65b9\u6cd5\u304c\u3042\u308a\u3001\u3055\u3089\u306b\u3001\u300c\u30b0\u30ea\u30c3\u30c9\u3092\u30e9\u30a4\u30f3(\u7dda)\u3068\u3057\u3066\u63cf\u304f or \u30dd\u30ea\u30b4\u30f3(\u9762)\u3068\u3057\u3066\u63cf\u304f\u300d\u306e\uff12\u7a2e\u985e\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f<a href=\"http:\/\/qgis.org\/ja\/site\/\">QGIS<\/a>\u3092\u4f7f\u3063\u3066\u30dd\u30ea\u30b4\u30f3\u306e\u30b0\u30ea\u30c3\u30c9\u30ec\u30a4\u30e4\u30fc\u3092\u4f5c\u6210\u3057\u3001GeoJSON\u3068\u3057\u3066\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3057\u3066\u3001\u30e9\u30f3\u30c0\u30e0\u306b\u8272\u5857\u308a\u3057\u3066\u307f\u307e\u3057\u305f\u3002<br \/>\n\u30dd\u30ea\u30b4\u30f3\u3060\u3068\u5404\u30bb\u30eb\u306b\u5c5e\u6027\u5024\u304c\u3064\u304f\u306e\u3067\u8272\u5857\u308a\u3057\u3084\u3059\u304b\u3063\u305f\u308a\u3001\u4ed6\u306b\u3082\u3044\u308d\u3044\u308d\u4f7f\u3044\u3084\u3059\u304b\u3063\u305f\u308a(\u4f8b\u3048\u3070\u3001\u3042\u308b\u7279\u5b9a\u306e\u30bb\u30eb\u306b\u542b\u307e\u308c\u308b\u30dd\u30a4\u30f3\u30c8\u3092\u62bd\u51fa\u3059\u308b\u3068\u304b\uff09\u3059\u308b\u306e\u3067\u3059\u304c\u3001\u30b0\u30ea\u30c3\u30c9\u3092\u8868\u793a\u3059\u308b\u7bc4\u56f2\u304c\u5e83\u304f\u306a\u308b\u3068\u3081\u3063\u3061\u3083\u91cd\u304f\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u8aad\u307f\u8fbc\u3093\u3060\u30c7\u30fc\u30bf\u3092<a href=\"https:\/\/github.com\/mapbox\/geojson-vt\">geojson-vt<\/a>\u3092\u4f7f\u3063\u3066\u30bf\u30a4\u30eb\u5316\u3059\u308b\u3068\u304b\u3001<span class=\"removed_link\" title=\"http:\/\/turfjs.org\/static\/docs\/module-turf_grid.html\">truf.js\u306egird\u30e1\u30bd\u30c3\u30c9<\/span>\u3092\u5229\u7528\u3057\u3066\u305d\u3082\u305d\u3082\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u5074\u3067\u8868\u793a\u3055\u308c\u3066\u3044\u308b\u7bc4\u56f2\u3060\u3051\u63cf\u753b\u3059\u308b\u3068\u304b\u4f7f\u7528\u7528\u9014\u306b\u5408\u308f\u305b\u3066\u4f7f\u3044\u5206\u3051\u308b\u5fc5\u8981\u304c\u3042\u308b\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u3002<\/p>\n<p>\u4ed6\u306e\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306f\u3001\u307e\u305f\u3044\u305a\u308c\u8a66\u3057\u3066\u307f\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<h2>\u30b0\u30ea\u30c3\u30c9\u30c7\u30fc\u30bf\u306e\u4f5c\u6210<\/h2>\n<p>QGIS\u306e\u300c\u30d9\u30af\u30bf\u300d\u30e1\u30cb\u30e5\u30fc\u304b\u3089\u300c\u8abf\u67fb\u30c4\u30fc\u30eb\u2192\u30d9\u30af\u30bf\u30b0\u30ea\u30c3\u30c9\u300d\u3092\u9078\u629e\u3057\u3066\u30b0\u30ea\u30c3\u30c9\u3092\u4f5c\u6210\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>[\u53c2\u8003]<br \/>\n\u30fb<span class=\"removed_link\" title=\"http:\/\/www.geopacific.org\/opensourcegis\/gcngisbook\/QGIS_book\/4ed89332b\/fqdipz\">\u30d9\u30af\u30bf\u89e3\u6790\u6a5f\u80fd \u2014 GeoPacific.org<\/span><br \/>\n\u30fb<a href=\"http:\/\/www.gis-okinawa.jp\/QGIS\/doc6202\/index.html\">\u30b0\u30ea\u30c3\u30c9\u7dda\u30fb\u30dd\u30ea\u30b4\u30f3\u3092\u751f\u6210<\/a><\/p>\n<p>\u4f5c\u6210\u3057\u305f\u30d9\u30af\u30bf\u30fc\u30ec\u30a4\u30e4\u30fc\u3092GeoJSON\u3068\u3057\u3066\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3057Google Maps\u4e0a\u306b\u8868\u793a\u3057\u307e\u3059\u3002<\/p>\n<h3>\u30b0\u30ea\u30c3\u30c9\u306e\u8868\u793a<\/h3>\n<pre class=\"lang:js decode:true \" >google.maps.event.addDomListener(window, 'load', function() {\r\n\t\/\/Google Maps API\u521d\u671f\u5316\r\n\tvar map = new google.maps.Map(document.getElementById('map-canvas'), {\r\n\t\tcenter: { lat: 36.3894816, lng: 139.0634281 },\r\n\t\tzoom: 16\r\n\t});\r\n\r\n\t\/\/\u30ab\u30e9\u30fc\u8a2d\u5b9a\r\n\tcolorArray = [\"#faa\", \"#aaf\", \"#afa\"];\r\n\t\r\n\t\/\/\u30dd\u30ea\u30b4\u30f3\u30c7\u30fc\u30bf\u306e\u30b9\u30bf\u30a4\u30eb\u3092\u6307\u5b9a\r\n\tvar styleFeature =  function(feature){\r\n\t\treturn {\r\n\t\t\tstrokeWeight: 0.5,\r\n\t\t\tstrokeColor: 'black',\r\n\t\t\tzIndex: 4,\r\n\t\t\tfillColor: colorArray[Math.floor(Math.random() * 4)],\u3000\/\/\u3068\u308a\u3042\u3048\u305a\u30e9\u30f3\u30c0\u30e0\r\n\t\t\tfillOpacity: 0.3,\r\n\t\t\tvisible: true\r\n\t\t};\t\t\r\n\t}\r\n\t\r\n\t\r\n\t\/\/grid\u30c7\u30fc\u30bf\u3092\u8aad\u307f\u8fbc\u307f\r\n\td3.json('grid.geojson', function(json) {\t\t\r\n\t\t\/\/\u30c7\u30fc\u30bf\u30ec\u30a4\u30e4\u30fc\u306b\u8ffd\u52a0\r\n\t\tmap.data.addGeoJson(json);\r\n\t\t\/\/\u30c7\u30fc\u30bf\u30ec\u30a4\u30e4\u306e\u30b9\u30bf\u30a4\u30eb\u3092\u6307\u5b9a\r\n\t\tmap.data.setStyle(styleFeature);\r\n\t});\r\n   \r\n});\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>example 100m \u00d7 100m\u306e\u30b0\u30ea\u30c3\u30c9\u3092&hellip;<\/p>\n","protected":false},"author":1,"featured_media":4065,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[37],"tags":[],"class_list":["post-4063","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-google-map-api","has-post-thumbnail-archive"],"_links":{"self":[{"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/posts\/4063","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/comments?post=4063"}],"version-history":[{"count":0,"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/posts\/4063\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/media\/4065"}],"wp:attachment":[{"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/media?parent=4063"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/categories?post=4063"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gunmagisgeek.com\/blog\/wp-json\/wp\/v2\/tags?post=4063"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}