Commit Graph

1853 Commits

Author SHA1 Message Date
erwin coumans
29f3afe2a4 don't use GL_LINEAR_MIPMAP_LINEAR for shadow maps
optimize gpu upload (use glBufferSubData instead of glMapBuffer
Avoid checking char array against zero.
2016-10-14 15:06:09 -07:00
erwin coumans
ddff1bcdc0 remove some useless global constants, move them right into the constructor 2016-10-07 09:00:49 -07:00
erwin coumans
b81eb79ef5 ping-pong back/forward in PGS solving iterations to reduce bias in constraint order
add experimental rhs clamp in btMultiBodyJointMotor to control maximum error resolution.
2016-09-28 11:17:11 -07:00
Erwin Coumans
96c1ee4256 revert default contact 'erp' (error-reduction-parameter) from 0.8 to 0.2
as it used to be.
2016-09-26 07:55:30 -07:00
Erwin Coumans
6563c9c821 add btVector3::safeNorm to avoid/workaround certain clang/g++ issue or returning -INF
when taking sqrtf(0.0000000000000000000000000000000000000108333558)
2016-09-25 23:13:23 -07:00
erwincoumans
c979f147e6 Update btQuaternion.h
add missing ; after btAssert
2016-09-25 15:12:19 -07:00
erwincoumans
0dfe20c036 Merge pull request #759 from MichaelMcDonnell/warnings
Two bugs
2016-09-23 22:15:16 -07:00
erwincoumans
278a89f7c3 Merge pull request #804 from erwincoumans/master
fix uninitialized variable in btMultiBody
2016-09-23 22:13:36 -07:00
erwincoumans
d3bf740c50 Merge pull request #446 from T4Larson/slerpfix
fix: btQuaternion.slerp() may result in NaN-quaternions
2016-09-23 22:03:01 -07:00
erwincoumans
fe6c8775da fix uninitialized variable in btMultiBody
use btAssert to detect 0 determinant in btMatrix3x3 inverse
Remove obsolete comment in PosixSharedMemory, the Windows shared memory implementation was done over a year ago
2016-09-23 21:59:38 -07:00
erwincoumans
5c1d2f9a0e Merge pull request #789 from mwoehlke-kitware/remove-useless-const
Remove useless const qualifiers from returns
2016-09-21 08:12:11 -07:00
erwincoumans
e4e12828ca Merge pull request #790 from mwoehlke-kitware/fix-dl-link-errors
Fix clew.c link errors
2016-09-21 08:11:00 -07:00
erwincoumans
5a6db80d01 Merge pull request #788 from mwoehlke-kitware/fix-missing-virtual-dtor
Add "missing" virtual dtor
2016-09-21 08:09:14 -07:00
erwin coumans
0a628f06cc decrease some gjk/epa tolerance to improve collision detection using very small collision margins (0.001/1mm)
tweak pr2 gripper.
2016-09-20 12:37:13 -07:00
erwin coumans
db3122233f remove that odd triangle in the origin of samurai castle (VR)
add rolling/spinning friction to cube, remove it from plane/samurai.urdf
URDF2Bullet: support joint limits for revolute and prismatic, only if defined (if upper < lower, disable limit)
add some profiling markers to improve performance
2016-09-19 07:02:43 -07:00
Matthew Woehlke
7e1d72dfe4 Remove useless const qualifiers from returns
Remove const qualifiers applied to POD return values, as these are
meaningless and ignored by the compiler and are therefore potentially
misleading. (They also trip -Wignored-qualifiers.)
2016-09-16 11:01:03 -04:00
Erwin Coumans
567b003654 separate spinning and rolling friction coefficients, exposed in URDF as spinning_friction / m_rolling_friction
improvements in VR demo, add grasper etc.
2016-09-16 00:57:00 +01:00
Erwin Coumans
1d88cf71e4 separate spinning friction (torsional friction around contact normal) from
rolling friction (orthogonal to contact normal)
2016-09-16 00:04:33 +01:00
Matthew Woehlke
ba3a1dcc98 Fix clew.c link errors
Add missing link to CMAKE_DL_LIBS to resolve link errors from clew.c
using dlopen and friends but failing to link to libdl.

Fixes #787.
2016-09-15 12:58:31 -04:00
Matthew Woehlke
ef943bdcf0 Add "missing" virtual dtor
Make the dtor of b3DynamicBvhBroadphase virtual, to match that the type
has other virtual methods. This silences a -Wvirtual-dtor warning.
2016-09-15 12:17:23 -04:00
erwincoumans
e5a8eb2425 rolling friction -> combine using rolling*normal friction, add for both objects.
rolling friction -> only along the normal, until we have separate rolling friction coefficients on normal and non-normal directions
Don't teleport with grasping controller (VR)
Tune VR grasping a bit.
2016-09-12 19:10:20 +01:00
Erwin Coumans
82661d98cd init ERP for second btMultiBodyJointMotor,
comment-out debug printf in Kuka IK example
2016-09-11 05:54:47 +01:00
erwin coumans
3c706306cd add experimental pr2-gripper support in VR physics server
add setErp to btMultiBodyJointMotor
2016-09-09 14:30:37 -07:00
erwin coumans
4ab02a07e5 Merge branch 'master' of https://github.com/erwincoumans/bullet3 2016-09-08 15:22:41 -07:00
erwin coumans
32eccdff61 Create project file for BussIK inverse kinematics library (premake, cmake)
URDF/SDF: add a flag to force concave mesh collisiofor static objects. <collision concave="yes" name="pod_collision">
VR: support teleporting using buttong, allow multiple controllers to be used, fast wireframe rendering,
Turn off warnings about deprecated C routine in btScalar.h/b3Scalar.h
Add a dummy return to stop a warning
Expose defaultContactERP in shared memory api/pybullet.
First start to expose IK in shared memory api/pybullet (not working yet)
2016-09-08 15:15:58 -07:00
erwincoumans
d5ec5ca9a0 Update IDConfig.hpp 2016-09-06 13:07:06 -07:00
Erwin Coumans
ecd814c9c5 export contact friction/damping through URDF and API
convert from contact friction/damping to cfm/erp
btCollisionObject::setContactFrictionAndDamping
2016-09-02 16:40:56 -07:00
Erwin Coumans
e98fca1e5e implement pybullet.getContactPointData(), two optional object unique ids as filter
returns a pylist of contact points. Each point has the following data:

	0     int m_contactFlags;//unused for now
         1     int m_bodyUniqueIdA;
         2     int m_bodyUniqueIdB;
         3     int m_linkIndexA;
         4     int m_linkIndexB;
         5-6-7     double m_positionOnAInWS[3];//contact point location on object A, in world space coordinates
         8-9-10     double m_positionOnBInWS[3];//contact point location on object A, in world space coordinates
         11-12-13     double m_contactNormalOnBInWS[3];//the separating contact normal, pointing from object B towards object A
         14     double m_contactDistance;//negative number is penetration, positive is distance.

         15    double m_normalForce;
2016-09-01 18:28:39 -07:00
erwincoumans
a370c3bbac Merge pull request #765 from YunfeiBai/master
Torsional and rolling friction for btMultiBody
2016-09-01 14:57:46 -07:00
erwincoumans
85fd7f560c add first draft of contact point query in shared memory API
b3SharedMemoryCommandHandle b3InitRequestContactPointInformation(b3PhysicsClientHandle physClient);
void b3SetContactFilterBodyA(b3SharedMemoryCommandHandle commandHandle, int bodyUniqueIdA);
void b3SetContactFilterBodyB(b3SharedMemoryCommandHandle commandHandle, int bodyUniqueIdB);
void b3GetContactPointInformation(b3PhysicsClientHandle physClient, struct b3ContactInformation* contactPointData);
Implemented for PhysicsClientSharedMemory, not for PhysicsDirect yet.
Add btCollisionObject::setUserIndex2
2016-09-01 13:30:07 -07:00
yunfeibai
9c124b5896 Rolling friction demo for sphere and torsional friction demo for two point contact. 2016-08-30 17:50:37 -07:00
yunfeibai
d784c61b61 Add rolling friction, set rolling friction coefficient from urdf, and set up two point contact experiment. 2016-08-30 11:19:23 -07:00
erwin coumans
4094b9f0df Disable 'm_robotSim.setNumSimulationSubSteps' because it is not needed at the moment
Fix issue in contact/friction between btMultibody and btRigidBody (external force/torque of btRigidBody was not taken into account during contact/friction setup)
Allow 0.1 mm slop in contact, to avoid loosing contact. Todo: allow contacts with positive distance in multibody solver.
2016-08-27 13:44:18 -07:00
Michael Mc Donnell
4636efae2b [Bullet3OpenCL] Fix check for null-terminated string
The code essentially dead because it was checking the pointer to an array for null. The check will alway return true. Instead the code was meant to check if the string had anything in it after the call to clGetDeviceInfo.
2016-08-27 08:13:42 -07:00
Michael Mc Donnell
d5dcb34188 [Bullet3OpenCL] Fix wrong parantheses around b3Fabs
The absolute value of m_appliedImpulse was supposed to be compared to the breakingThreshold. Instead a boolean was created from the comparison, and the absolute value of that was taken (which makes no sense).
2016-08-27 08:13:42 -07:00
erwincoumans
c741b17da8 Merge pull request #758 from YunfeiBai/master
Expose slider constraint in RobotSimAPI.
2016-08-26 12:26:08 -07:00
erwincoumans
79be5800cb Merge pull request #757 from erwincoumans/master
fix in structure alignment of btMultiBodyLinkDoubleData and btMultiBo…
2016-08-26 12:08:29 -07:00
yunfeibai
5b9b5178f9 Expose slider constraint in RobotSimAPI. 2016-08-26 10:35:10 -07:00
erwin coumans
c5164e503f fix in structure alignment of btMultiBodyLinkDoubleData and btMultiBodyDoubleData
causing serialization issue in  URDF/SDF loading in double-precision mode on Windows 32bit.
(it was fine on Mac/Linux 64bit)
bump serialization version to 2.85, as we change the file format
fix in name clash in makesdna.cpp -> intptr_t is already defined.
2016-08-26 10:00:29 -07:00
erwincoumans
c29d445b94 Merge pull request #750 from TIHan/quick_fix1
Fixed btKinematicCharacterController from clipping through walls in corners.
2016-08-25 20:26:42 -04:00
erwincoumans
0baef2b84e Merge pull request #754 from YunfeiBai/master
Set physics clock subdivider and fixed constraint in RobotSimAPI.
2016-08-25 20:24:54 -04:00
Erwin Coumans
ba8964c4ac [InverseDynamics] Support for Jacobians & derivatives
This change adds support for calculating Jacobians and
dot(Jacobian)*u terms, along with the required support for
the 3xN matrices in the standalone math library.
It also adds functions to compute kinematics only (position, velocity, accel).
To facilitate tests, the Cl also adds a RandomTreeCreator to create
randomized multibody trees.
Thanks to Thomas Buschmann for this contribution!
2016-08-25 16:24:28 -07:00
yunfeibai
c26da8440d Add slider constraint. 2016-08-25 11:54:59 -07:00
Will Smith
ba4c389c84 Fixed btKinematicController from clipping through walls in corners. 2016-08-19 18:46:07 -05:00
erwin coumans
62d5b7c5c0 add single step simulation, using 'o' key. use 'i' key to suspend simulation first
default background color a bit darker, to show debug lines
tweaked contact point rendering a bit
2016-08-19 10:30:02 -07:00
erwincoumans
c50490a6d9 Merge pull request #742 from sinkingsugar/master
Fixed btKinematicCharacterController runtime crashes
2016-08-17 19:54:14 -07:00
Giovanni Petrantoni
a4a6a3ce57 Fixed btKinematicCharacterController runtime crashes coming from previous pull request (more testing is necessary) 2016-08-17 14:19:58 +09:00
yunfeibai
9c4cfde3d6 Fixed constraint for btMultiBody and btRigidBody. 2016-08-15 13:19:00 -07:00
Erwin Coumans
f304fd7611 add one more pybullet renderImage API and testrender.py example
tweak Bullet Inverse Dynamics, work-around compiler issue
2016-08-02 11:12:23 -07:00
erwincoumans
d605897d13 Merge pull request #719 from erwincoumans/master
fix ffmpeg stream to create quicktime compatible videos
2016-07-29 09:07:46 -07:00