Physics Simulation Forum

 

All times are UTC




Post new topic Reply to topic  [ 4 posts ] 
Author Message
PostPosted: Sat May 12, 2007 9:37 pm 
Offline

Joined: Sat May 12, 2007 9:30 pm
Posts: 5
Does it make sense, that when I set the localScaling of a btConvexTriangleMeshShape it will store the scaling by calling m_stridingMesh->setScaling(scaling); but when I call getLocalScaling on the btConvexTriangleMeshShape I will get the member variable m_localScaling from the btConvexShape class?

In this case these values are not equal!


Top
 Profile  
 
 Post subject: Another confusion
PostPosted: Sun May 13, 2007 8:01 am 
Offline

Joined: Sat May 12, 2007 9:30 pm
Posts: 5
Another curiosity is in btBvhTriangleMeshShape::setLocalScaling:

within this method btTriangleMeshShape::setLocalScaling is called which recalculates m_localAabbMin and m_localAabbMax. But after this recalculation these two variables are multiplicated with the given scaling again which results in a quadratic scaling, e.g. when specifying a scale of 3 the m_localAabbMin and -Max has a scale of 9.


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 13, 2007 4:15 pm 
Offline

Joined: Sat May 12, 2007 9:30 pm
Posts: 5
And again some confusion.

The getScaling of the btMatrix3x3 seems to return the squared scaling instead of the real scaling. Perhaps this should be mentioned in the documentation.


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 13, 2007 5:35 pm 
Offline
Site Admin
User avatar

Joined: Sun Jun 26, 2005 6:43 pm
Posts: 3744
Location: California, USA
This local scaling issue will be fixed for convex and concave triangle meshes.
Note that not all shapes support local non-uniform scaling, in particar btSphereShape. If you want a non-uniform scaled sphere, you need to use btMultiSphereShape.

Scaling functionality should have been removed from transforms (btTransform) and this remainder will be removed from btMatrix3x3.

Thanks for the feedback!
Erwin


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC


Who is online

Users browsing this forum: Bing [Bot] and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group