<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[Infinity Code Forum — Mesh created at runtime, attached to a 3D marker, strange behavior]]></title>
		<link>https://forum.infinity-code.com/viewtopic.php?id=923</link>
		<atom:link href="https://forum.infinity-code.com/extern.php?action=feed&amp;tid=923&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in Mesh created at runtime, attached to a 3D marker, strange behavior.]]></description>
		<lastBuildDate>Thu, 25 Oct 2018 20:41:21 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Mesh created at runtime, attached to a 3D marker, strange behavior]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=4103#p4103</link>
			<description><![CDATA[<p>So the problem was that i forgot to call &quot;Mesh.RecalculateBounds&quot; </p><p><a href="https://docs.unity3d.com/ScriptReference/Mesh.RecalculateBounds.html">https://docs.unity3d.com/ScriptReferenc … ounds.html</a></p><p>The documentation says &quot;Assigning triangles automatically recalculates the bounding volume.&quot; which is why i usually don&#039;t call this function when i&#039;m creating meshes at runtime. But in this case i&#039;m modifying vertices after having set the triangles.</p><p>I feel stupid but it works properly now <img src="https://forum.infinity-code.com/img/smilies/smile.png" width="15" height="15" alt="smile" /></p>]]></description>
			<author><![CDATA[null@example.com (Thibault)]]></author>
			<pubDate>Thu, 25 Oct 2018 20:41:21 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=4103#p4103</guid>
		</item>
		<item>
			<title><![CDATA[Re: Mesh created at runtime, attached to a 3D marker, strange behavior]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=4098#p4098</link>
			<description><![CDATA[<p>Hello.</p><p>I looked at your gif many times ... and I have no idea why this is happening.<br />If you send your project to us (support@infinity-code.com) I will be able to test it and tell you the exact cause of the problem.<br />Unfortunately, in this case, only using gif I can not do it.</p>]]></description>
			<author><![CDATA[null@example.com (Alex Vertax)]]></author>
			<pubDate>Wed, 24 Oct 2018 19:40:45 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=4098#p4098</guid>
		</item>
		<item>
			<title><![CDATA[Mesh created at runtime, attached to a 3D marker, strange behavior]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=4095#p4095</link>
			<description><![CDATA[<p>Hi</p><p>I made a prefab (named &quot;frustum&quot;) with an empty Gameobject containing a script, which create a mesh. This mesh is displaying properly in a regular empty scene.</p><p>I attached this prefab as a child to another prefab which i am using as a 3D marker in my scene with the map.</p><p>It doesn&#039;t display properly (see the GIF below). </p><p>I believed at first that i didn&#039;t code properly the mesh creation (particularly the normals) but i made a test :&nbsp; <br />If i manually add the frustum prefab in my scene at runtime, and make it a child of my 3D marker prefab manually, it display properly.</p><p>See the Gif below: <br />you will first see the &quot;frustum&quot; prefab not displaying properly.<br />Then i disable it and enable the &quot;frustum2&quot; prefab (that i manually added at runtime) <br />you will see that there is no problem with this one.</p><p><a href="https://media.giphy.com/media/5w2ejH86oVeMZd0ZvQ/giphy.gif">https://media.giphy.com/media/5w2ejH86o … /giphy.gif</a></p><p>You will find the script of the mesh creation attach to this message, though i don&#039;t think it is the problem anymore.</p><p>So one solution i have is problably to instantiate the frutum prefab separatly and assign it as a child of my drone prefab via script, but i would prefer to keep it as a part of the drone prefab if it is possible. Do you have any idea of what could occur this strange behavior ?</p>]]></description>
			<author><![CDATA[null@example.com (Thibault)]]></author>
			<pubDate>Wed, 24 Oct 2018 19:10:24 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=4095#p4095</guid>
		</item>
	</channel>
</rss>
