<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://pybullet.org/Bullet/phpBB3/app.php/feed/topic/8385" />

	<title>Real-Time Physics Simulation Forum</title>
	
	<link href="https://pybullet.org/Bullet/phpBB3/index.php" />
	<updated>2012-08-26T05:24:49+00:00</updated>

	<author><name><![CDATA[Real-Time Physics Simulation Forum]]></name></author>
	<id>https://pybullet.org/Bullet/phpBB3/app.php/feed/topic/8385</id>

		<entry>
		<author><name><![CDATA[quiasmo]]></name></author>
		<updated>2012-08-26T05:24:49+00:00</updated>

		<published>2012-08-26T05:24:49+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=28631#p28631</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=28631#p28631"/>
		<title type="html"><![CDATA[Voluemtric Raycasting]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=28631#p28631"><![CDATA[
Dear Scientists and Physics Fans,<br><br>I have written a volumetric raycast class that uses a cylinder shape to perform contact tests with collision objects.<br><br>This is working fine for me except for the following two things:<br><br>1. The collision normal for each point I get is often unusable because world::contactTest generates a normals spanning outwards from the testing cylinder instead of outward from the colliding object ( and most of my objects are scaled triangular meshes )<br><br>2. Using world::contactTest is understandably expensive and has a significant toll on performance.<br><br>I use this test for two things in my application.<br><br>1. The first is for interaction tests originating from touch devices, which don't have the pixel perfect precision a mouse pointer has. <br>It seemed to me that mapping touches to volumetric raycasting of cylinders or cones was a sensible approach. <br><br>2. The second use is much more specific to my simulation, but it regards simulating tangling strings under tension. <br>I test string/object collisions using this method.<br><br>Here are my initial takes on these two issues:<br><br>The way I've imagined solving the accuracy of the collision normal is by replacing the cast cylinder/cone with custom shape and create a new collision algorithm which handles the collision and calculates the normals as needed.<br><br>Regarding performance issues, I'm absolutely in the dark as to a way of lightening the performance hit. <br>Drilling down in my profiler call tree,  the bulk performance hit happens here:<div class="codebox"><p>Code: </p><pre><code>btGjkPairDetector::getClosestPointsNonVirtual(btDiscreteCollisionDetectorInterface::ClosestPointInput const&amp;, btDiscreteCollisionDetectorInterface::Result&amp;, btIDebugDraw*)</code></pre></div>This is at the core of the world::contactTest<br><br>I would love to hear your insight on ways of making this an accurate and/or fast test or perhaps better ways of solving this problem.<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=8158">quiasmo</a> — Sun Aug 26, 2012 5:24 am</p><hr />
]]></content>
	</entry>
	</feed>
