mirror of
https://github.com/bulletphysics/bullet3
synced 2024-12-16 14:40:05 +00:00
commit
4afe403e35
@ -234,7 +234,7 @@ bool Bullet2MultiBodyDemo::mouseButtonCallback(int button, int state, float x, f
|
||||
btPoint2PointConstraint* p2p = new btPoint2PointConstraint(*body,localPivot);
|
||||
m_dynamicsWorld->addConstraint(p2p,true);
|
||||
m_pickedConstraint = p2p;
|
||||
btScalar mousePickClamping = 30.f;
|
||||
btScalar mousePickClamping = 10.f;
|
||||
p2p->m_setting.m_impulseClamp = mousePickClamping;
|
||||
//very weak constraint for picking
|
||||
p2p->m_setting.m_tau = 0.001f;
|
||||
@ -256,7 +256,7 @@ bool Bullet2MultiBodyDemo::mouseButtonCallback(int button, int state, float x, f
|
||||
//so we try to avoid it by clamping the maximum impulse (force) that the mouse pick can apply
|
||||
//it is not satisfying, hopefully we find a better solution (higher order integrator, using joint friction using a zero-velocity target motor with limited force etc?)
|
||||
|
||||
p2p->setMaxAppliedImpulse(20*scaling);
|
||||
p2p->setMaxAppliedImpulse(2*scaling);
|
||||
|
||||
btMultiBodyDynamicsWorld* world = (btMultiBodyDynamicsWorld*) m_dynamicsWorld;
|
||||
world->addMultiBodyConstraint(p2p);
|
||||
|
@ -19,7 +19,7 @@
|
||||
using namespace Gwen::Controls;
|
||||
|
||||
|
||||
Canvas::Canvas( Gwen::Skin::Base* pSkin ) : BaseClass( NULL ), m_bAnyDelete( false )
|
||||
Canvas::Canvas( Gwen::Skin::Base* pSkin ) : BaseClass( NULL ), m_bAnyDelete( false ),m_fScale(-1)
|
||||
{
|
||||
SetBounds( 0, 0, 10000, 10000 );
|
||||
SetSkin( pSkin );
|
||||
|
Loading…
Reference in New Issue
Block a user