<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Infinity Code Forum — geojson data layer over map]]></title>
	<link rel="self" href="https://forum.infinity-code.com/extern.php?action=feed&amp;tid=535&amp;type=atom" />
	<updated>2017-05-12T00:16:44Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.infinity-code.com/viewtopic.php?id=535</id>
		<entry>
			<title type="html"><![CDATA[Re: geojson data layer over map]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=2335#p2335" />
			<content type="html"><![CDATA[<p>thank you for your help! that worked a treat</p>]]></content>
			<author>
				<name><![CDATA[stiffy89]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=453</uri>
			</author>
			<updated>2017-05-12T00:16:44Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=2335#p2335</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: geojson data layer over map]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=2327#p2327" />
			<content type="html"><![CDATA[<p>Hello.</p><p>Example:<br /></p><div class="codebox"><pre><code>using System;
using System.Collections.Generic;
using UnityEngine;

public class GeoJSONExample : MonoBehaviour
{
    private void Start()
    {
        OnlineMapsUtils.GetWWW(&quot;https://storage.googleapis.com/mapsdevsite/json/google.json&quot;).OnComplete += OnComplete;
    }

    private void OnComplete(OnlineMapsWWW www)
    {
        OnlineMapsJSONItem json = OnlineMapsJSON.Parse(www.text);
        OnlineMapsJSONItem geometries = json[&quot;features/*/geometry/coordinates&quot;];
        foreach (OnlineMapsJSONItem geometry in geometries)
        {
            List&lt;double&gt; points = new List&lt;double&gt;();
            foreach (OnlineMapsJSONItem geometryPoints in geometry)
            {
                foreach (OnlineMapsJSONItem point in geometryPoints)
                {
                    points.Add(point[0].Value&lt;double&gt;());
                    points.Add(point[1].Value&lt;double&gt;());
                }
            }
            OnlineMapsDrawingPoly poly = new OnlineMapsDrawingPoly(points, Color.red);
            OnlineMaps.instance.AddDrawingElement(poly);
        }
    }
}</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Alex Vertax]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=2</uri>
			</author>
			<updated>2017-05-08T23:49:35Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=2327#p2327</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[geojson data layer over map]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=2324#p2324" />
			<content type="html"><![CDATA[<p>Hey guys,</p><p>Im new to unity and to Onlinemaps so im a little unsure with this question but i was wondering if there is a way to import geojson data to overlay the map? Similar to the data layer within google javascript maps, ive posted a link below</p><p><a href="https://developers.google.com/maps/documentation/javascript/datalayer">https://developers.google.com/maps/docu … /datalayer</a></p><p>if anyone is able to help me with this topic, id really appreciate it!</p><p>Regards</p>]]></content>
			<author>
				<name><![CDATA[stiffy89]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=453</uri>
			</author>
			<updated>2017-05-08T11:13:29Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=2324#p2324</id>
		</entry>
</feed>
