<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Maratis forum - How to check object visibility?]]></title>
	<link rel="self" href="http://forum.maratis3d.com/extern.php?action=feed&amp;tid=894&amp;type=atom"/>
	<updated>2013-12-15T08:26:58Z</updated>
	<generator>PunBB</generator>
	<id>http://forum.maratis3d.com/viewtopic.php?id=894</id>
		<entry>
			<title type="html"><![CDATA[Re: How to check object visibility?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6085#p6085"/>
			<content type="html"><![CDATA[<p><strong>com3D</strong>, yeah. Thanks.<br />I thinked that IsVisible return reverse value of &quot;Invisible&quot;-attribute<br /><span class="postimg"><img src="http://sgeproject.narod.ru/pics/Maratis/invisible.jpg" alt="http://sgeproject.narod.ru/pics/Maratis/invisible.jpg" /></span><br />But it&#039;s my mistake <img src="http://forum.maratis3d.com/img/smilies/smile.png" width="15" height="15" alt="smile" /></p><p>P.S. He-he, I look to engine-code. Visible check use described above algorythm with BBox <img src="http://forum.maratis3d.com/img/smilies/smile.png" width="15" height="15" alt="smile" /></p>]]></content>
			<author>
				<name><![CDATA[Aikon]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2730</uri>
			</author>
			<updated>2013-12-15T08:26:58Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6085#p6085</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: How to check object visibility?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6084#p6084"/>
			<content type="html"><![CDATA[<p>In lua you can use the isVisible(object) function.</p>]]></content>
			<author>
				<name><![CDATA[com3D]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=1488</uri>
			</author>
			<updated>2013-12-15T06:26:10Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6084#p6084</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[How to check object visibility?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6083#p6083"/>
			<content type="html"><![CDATA[<p>I need to detect events - &quot;object appear on screen&quot; and &quot;object dissapear from screen&quot;.<br />Can you advise the best way to do this?</p><p>Currently my plan is check object-visible in onSceneUpdate() by next algorythm:<br />1. Find camera look direction =&gt; vec3_A<br />2. Find vector from cameraPosition to objectPosition (center) =&gt; vec3_B<br />3. Find angles between vec3_A and vec3_B and compare with angles defined by camera fov/screen width and height.<br />It&#039;s a dirty algorythm with &quot;unknow visible state&quot; zone and can be improved by cheking all BBox-vertices (inaccessible yet) instead of center.<br />P.S. I don&#039;t need accurate detection.<br />P.P.S. Next step is visible level, e.g. 1 - object under cursor +-, 0.8 - object near cursor, 0.4 - object near screen border, 0 - object invisible.</p>]]></content>
			<author>
				<name><![CDATA[Aikon]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2730</uri>
			</author>
			<updated>2013-12-14T20:21:38Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6083#p6083</id>
		</entry>
</feed>
