Commit Graph

447 Commits

Author SHA1 Message Date
erwin.coumans
8be5172df5 fix issue in the recent SSE implementation of setInterpolate3
align class
2012-09-17 16:03:47 +00:00
erwin.coumans
22fb7d5c1e improve rolling friction using anisotropic direction, to avoid resting in an instable position
(for implicit capsule, cylinder and cone shape)
See Bullet/Demos/RollingFrictionDemo for an example
2012-09-16 17:01:25 +00:00
erwin.coumans
7eebb79ced implemented rolling friction, using a contact constraint. Useful to get rolling spheres to rest, even on a slightly sloped plane.
See http://www.youtube.com/watch?v=RV7sBAsKu4M and Bullet/Demos/RollingFrictionDemo
Fixes in FractureDemo (mouse picking constraint needs to be removed, otherwise constraint solver crashes/asserts)
2012-09-15 06:52:17 +00:00
erwin.coumans
54744b6ab9 added gyroscopic force option for btRigidBody, body->setFlags(BT_ENABLE_GYROPSCOPIC_FORCE);
Note that it can easily introduce instability at regular (60Hertz) simulation steps so it is generally best to not use the option.
If needed, use a very small internal step, such as 1000 Hertz (world->stepSimulation(dt,100,1./1000.f); or stepSimulation(1./1000.,0);
2012-09-14 21:39:48 +00:00
erwin.coumans
3e9f35c0fd Add btGearConstraint, with a demo in Bullet/Demos/ConstraintDemo
Thanks to Dimitris Papavasiliou for the idea.
2012-09-13 22:40:39 +00:00
erwin.coumans
4eb5240cbe Applied patch for character controller by bjorn.wesen. Fixes Issue 644.
Fixed some warnings in double-precision compile
2012-09-11 04:36:57 +00:00
erwin.coumans
8c56528a79 Avoid using restitution for ccd motion clamping. Restitution for fast moving objects should be handled by btDiscreteDynamicsWorld::createPredictiveContacts
(make sure to merge islands based on those predictive contacts too, added some check in the solver)
This fixes Issue 356.
Use same solver settings for AllBulletDemos
Make sure to embed the setCcdSweptSphereRadius inside the actual collision shape (for shoot box)
2012-09-11 03:12:32 +00:00
erwin.coumans
9612561113 add btDiscreteDynamicsWorld::createPredictiveContacts after discrete collision detection and add temporary contact manifolds, for the constraint solver.
This should improve 'ccd' handling when using world->getDispatchInfo().m_useContinuous = true;body->setCcdSquareMotionThreshold(...); body->setCcdSquareMotionThreshold(...)
shoot smaller boxes (test)
use yellow instead of orange for contact point normals
tweak default erp and erp2 values, now split impulse is on by default (need to check it)
2012-09-11 00:56:11 +00:00
erwin.coumans
3b83428a7f Applied polar decomposition patch. Fixes Issue 621. Thanks to Christian for the report, Joshua for the fix, Dongsoo for checking the fix.
Applied picking cloth patch. Fixes Issue 646. Thanks to Dongsoo.
Applied patch Softbody updateConstraints. Fixes Issue 503. Thanks to Dave Bruce Phillips and Dongsoo.
Fix various warnigns under Mac OSX.
2012-09-09 17:22:30 +00:00
erwin.coumans
b69c6ac3f5 fix padding in btSolverConstraint, see Issue 650
fix some warnings
2012-09-08 19:21:14 +00:00
erwin.coumans
196aa20329 add m_splitImpulseTurnErp solver setting, initialized to 0.1: more stable recovery from deeper penetrations by reducing the angular effect (if split impulse is enabled)
Set it to 1.0 to disable the effect.
removed broken/not maintained heightfield fluid demo
add some API methods to btPersistentManifold
2012-09-03 04:38:08 +00:00
erwin.coumans
c28f413e50 remove obsolete IBM Cell SDK makefiles 2012-09-02 17:38:51 +00:00
erwin.coumans
84b1774dda improve handling of restitution by using the velocity (linear/angular) before applying forces: this is done by re-introducing the btSolverBody and only apply the forces to solver body, and use the original rigid body velocity for restitution computation.
warmstarting for contact points was broken, fix in btPersistentManifold
enable split impulse by default (at the cost of some performance)
add  the option for zero-length friction (instead of recomputing friction directions using btPlaneSpace), use the solver mode flag SOLVER_ALLOW_ZERO_LENGTH_FRICTION_DIRECTIONS
precompute lateral friction directions (in btManifoldResult)
remove the mConstraintRow[3] from btManifoldPoint, it just took a lot of memory with no benefits: fixed it in btParallelConstraintSolver
2012-08-31 19:46:24 +00:00
erwin.coumans
10ed7bffd5 Fix serialization issue with btGeneric6DofSpringConstraintData, due to typo
Skip btGeneric6DofSpringConstraintData parts of the data that will be invalid in .bullet files version 280 or older
This fixes Issue 618, thanks to cyrfer for the report.
minor improvements in premake build (name library output so multiple Visual Studio installations don't conflict)
remove msvc folder
2012-07-24 04:07:25 +00:00
erwincoumans
78e1058b68 apply forgotten patch in a closed issue
http://code.google.com/p/bullet/issues/detail?id=573

Thanks to Andres Traks for the reminder!
2012-06-29 22:36:38 +00:00
erwin.coumans
73b217fb07 Apple contribution for OSX SSE and iOS NEON optimizations unit tests, thanks to Jordan Hubbard, Ian Ollmann and Hristo Hristov.
For OSX:
cd build
./premake_osx xcode4
for iOS:
cd build
./ios_build.sh
./ios_run.sh

Also integrated the branches/StackAllocation to make it easier to multi-thread collision detection in the near future. It avoids changing the btCollisionObject while performing collision detection.

As this is a large patch, some stuff might be temporarily broken, I'll keep an eye out on issues.
2012-06-07 00:56:30 +00:00
erwin.coumans
b5b31ce52b added VoronoiFractureDemo, thanks to RBD
fix in infinite recursion in quickSort, exclude the pivot in each sub partition
disabled constraints don't merge simulation islands, and they don't disable collision between linked rigid bodies either.
2012-03-05 21:47:05 +00:00
erwin.coumans
710954d772 Constraints can override their own number of solver iterations (either more or less than the default) or leave it default (-1)
Bump version to 2.80
2012-03-03 03:07:18 +00:00
erwin.coumans
a5aa2a5ff7 Add single body constructor for btGeneric6DofSpringConstraint. See Issue 601, thanks to aj.dneg for the patch. 2012-03-01 05:48:51 +00:00
erwin.coumans
b90352d62b changes in debug drawing, thanks to Dennis Cappendijk
See Issue 559
2012-02-29 04:15:09 +00:00
erwin.coumans
22dc2ca6c3 fix for btGeneric6DofConstraint, when the btRotationalLimitMotor goes over PI or under -PI.
See http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?f=9&t=5046&p=27113#p27113
Thanks zlash for the fix/report and Flix for the reminder.
2012-02-18 09:21:16 +00:00
erwin.coumans
15deee7e79 Fix a division by zero in btConeTwistConstraint::calcAngleInfo2
http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?f=9&t=7867
Thanks to Aardwolf for report and Roman Ponomarev for the fix
2012-02-16 23:44:43 +00:00
erwin.coumans
ff4fa560f0 Add missing forward declaration.
Thanks to SkewMatrix.
Fixes Issue 582.
2012-01-23 21:43:01 +00:00
erwin.coumans
f754952232 Pass in a const reference to a CompareFunc for quickSort, to make Visual Studio 2011 happy.
Thanks to Cameron Hart
Fixes Issue 588
2012-01-23 21:39:44 +00:00
erwin.coumans
dacb24e968 pass in const vectors into btUniversalConstraint and normalize the local copy
Thanks to SkewMatrix for the patch, http://code.google.com/p/bullet/issues/detail?id=571
2011-12-14 09:10:12 +00:00
erwin.coumans
22915b2344 enable randomization of non-contact constraints (disabled by default)
Thanks to Peter Kyme, http://code.google.com/p/bullet/issues/detail?id=576
2011-12-14 09:06:14 +00:00
erwin.coumans
606d65d95b Reduce dynamic memory allocation, fixes Issue 573
Thanks to Anton Breusov for the patch
2011-12-12 16:47:41 +00:00
erwin.coumans
76785d6e01 Only set the m_interpolationWorldTransform to m_worldTransform for kinematic objects, and use the new transform directly for static/dynamic objects.
update some cmake project files
2011-12-12 11:53:20 +00:00
erwin.coumans
8b849e0d07 Fixed split impulse SIMD issue in the constraint solver (doesn't affect default behaviour, as split impulse is switched off by default)
Thanks to Laurent Coulon for the report/fix. http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?f=9&t=7515&p=25766#p25766
2011-10-12 20:22:55 +00:00
erwin.coumans
654fe7872a remove btContinuousDynamicsWorld, it is obsolete and was never completed.
If you need tunneling prevention, one option is to use the CCD motion clamping in btDiscreteDynamicsWorld. See also Bullet/Demos/CcdPhysicsDemo.
You can use an embedded sphere that prevents tunneling, using the following settings:

		body->setCcdMotionThreshold(0.5);
		body->setCcdSweptSphereRadius(0.9f);


Add a camera zoom setting for the demos, thanks to ejtttje, fixes Issue 543
2011-09-15 18:47:13 +00:00
erwin.coumans
a13d22dc84 Fix a lot of warnings, thanks to ejtttje, Fixes issue 537
Fix soft body debug rendering
2011-09-15 01:17:34 +00:00
erwin.coumans
b690019e39 Removed global operator- in btQuaternion, and rewrote the 'getAxis' method
Add a unit test for testQuaternionGetAxisAngle
Thanks to ejtttje, fixes Issue 538
2011-09-13 23:37:05 +00:00
erwin.coumans
82234e6f33 add preliminary premake4 support (next to cmake) mainly to auto-generate Visual Studio projectfiles that can be redistributed (with no dependency on cmake, premake) 2011-09-02 22:24:08 +00:00
erwin.coumans
642a6821a5 remove speculative contacts, they break restitution and cause other artifacts
use btConvexPolyhedron for debug rendering, if available
fixes in btConvexConvexAlgorithm for polyhedral contact clipping, if GJK separating normal is zero
don't shift vertices in btPolyhedralConvexShape
2011-08-30 03:28:32 +00:00
erwin.coumans
16cc5665de fix in the breaking constraints feature 2011-07-01 21:51:38 +00:00
erwin.coumans
b80e5fd167 Remove co-planar faces from convex hull, using 2d Graham scan
Improve SAT performance, by skipping back-facing features
Add assert in array class (probably fires in places)
2011-05-20 12:29:24 +00:00
erwin.coumans
cdddf9d25a add FractureDemo to AllBulletDemos
improvements in CCD handling
some cleanup of CcdPhysicsDemo and BasicDemo
2011-04-09 01:14:21 +00:00
erwin.coumans
e9f2176804 fixes in AllBulletDemos OSX projectfile 2011-04-07 17:08:21 +00:00
erwin.coumans
a4e8213ede Implemented btDiscreteDynamicsWorld::addSpeculativeContacts, using conservative advancement to find contact point ahead of time
make Extras/ConvexDecomposition thread safe, Issue 501
some improvements to the btInternalEdgeUtility, patch from Issue 501
2011-04-07 06:23:34 +00:00
erwin.coumans
b16b61d9d6 disable constraints when they exceed a breaking threshold, control it with new methods in btTypedConstraint: get/setBreakingImpulseThreshold and get/setEnabled
Disabled constraints are not removed from the world and they use negligible CPU cycles
2011-04-02 19:01:23 +00:00
erwin.coumans
d198451909 clear the applied impulse for constraints (no warmstarting)
simplify logic, see Issue 499
2011-04-02 00:44:15 +00:00
erwin.coumans
852fa3ba30 add the BT_ prefix for all #ifdef guards, to avoid conflicts with developers own header defines.
Fixes Issue 497

//license header
#ifndef BT_RIGIDBODY_H
#define BT_RIGIDBODY_H
class btRigidBody
{
};
#endif //BT_RIGIDBODY_H
2011-04-01 17:14:52 +00:00
erwin.coumans
b1f21a7e6a Add better support for btCollisionWorld::convexSweepTest for btStaticPlaneShape, now using the btContinuousConvexCollision directly.
Bugfix in btKinematicCharacterController, using an uninitialized variable
2011-04-01 16:33:55 +00:00
erwin.coumans
5cee553a96 convexSweepTest: don't report hits if 'needsContactResponse' reports false.
Should fixes Issue 197
2011-03-31 21:20:52 +00:00
erwin.coumans
f17fa297d5 wrapped up first version of the FractureDemo
move 'split impulse' / position solver before velocity solver, so that applied impulse is available for fracture
add btSliderConstraint::getAngularPos see http://code.google.com/p/bullet/issues/detail?id=489
2011-03-18 00:20:52 +00:00
erwin.coumans
3615f6d415 fix for vehicle rollInfluence, see also discussion here:
http://code.google.com/p/bullet/issues/detail?id=468
2011-03-15 20:56:29 +00:00
erwin.coumans
7a9c349a8c enable predictive contact constraints, see BasicDemo 2011-03-05 03:01:44 +00:00
erwin.coumans
fd4ae96697 Performance optimization for btCompoundShape::setLocalScaling
Thanks to Mirza, See Issue 487

backward compatibility fix for recent improvement in btRaycastVehicle 'rollinfluence'
Thanks to Mihail, See Issue 468
2011-03-04 20:16:50 +00:00
erwin.coumans
e621c880d6 avoid naming conflicts with vectormath/sse version 2011-02-28 06:54:08 +00:00
erwin.coumans
2049fb2cfa don't initialize damping twice, it is confusing.
See Issue 472, thanks Daniel.
2011-02-27 03:39:31 +00:00