<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Infinity Code Forum — Troubles when zooming]]></title>
	<link rel="self" href="https://forum.infinity-code.com/extern.php?action=feed&amp;tid=920&amp;type=atom" />
	<updated>2018-10-22T21:58:55Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.infinity-code.com/viewtopic.php?id=920</id>
		<entry>
			<title type="html"><![CDATA[Re: Troubles when zooming]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=4072#p4072" />
			<content type="html"><![CDATA[<p>p.y *= OnlineMaps.instance.transform.localScale.x;</p><p>It did the trick ! Thanks a lot.</p><p>I will consider using Online Maps v3 beta after my next dead-line</p>]]></content>
			<author>
				<name><![CDATA[Thibault]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=821</uri>
			</author>
			<updated>2018-10-22T21:58:55Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=4072#p4072</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: Troubles when zooming]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=4070#p4070" />
			<content type="html"><![CDATA[<p>In Online Maps v2 only smooth zoom emulation, which is achieved by scaling the map GameObject. <br />This means that in fact it does not change the corners of the map.</p>]]></content>
			<author>
				<name><![CDATA[Alex Vertax]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=2</uri>
			</author>
			<updated>2018-10-22T18:59:45Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=4070#p4070</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: Troubles when zooming]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=4069#p4069" />
			<content type="html"><![CDATA[<p>So after a deeper investigation, i noticed that there is no problem when my LineRenderer points have an altitude of 0.</p><p>The unwanted behaviour must be the result of this particular line in the GetWorldPositionWithAltitude function:</p><p>float yScale = control.GetBestElevationYScale(tlx, tly, brx, bry); </p><p>With tlx,tly,brx and bry beeing the result of map.GetCorners(out tlx, out tly, out brx, out bry);</p><p>I supposed that the corner of the map are not updated when the zoom is &quot;in progress&quot; between two levels so i tried to call &quot;OnlineMaps.instance.UpdateCorners();&quot; before trying to call &quot;map.GetCorners&quot; but it didn&#039;t solve my problem <img src="https://forum.infinity-code.com/img/smilies/hmm.png" width="15" height="15" alt="hmm" /></p>]]></content>
			<author>
				<name><![CDATA[Thibault]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=821</uri>
			</author>
			<updated>2018-10-22T18:51:55Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=4069#p4069</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: Troubles when zooming]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=4068#p4068" />
			<content type="html"><![CDATA[<p>Hello.</p><p>If you are working with a smooth zoom, I highly recommend you try Online Maps v3 beta.<br />Online Maps v3 has a built-in float zoom, and it will be MUCH easier to solve your problem.</p><p>To make it work in Online Maps v2, you need in GetWorldPositionWithAltitude to multiply p and transform.localScale.x of the map.</p>]]></content>
			<author>
				<name><![CDATA[Alex Vertax]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=2</uri>
			</author>
			<updated>2018-10-22T18:43:26Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=4068#p4068</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Troubles when zooming]]></title>
			<link rel="alternate" href="https://forum.infinity-code.com/viewtopic.php?pid=4063#p4063" />
			<content type="html"><![CDATA[<p>Hi</p><p>I have a lineRenderer. It does redraw when the event OnlineMapsTileSetControl.OnMeshUpdated occurs, which allow me to keep it in the correct position when moving the map.</p><p>But, when i&#039;m zooming &quot;too much&quot; (when i&#039;m beyong the max zoom level -&gt; i use an android tablet so as long as i don&#039;t release my finger when zooming i can go beyong the max zoom level) the lineRenderer is in an incorrect position. </p><p>As i don&#039;t want to wait for the user to release his finger to draw my lines in the correct position, i tried to use OnlineMapsTileSetControl.OnSmoothZoomProcess to update the lineRenderer constantly when zooming.</p><p>But it doesn&#039;t solve my problem.</p><p>OnlineMapsTileSetControl.OnSmoothZoomProcess is working though. (i can see my Debug.Log messages as long as i don&#039;t release my fingers).</p><p>Here is a GIF for a better understanding of the situation: </p><p><a href="https://gph.is/2AmbZBs">https://gph.is/2AmbZBs</a></p><p>What am i missing ?</p>]]></content>
			<author>
				<name><![CDATA[Thibault]]></name>
				<uri>https://forum.infinity-code.com/profile.php?id=821</uri>
			</author>
			<updated>2018-10-22T14:56:35Z</updated>
			<id>https://forum.infinity-code.com/viewtopic.php?pid=4063#p4063</id>
		</entry>
</feed>
