<?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/9382" />

	<title>Real-Time Physics Simulation Forum</title>
	
	<link href="https://pybullet.org/Bullet/phpBB3/index.php" />
	<updated>2013-08-30T11:25:18+00:00</updated>

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

		<entry>
		<author><name><![CDATA[Gickl]]></name></author>
		<updated>2013-08-30T11:25:18+00:00</updated>

		<published>2013-08-30T11:25:18+00:00</published>
		<id>https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=31646#p31646</id>
		<link href="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=31646#p31646"/>
		<title type="html"><![CDATA[CustomMaterialCombinerCallback -&gt; conveyor belt effect]]></title>

		
		<content type="html" xml:base="https://pybullet.org/Bullet/phpBB3/viewtopic.php?p=31646#p31646"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>static bool CustomMaterialCombinerCallback(btManifoldPoint&amp; cp,   const btCollisionObject* colObj0,int partId0,int index0,const btCollisionObject* colObj1,int partId1,int index1){   cp.m_lateralFrictionInitialized = true;   cp.m_lateralFrictionDir1.setValue(1,0,0);   ///downscale the friction direction 2 for lower (anisotropic) friction (rather than a unit vector)   cp.m_lateralFrictionDir2.setValue(0,0,0.1);   ///choose a target surface velocity in the friction dir1 direction, for a conveyor belt effect   cp.m_contactMotion1 = 1.f;   //cp.m_contactMotion1 = 1.f;   //cp.m_contactCFM2 = 0.1;   //cp.m_combinedFriction = 10;   //cp.m_combinedRestitution = calculateCombinedRestitution(restitution0,restitution1);   return true;}</code></pre></div>Hi,<br><br>the code above was posted a few years ago and it should have the effect of a conveyor belt (see <a href="http://www.bulletphysics.org/Bullet/phpBB3/viewtopic.php?f=9&amp;t=3555&amp;p=15751&amp;hilit=conveyor+belt+effect+porting#p15751" class="postlink">http://www.bulletphysics.org/Bullet/php ... ing#p15751</a>). Erwin posted a modified version of the BasicDemo.cpp where the callback is included. There I can achieve that all the boxes drift to the right like on a conveyor belt. but when i try to change the direction of the movement by modifying the two friction directions i get odd behaviour. sometimes the boxes drift in two opposite directions and other times they drift in all directions for example.<br><br>so my problem is that i don't know exactly what the parameters and especially the two friction directions effect. can someone tell me what the friction directions exactly do? and perhaps what the other parameters are for?<br>i thought that the comments explain enough. but it seems that it isn't that easy...<br><br>i would be very happy!<br><br>Thank you<br>Gickl<p>Statistics: Posted by <a href="https://pybullet.org/Bullet/phpBB3/memberlist.php?mode=viewprofile&amp;u=9361">Gickl</a> — Fri Aug 30, 2013 11:25 am</p><hr />
]]></content>
	</entry>
	</feed>
