Commit Graph

336 Commits

Author SHA1 Message Date
Saran Tunyasuvunakool 06b70832ce Add keyboard event callback for Python passive viewer.
Fixes #766
Fixes #846

PiperOrigin-RevId: 549449372
Change-Id: I37d17f1162c66d0e8482d402aae22d9a16b59deb
2023-07-19 15:54:44 -07:00
Saran Tunyasuvunakool f7847ba73e Fix GLFW crash when Python exits while the passive viewer is running.
Fixes #790

PiperOrigin-RevId: 549440435
Change-Id: I808f6aaab6662225e5fe1131e0da72eca6011ba9
2023-07-19 15:20:46 -07:00
Saran Tunyasuvunakool 8386b28877 Change "MIME type" to "Media Type".
MIME type is the historic nomenclature for Media Type, see e.g. https://www.iana.org/assignments/media-types/media-types.xhtml.

PiperOrigin-RevId: 549394435
Change-Id: I000e044a35ec44392e9c41bab6383aa89cdefc49
2023-07-19 12:35:57 -07:00
Yuval Tassa 51aa375af0 Improvements related to models where joint-actuator relationship is not one-to-one:
- Add `joint-actuatorforcerange` for clamping total actuator force at joints. Add `sensor-jointactuatorfrc` for sensing total actuator forces on a single joint.
See [documentation](https://mujoco.readthedocs.io/en/latest//modeling.html#actuator-force-clamping) for justification and use cases.
- Add simple car model to `model/`.
- Move actuation-related test models into `engine/testdata/actuation/`.

PiperOrigin-RevId: 549355941
Change-Id: I27f6c1f80426d73a2811ef5ae74684a228b2fbd1
2023-07-19 10:29:32 -07:00
Kyle Bayes 5fcdae771b Add content_type attribute that takes a MIME type to specify the file contents for meshes, hfields, and textures.
PiperOrigin-RevId: 549302344
Change-Id: I30a8adfef5b5d87bb20479329f3396892f5137ff
2023-07-19 06:51:36 -07:00
Saran Tunyasuvunakool 0ccfef7314 Add update_{hfield,mesh,texture} methods to the passive viewer.
Fixes #812.
Fixes #958.
Fixes #965.

PiperOrigin-RevId: 548181282
Change-Id: I6eb0cd2ce52c66083e83dd08d69e0cfb4178dbba
2023-07-14 11:43:36 -07:00
Yuval Tassa b5bef1b639 Describe c-frame variables.
Fixes #982.

PiperOrigin-RevId: 548060614
Change-Id: I2164afc07c02e657b1b924a5afc59209356b57eb
2023-07-14 01:59:43 -07:00
Kyle Bayes 242aea93c6 Bump oldest supported MacOS to version 11.
PiperOrigin-RevId: 547479684
Change-Id: Idb6a432af0e7872ca087a0c571aafa72e9528818
2023-07-12 06:38:26 -07:00
Yuval Tassa 5cfbb6ac8b Add mjd_quatIntegrate, expose mjd_subQuat.
PiperOrigin-RevId: 546252926
Change-Id: I7d6b2bd6536e7e8afc368f3c46037c20f6a1cb5e
2023-07-07 05:33:24 -07:00
Kyle Bayes 95167fab2d Add utility function for merging directory names with filenames, and fix issue in mj_addfileVFS where directory names without trailing filesystem separators won't append correctly.
PiperOrigin-RevId: 545450158
Change-Id: I550394f11ac2837d35f3d869f8718a119a9eac38
2023-07-04 08:09:01 -07:00
Copybara-Service a36cb0ce3f Merge pull request #949 from Ein04:patch-1
PiperOrigin-RevId: 544517699
Change-Id: Ic12feb62f3e90d93b1be122a90f0a6fe062ac411
2023-06-29 18:32:37 -07:00
Copybara-Service b96532181c Merge pull request #936 from thowell:main
PiperOrigin-RevId: 543653302
Change-Id: I174efb329a9023199ba0267d3fcd308805ff9cd0
2023-06-26 23:59:08 -07:00
Yuval Tassa a7021df63e Add primitive sphere-cylinder collider.
PiperOrigin-RevId: 543586615
Change-Id: Icd47123e619f731f16dedfec25d825e44c24c036
2023-06-26 17:25:32 -07:00
Ruiyu G ca3823343d fix typo in computation.rst 2023-06-22 17:28:56 -07:00
Ruiyu G 14cc32bbe5 Fix typo. 2023-06-22 16:39:44 -07:00
Yuval Tassa c50c92ccc8 Add mjv_connector, identical to mjv_makeConnector but with a more convenient "from-to" parameterization.
PiperOrigin-RevId: 542343761
Change-Id: I75f5ff3c404a2a9f65dfed706e590efd7b951f6e
2023-06-21 13:19:36 -07:00
Saran Tunyasuvunakool 0945af7b8a Apply version number 2.3.6 to the pending changelog.
PiperOrigin-RevId: 541964989
Change-Id: I66a18f2bae624f63962f28f434b9a5cf90d260c7
2023-06-20 10:08:34 -07:00
Taylor Howell 52aa5b645c Update python.rst 2023-06-19 14:12:08 -07:00
Saran Tunyasuvunakool c9e9cd8b35 Change org name to "Google DeepMind" in various docs.
PiperOrigin-RevId: 540691205
Change-Id: I9eb99eb18893e6748892334470211dbd9d5808db
2023-06-15 14:28:25 -07:00
Yuval Tassa f67e359532 Add mjtState enum and related mj_stateSize, mj_getState and mj_setState functions.
PiperOrigin-RevId: 539667943
Change-Id: I14c34be8ce4c287e529380257b5c5bffc3ab45ce
2023-06-12 08:56:48 -07:00
Copybara-Service 84c33e53df Merge pull request #916 from jc-cr:patch-1
PiperOrigin-RevId: 539634371
Change-Id: I3690034f4ea10c4e92daeeb4c62b0b060c5c8db5
2023-06-12 06:36:40 -07:00
Yuval Tassa 6434001747 Remove "Main struct types" subsection from APItypes.rst, for quicker access (fewer clicks) to main struct reference.
PiperOrigin-RevId: 539525003
Change-Id: I01a3b7e4b054c3acda0a0070c227d50d7f43ea72
2023-06-11 20:00:15 -07:00
JC b3b05c0435 remove extra new line when editing 2023-06-09 22:14:32 -05:00
JC 849ed472c0 removed trailing whitespaces 2023-06-09 22:13:04 -05:00
JC 15618d8f94 Corrected index.rst example code samples
Added the missing humanoid directory path to window and linux sample terminal commands
2023-06-09 21:55:02 -05:00
Yuval Tassa 4a086edb43 Fix wrong link in changelog.
PiperOrigin-RevId: 539106369
Change-Id: I228cbf426322e9b3756e64788cb9db0cd271ffa1
2023-06-09 09:45:55 -07:00
Yuval Tassa 466c9aca82 Remove mj_activate and mj_deactivate.
PiperOrigin-RevId: 538799120
Change-Id: I4d6729131e20ab9ae15c94c221ba83ae5732e942
2023-06-08 08:55:39 -07:00
Yuval Tassa 833d30858d Add note regarding reproducibility
PiperOrigin-RevId: 538535494
Change-Id: Icc37c95df77a9e30868a2ef866c5e603239e728b
2023-06-07 10:56:18 -07:00
Yuval Tassa d82f5ce5a4 Add mjContact.solreffriction, mjModel.pair_solreffriction and related implementation, allowing contact reference acceleration to be different for normal and frictional contact directions. This is required for e.g. elastic frictional collisions.
PiperOrigin-RevId: 538513357
Change-Id: Id9eb910fe791cf898c712030cb2c0fc481389c91
2023-06-07 09:40:20 -07:00
Yuval Tassa 83e70954d7 Improve documentation of solver parameters.
PiperOrigin-RevId: 538098136
Change-Id: I6a25fd066d5a1a7ef7b28c73accbd15c497fcba4
2023-06-06 00:30:15 -07:00
Copybara-Service 1efdcbf511 Merge pull request #896 from Beanpow:fix_doc
PiperOrigin-RevId: 537977702
Change-Id: I1ecc4caba7ce434a61625fa8b01bdc5769747f4a
2023-06-05 14:11:52 -07:00
Beanpow 39b744b231 Fix the effective time constant function of muscle 2023-06-02 16:53:32 +08:00
Yuval Tassa 86f22cb26b Fix typo.
PiperOrigin-RevId: 537211345
Change-Id: Icec139ee4651e32008bf71d990d5dbe7434df67d
2023-06-01 21:37:54 -07:00
Yuval Tassa 8efb04eb79 Improved docs chapter order, rename Models to Model Gallery.
PiperOrigin-RevId: 536819755
Change-Id: Ia2151a464c423b1ca13719285e4016832f448399
2023-05-31 14:13:41 -07:00
Yuval Tassa 4beab79946 Remove outdated reference in computation chapter.
PiperOrigin-RevId: 536818445
Change-Id: I6974855bfd0aee1c28651ad577a185b63d71c187
2023-05-31 14:08:57 -07:00
Yuval Tassa d40c395917 Add Visualization tab to simulate.
Also:
- Increased label width in mjUI tight theme spacing.
- Added `mjITEM_EDITFLOAT` for editing float values.
- Move mjUI numpad key codes to header file.
PiperOrigin-RevId: 535839953
Change-Id: Ibdc0a9a20be514caa5b487211212ed6f5b8a6ba9
2023-05-27 05:08:15 -07:00
Saran Tunyasuvunakool f887c1e928 Add ASAN and MSAN instrumentation for arena and mjData stack.
PiperOrigin-RevId: 535635490
Change-Id: Ia1e58771bae25bf72c861f57452fb8faa2b918fb
2023-05-26 09:17:26 -07:00
Yuval Tassa c66d79409c Change mj_ray behaviour to match geom visualisation conventions:
- Planes and height-fields respect `mj_ray`'s `geom_group` argument.
- The `flg_static` argument now applies to all static geoms, not only those directly in the world body.

Before this change:
- Rays always intersected with height fields and planes, unless `flg_static` was set to 0.
- `flg_static` only applied to static geoms that were direct children of the world, but not geoms that were children of static bodies.

PiperOrigin-RevId: 534969091
Change-Id: I8dc7c320c63d6af95709b9f5e83a3c50e1c199fa
2023-05-24 13:52:21 -07:00
Saran Tunyasuvunakool 55c7f45dc5 Fix sparse matmul logic in addJTBJSparse.
Also rename arguments and loop variables in `addJTBJSparse` for additional clarity.

PiperOrigin-RevId: 534908360
Change-Id: I143ef5aef7ff90091369d408740f7f44d9e19378
2023-05-24 11:02:35 -07:00
Alessio Quaglino 03d6d27f64 Use mesh BVH for speeding up ray mesh intersection.
PiperOrigin-RevId: 534141245
Change-Id: I9f5a71ea059a1a232fd2910d1efc0506ab6dbef3
2023-05-22 12:05:20 -07:00
Alessio Quaglino dab49d487c Use mesh BVH for speeding up ray mesh intersection.
PiperOrigin-RevId: 532516008
Change-Id: Ia9cac060279d030221c1a6b4fad457a857701370
2023-05-16 11:10:38 -07:00
Alessio Quaglino 9d1a21f99d Use mesh BVH for speeding up ray mesh intersection.
PiperOrigin-RevId: 532464595
Change-Id: If159c89b93c24e6a7be6310911364cfad7baae81
2023-05-16 08:17:50 -07:00
Alessio Quaglino fcc825c5e6 Add cutoff argument to mj_multiRay.
PiperOrigin-RevId: 532158635
Change-Id: I70f98be9f781c8281e21aa5c17bd85f3654e9383
2023-05-15 10:44:37 -07:00
Yuval Tassa 770b4b363a Added optional smoothing to muscle dynamics:
- `muscle` actuators take a new `tausmooth` attribute (defaults to 0) which when positive, smooths the transition between activation and deactivation timescales.
- `mju_muscleDynamics` takes 3 parameters, adding width of smoothing sigmoid.

PiperOrigin-RevId: 531473354
Change-Id: I8ab6c0289ff04437e798c3ca6edda132a30fcc31
2023-05-12 04:58:53 -07:00
Copybara-Service 777cad52b4 Merge pull request #860 from PeterMitrano:main
PiperOrigin-RevId: 531458260
Change-Id: I551e6c6be5d6a15426e6aa60beb27d64591bc66a
2023-05-12 03:34:33 -07:00
Kevin Zakka 3d71b160e6 Add 3x3x3 cube to model collection.
PiperOrigin-RevId: 531224451
Change-Id: Ibdfe5b89a5b2895500265199906a364768d606f0
2023-05-11 09:28:18 -07:00
Alessio Quaglino bf81d1e6a5 Fix typo.
PiperOrigin-RevId: 531167948
Change-Id: I5fcfe77fd69a050ef9dd88f748973c4a9233cbdb
2023-05-11 04:55:53 -07:00
Alessio Quaglino 41a7049920 Use shell inertia to compute mesh aabb and frame if volume is invalid.
PiperOrigin-RevId: 530925161
Change-Id: I94b97efc7198e2b750480df8687e91bc047a6fc9
2023-05-10 09:12:11 -07:00
Peter Mitrano 73fde667a5 fix typos 2023-05-09 20:59:43 +00:00
Alessio Quaglino 4c487e07ed Add mesh BVH.
PiperOrigin-RevId: 530559807
Change-Id: Ibdafae22c7c74d15d707f205be73e4a571a6ae10
2023-05-09 03:31:06 -07:00