Commit Graph

141 Commits

Author SHA1 Message Date
Erwin Coumans
d744fe10dc compile fix 2017-06-01 12:51:43 -07:00
Erwin Coumans
87293e835c implement specular, URDF non-standard specular part (see sphere2.urdf) and SDF specular support.
pybullet.changeVisualShape(obUid,linkIndex,specularColor=[R,G,B]) and Bullet C-API b3UpdateVisualShapeSpecularColor
Bug fixes in b3ResourcePath::findResourcePath resolution.
add stadium.sdf and roboschool/models_outdoor/stadium assets https://github.com/openai/roboschool/tree/master/roboschool/models_outdoor/stadium
minor fixes to obj2sdf
2017-06-01 12:32:44 -07:00
Erwin Coumans
e6180ef98a use a fixed joint instead of crashing for unsupported joint types (planar, floating joint) 2017-05-25 13:02:20 -07:00
Erwin Coumans
19295f2859 enable file caching, currently only for Wavefront .obj files. You can disable file caching using
pybullet.setPhysicsEngineParameter(enableFileCaching=0)
Allow VR camera tracking only using position tracking, no orientation tracking (use
pybullet.setVRCamera([posX,posY,posZ],trackObjectFlag=0 or pybullet.VR_CAMERA_TRACK_OBJECT_ORIENTATION)
2017-05-17 19:29:12 -07:00
Erwin Coumans
dfe618bd62 initialize UrdfGeometry members 2017-05-15 07:59:07 -07:00
Erwin Coumans
e2d596f4d0 remove visual shape from CPU/TinyRenderer with removeBody
(thanks to Jeff Bingham for reporting the bug!)
2017-05-12 20:24:10 -07:00
Erwin Coumans
53a82819a0 expose b3LoadMJCFCommandSetFlags / pybullet.pybullet_loadMJCF(fileName,flags=pybullet.URDF_USE_SELF_COLLISION_EXCLUDE_ALL_PARENTS) 2017-05-10 15:01:25 -07:00
Oleg Klimov
b8afb4d7aa Memory leaks 2017-05-06 14:49:51 +03:00
Oleg Klimov
5a40b5aaae Compile fix 2017-05-06 14:49:51 +03:00
Oleg Klimov
1524004aa8 MJCF: support for "axisangle", small code improvements 2017-05-06 14:49:43 +03:00
Erwin Coumans
af6bf8ddc8 plumb URDF/SDF audio_source into PhysicsServerCommandProcessor, allow to play sounds on collision !
See also https://youtu.be/eppOjTfx5Jg for a first test, and this modified URDF how to add sounds:
https://github.com/bulletphysics/bullet3/blob/master/data/plane_with_collision_audio.urdf
Add the --audio flag to enable sound in pybullet/Bullet-C-API
2017-05-01 11:14:09 -07:00
Erwin Coumans
e4ace90980 fix some potentially uninitialized variable 2017-04-25 21:37:04 -07:00
Erwin Coumans
5158c1ae98 add python dumpLog.py utility to view log files created using 'startStateLogging'
don't enable <CTRL> for hotkeys yet
add some more profile markers
log objectId and linkIndex as signed int ('i') and not unsigned int 'I'
fix issue in startStateLogging: number of parameters was wrong
2017-04-12 15:02:47 -07:00
Erwin Coumans
82b576a390 fixed a bug that prevented kitchens/1.sdf to render properly (local scaling was double applied)
disable some left-over clipping that was moved to another part of the code
2017-04-06 21:13:23 -07:00
Erwin Coumans
b095e1d917 expose pybullet.URDF_USE_SELF_COLLISION flag, experimental (likely doesn't work well for many URDF files) 2017-04-04 12:47:34 -07:00
Erwin Coumans
b1cbc3d4b0 fix a potential memory leak for URDF files with multiple materials using the same name 2017-03-30 13:30:38 -07:00
Erwin Coumans
9d05b46de2 expose width/height as ExampleBrowser options.
suppress lack of 'site' support message in MJCF importer
suppress lack of 'plane' visual support in urdf/sdf import
getBodyName default to "" to avoid breaking cloudsim
expose bodyName when requesting body info (sdf/mjcf import)
pass optional "options" string to pybullet.connect method. this can be used for --opengl2 flag in GUI mode (or other flags)
2017-03-30 11:01:33 -07:00
yunfeibai
f062847038 Replace spaces with tabs. 2017-03-29 15:37:33 -07:00
yunfeibai
66a8685816 Merge remote-tracking branch 'upstream/master' 2017-03-29 15:06:15 -07:00
Oleg Klimov
77608154a3 MJCF: fix capsule length when given in size="", fix slider joint limits 2017-03-27 22:54:20 +03:00
Erwin Coumans
f4be2c1ee0 pass the joint parameters for all joints 2017-03-26 20:05:48 -07:00
Erwin Coumans
7503418c72 Split Bullet/src/LinearMath/btSerializer.cpp into btSerializer64.cpp to make it easier to rebuild serialization structure.
Add several MSVC optimization flags to cmake.
Bump up VERSION because serialization format changed
Expose btScalar& jointMaxForce, btScalar& jointMaxVelocity to 'getJointInfo2' API, add backwards compatibility to examples\Importers\ImportURDFDemo\URDFImporterInterface::getJointInfo.

pybullet: expose 4 more fields to getJointInfo: jointLowerLimit/jointUpperLimit/jointMaxForce/jointMaxVelocity
fix performance issue in CMD_ACTUAL_STATE_UPDATE_COMPLETED
2017-03-26 13:06:46 -07:00
Erwin Coumans
acbe8ee5cd remove use of snprint, fixes Issue 1037 2017-03-23 15:10:47 -07:00
yunfeibai
50f0cfca9e Add body name when loading urdf. 2017-03-23 10:16:39 -07:00
erwincoumans
a30b887595 Merge pull request #1025 from olegklimov/master
URDF loader improvement 2
2017-03-21 17:12:22 -07:00
Oleg Klimov
80a0b51a1d MJCF: fix cylinders in MJCF, also (possibly) fixes capsules in tiny renderer 2017-03-22 00:36:28 +03:00
Erwin Coumans
0b017b0f53 fix issue with btMultiBody friction in combination with soft contacts (friction should not re-use normal contact cfm/erp)
implement friction anchors, position friction correction, disabled by default. Use colObj->setCollisionFlag(flag | CF_HAS_FRICTION_ANCHOR); See test/RobotClientAPI/SlopeFrictionMain.cpp. In URDF or SDF, add <friction_anchor/> in <contact> section of <link> to enable.
PhysicsServer: properly restore old activation state after releasing picked object
btMultiBodyConstraintSolver: disable flip/flop of contact/friction constraint solving by default (it breaks some internal flaky unit tests)
2017-03-20 10:58:07 -07:00
Oleg Klimov
41df15a464 MJCF: fix B3_PI, fix colors, fix capsule without 'fromto' 2017-03-19 00:19:04 +03:00
Oleg Klimov
e8da7bb6f8 URDF loader: fix MuJoCo xml load, also closes #993 2017-03-17 02:11:47 +03:00
Erwin Coumans
3d2cb1cabf also allow absolute path in asset files (.obj, .stl, .dae etc) 2017-03-14 10:40:27 -07:00
Oleg Klimov
fa60cc5f56 URDF loader: fix SDF branch, warn about unsupported geometry 2017-03-14 02:32:02 +03:00
Oleg Klimov
3a8199ec28 Fix formatting 2017-03-10 19:46:46 +03:00
Oleg Klimov
82495f3c84 URDF loader: reuse the same resources finder routine for TinyRendererVisualShapeConverter 2017-03-10 18:17:38 +03:00
Oleg Klimov
5b2a9d1a01 URDF loader: resources path, "package://" removal, error messages, zero material path in .obj loader 2017-03-08 15:14:54 +03:00
Erwin Coumans
89e8e30de6 fix lack of collision scaling in pybullet URDF/SDF files (only graphics meshes supported scaling, collision objects ignored scaling) 2017-02-28 16:30:57 -08:00
Erwin Coumans
63486a712c VR video recording, use command-line --mp4=videoname.mp4
tune gripper grasp example with tefal pan, 800Newton force.
URDF importer: if using single transform 1 child shape, don't use compound shape.
if renderGUI is false, don't intercept mouse clicks
add manyspheres.py example (performance is pretty bad, will look into it)
[pybullet] expose contactBreakingThreshold
2017-02-16 14:19:09 -08:00
Erwin Coumans
7df123025f URDF parser: allow inertial element in just ixx, iyy, izz format (non-standard URDF)
tiny_obj_loader: don't crash when/if normals are not specified
2017-01-31 18:09:44 -08:00
Erwin Coumans
76dcf3a751 remove the contype=0 in inverted_pendulum.xml, so we can 'mouse-pick' the pendulum.
[mjcf importer] add rudimentary support for inertial frame computation, for 'fromto' capsules.
2017-01-24 21:10:21 -08:00
Erwin Coumans
d465e1eea5 add capsule support in urdf parser (non-standard extension), capsule.urdf
fix btCapsuleShape (X,Y,Z) margin issue
fix uninitialized variables in TinyRenderer: m_hasLightDistance, m_hasLightAmbientCoeff, m_hasLightDiffuseCoeff, m_hasLightSpecularCoeff
pybullet/shared memory API 'getClosestPoints' / b3InitClosestDistanceQuery, only report contacts equal/smaller distance than given
2017-01-23 16:45:18 -08:00
Erwin Coumans
93471a1c31 cmake Win32 fixes
fixed some more warnings
added alignment macros to some classes
btPersistentManifold from 128 to 16 bytes aligned
prepare command to select collision filter mode (SIM_PARAM_UPDATE_COLLISION_FILTER_MODE)
2017-01-16 13:05:26 -08:00
Erwin Coumans
c0c4c8ba3f fix many warnings
remove btMultiSapBroadphase.*
make collisionFilterGroup/collisionFilterMark int (instead of short int)
2017-01-15 22:26:11 -08:00
Erwin Coumans
310fabcd7e Further improvements in Bullet MuJoCo MJCF import:
[MJCF import] improved humanoid.xml, inverted_pendulum.xml import (automatically add dummy-links to connect multiple joints between bodies)
[MJCF import] fix bug in quaternion conversion (w,x,y,z) -> (x,y,z,w)
2017-01-15 11:22:24 -08:00
Erwin Coumans
3d6584962a remove some memory leaks in example code. 2017-01-10 14:57:16 -08:00
Erwin Coumans
afdcf69837 implement some dummy methods in URDFImporterInterface, some code
breaks because of un-implemented methods
2017-01-07 09:30:06 -08:00
Erwin Coumans
c940f0ec47 update pybullet quickstart quide PDF
hook up the loadMJCF importing MuJoCo xml files in pybullet and shared memory API b3LoadMJCFCommandInit
2016-12-31 14:43:15 -08:00
Erwin Coumans
fdd517e00f First step towards a MuJoCo MJCF importer for Bullet. It can load the humanoid.xml, ant.xml and some other OpenAI GYM asset files. Not all fields are converted, so it is work-in-progress. This is useful for Reinforcement Learning experiments, and would also help integration with DeepMind Lab. 2016-12-30 18:32:57 -08:00
Erwin Coumans
82995a8343 pybullet, more robust multi-server connections
Windows shared memory: allow to use custom key.
Improve GUI performance on Windows, submit letters in text as a batch (fewer draw-calls)
quadruped.py: first try to connect to SHARED_MEMORY, if it fails (<0) use GUI
increase Chrome about://tracing json export capacity (press 'p' in Example Browser)
UDP physics server: add --port and --sharedMemoryKey command-line arguments
PhysicsServerExample: add --sharedMemoryKey command-line option (for VR example too)
ExampleBrowser: sleep a few milliseconds if rendering is too fast, use --minUpdateTimeMicroSecs=0 to disable
2016-12-28 21:51:54 -08:00
Erwin Coumans
15cda75130 add <restitution> in <contact> settings of URDF/SDF
allow 'useMaximalCoordinates' and 'useFixedBase' in pybullet.loadURDF.
enable split impulse for btRigidBody, even in btMultiBodyDynamicsWorld.
allow initialization of velocity and apply force for btRigidBody in pybullet/shared memory API.
process contact parameters in URDF also for btRigidBody (friction, restitution etc)
add pybullet.setPhysicsEngineParameter with numSolverIterations, useSplitImpulse etc.
2016-11-30 22:24:20 -08:00
erwincoumans
0d47d61007 pybullet getClosestPoints 2016-11-09 21:01:04 -08:00
erwin coumans
f97cb7002d first version of 'getVisualShapeData' to get visual shape information to allow external renderer with pybullet and shared memory robotics API
b3InitRequestVisualShapeInformation/b3GetVisualShapeInformation in shared memory API
2016-10-18 22:05:28 -07:00