Commit Graph

584 Commits

Author SHA1 Message Date
Yuval Tassa 222ee00a66 Break out passive force functions into a new file engine_passive.c
PiperOrigin-RevId: 513834952
Change-Id: I5347440f24d767a7dc81a34e48e1e17d8c10173f
2023-03-03 08:32:16 -08:00
Yuval Tassa fd1070cf03 Delete remaining code related to now-removed distance equality constraint.
PiperOrigin-RevId: 513391064
Change-Id: I47fc344708a580c1e99bd2753113aaa408812966
2023-03-01 17:57:54 -08:00
Kyle Bayes 50bebcb4ee Precount number of non-zeros for constraint Jacobian sparse matrix.
PiperOrigin-RevId: 512947632
Change-Id: I9605e81b4e51fbc90854c13153e4fee38ad48fb9
2023-02-28 08:57:56 -08:00
Kyle Bayes 90b5dd14ca Fix issue where mj_addConstraint was writing values into efc_J_rowadr and efc_J_rownnz that are not needed.
PiperOrigin-RevId: 512919818
Change-Id: I8ee7443a2bf2265934899673f8943a83cdd4ef69
2023-02-28 06:47:56 -08:00
Alessio Quaglino f2413a5d55 Remove overwriting of particle geoms as spheres that was restored by mistake in commit d0b1a97.
PiperOrigin-RevId: 512597403
Change-Id: Ifa29ccc405d1c98ffadf65b2cefa164067f95220
2023-02-27 05:09:39 -08:00
Alessio Quaglino 7e5419f806 Remove trailing spaces in printArray, printArrayInt, printVector, and printSparse.
PiperOrigin-RevId: 512596881
Change-Id: Icfa955628b9a2955df73093b6c8df7751260adfb
2023-02-27 05:06:33 -08:00
Copybara-Service 2729f9fcf8 Merge pull request #740 from hyarion:fix/unity-fluidshape
PiperOrigin-RevId: 511791324
Change-Id: I28e98e55efe43ba053b803838082646289e4f09e
2023-02-23 08:19:20 -08:00
Yuval Tassa cadab1f438 Make the word extent more clearly visible in documentation of zfar and znear.
Fixes #746.

PiperOrigin-RevId: 511719937
Change-Id: If697e2dd4992dfa3f345ae4caa25bd67d015a91b
2023-02-23 01:33:27 -08:00
Benjamin Nauck 42c3faa462 Add support for fluid coefficients to Unity plugin 2023-02-20 18:46:16 +01:00
Yuval Tassa 7e7cb177a4 Cosmetic changes.
PiperOrigin-RevId: 511008317
Change-Id: Id8d7cd4f4e22e0658857d16b47d51053f1477bb9
2023-02-20 09:23:32 -08:00
Yuval Tassa 7542c90cd2 Improved behaviour of mouse-spring interactions.
Also:

- Renamed recently introduced `mjvPerturb` member `reflocalpos` -> `refselpos` and corrected docstring.
- Added `mjvPerturb.localmass`: body spatial inertia at selection point.
- Removed `const` qualifier to `mjData` argument of `mjv_initPerturb()`, to facilitate spatial inertia computation.
- Improved `mj_Object{Velocity, Acceleration}` docstrings, clarifying that rotational velocities precede linear velocities.
- Removed redundant const qualifiers from non pointer arguments to `mju_dot` and `mju_writeNumBytes`.

PiperOrigin-RevId: 511002168
Change-Id: I27400f497947f330072d4abb7c9bf7e71e6c5d49
2023-02-20 08:40:33 -08:00
Alessio Quaglino 9756ed0d80 Read normals and textures from OBJ, do not duplicate vertices.
PiperOrigin-RevId: 510461549
Change-Id: I19245d691e722a8371e61153383f275f599353d6
2023-02-17 10:15:25 -08:00
Yuval Tassa 35967a30d9 Fix order of API function sections, add missing Plugins section.
PiperOrigin-RevId: 510442237
Change-Id: I1fd4e309f33f45247eac84233745bfa35b5d796f
2023-02-17 08:50:25 -08:00
Kyle Bayes 090c25988a Split API reference pages into Data Structures and Functions pages.
PiperOrigin-RevId: 510422950
Change-Id: I6b2eebab0c0020b80fec83094aa65c6a412e277e
2023-02-17 07:06:20 -08:00
Yuval Tassa 2607e67f8d Add contact labels showing which geom pairs are in contact.
PiperOrigin-RevId: 510422404
Change-Id: Ia73570098752e7c7175e4b5a5f2a0f8b08a6c006
2023-02-17 07:03:19 -08:00
Benjamin Nauck 09bc934f25 Add support for fluid shapes to Unity plugin 2023-02-17 13:15:29 +01:00
Yuval Tassa a6730aa740 Keep only immediate parent in XMLreference TOC header names.
PiperOrigin-RevId: 510095682
Change-Id: I72973c955cce14a90f5af0037b2abc5f2ee3644c
2023-02-16 03:29:02 -08:00
Yuval Tassa 9f79acd7da Remove redundant space from XMLreference TOC titles
PiperOrigin-RevId: 510076364
Change-Id: I59e0e7fd2f6eae9b89f5bb00f2192358da8abf7a
2023-02-16 01:47:38 -08:00
Kevin Zakka 1552b988ff Fix typo.
PiperOrigin-RevId: 509919399
Change-Id: Idd1845a81b073e99d98148ffe73699af3cedcc6c
2023-02-15 13:41:50 -08:00
Copybara-Service d26d7babe9 Merge pull request #734 from hyarion:fix/unity-load-balloons.xml
PiperOrigin-RevId: 509832074
Change-Id: Ia8505b4ea83d8903052e72a12b914a8fd94a13df
2023-02-15 07:51:34 -08:00
Yuval Tassa 6a85b5db45 Improve cartesian actuator example model.
Significantly reduced joint-level damping, introduced damping in the actuators themselves. This reduces dynamics artifacts by matching the space in which damping and actuation forces are applied.

PiperOrigin-RevId: 509574523
Change-Id: Id99b69aea4562509c48ed1a24fb9ea3e008c0b69
2023-02-14 10:41:21 -08:00
Saran Tunyasuvunakool ace5b74f83 Rename inteval attribute in mjLROpt to interval.
PiperOrigin-RevId: 509275105
Change-Id: I0ffb9cf485a504843ed255f0b4f24e9285a1c273
2023-02-13 10:54:25 -08:00
Saran Tunyasuvunakool db28c31f05 Rename <required> tag to <plugin>.
PiperOrigin-RevId: 509237786
Change-Id: I35e812830b479004ac5025cbd9477888f51fb43e
2023-02-13 08:41:52 -08:00
Saran Tunyasuvunakool 239e00e3b1 Fix typo in the error message for distance equality constraints.
PiperOrigin-RevId: 509227257
Change-Id: Ibf501f267e513c504e527f3fe7a26d4f29e78273
2023-02-13 07:58:03 -08:00
Benjamin Nauck 87bc8d0ed2 Fix spelling in MjcfImporter 2023-02-13 12:02:55 +01:00
Benjamin Nauck 8599d80b4d Apply tendon defaults on fixed and spatial tendons 2023-02-13 12:02:29 +01:00
Benjamin Nauck 7ed632cb9e Add support for arbitrary default node lookup name
Makes it possible to apply modifiers to elements even if the name doesn't match.
This is necessary to support default values for tendons.
2023-02-13 12:02:10 +01:00
Benjamin Nauck 5228ad1b2e Change default wind to the value from the doc 2023-02-13 10:21:30 +01:00
Benjamin Nauck e7a9447c03 Add gravcomp to body in unity plugin
The unity plugin is missing gravcomp which makes it impossible for buoyancy
2023-02-13 10:21:09 +01:00
Benjamin Nauck 9971993cdb Add support for implicit integrator type
The `implicit` option was added in the IntegratorType enum.
Using `@` prefix to avoid collision with reserved keyword.
2023-02-13 10:20:42 +01:00
Saran Tunyasuvunakool 5e989d18c3 Enable compiler errors for implicit switch case fallthroughs.
Also unify warning options across Clang and GCC and fix minor issues that was surfaced by this.

PiperOrigin-RevId: 508619655
Change-Id: I59b777bf2dfea4422485670e2427c7d3f5cf6405
2023-02-10 03:49:00 -08:00
Saran Tunyasuvunakool 8a53a33fd1 Convert tabs to spaces in doc/images/banner.svg.
PiperOrigin-RevId: 508345625
Change-Id: Ie97d46327670929aa4254efb5ae257069b309c1b
2023-02-09 05:22:09 -08:00
Saran Tunyasuvunakool 49c939eaf0 Document 48e95817e4 in the changelog.
PiperOrigin-RevId: 508342626
Change-Id: I8505d3c3168d0ebffaff87dc687a831d278a8fcb
2023-02-09 05:03:31 -08:00
Saran Tunyasuvunakool 71c5f1794d Remove efc_ fields from joint indexers.
Since the introduction of arena memory, these fields now have dynamic sizes that change between time steps depending on the number of active constraints. This breaks strict correspondence between joints and `efc_` rows.

Note that these fields can still be accessed directly as attributes on the `MjData` object.

PiperOrigin-RevId: 508342388
Change-Id: I610ae6ca462f6bb5cf8bc199a3436bed3d1a5371
2023-02-09 05:02:11 -08:00
Saran Tunyasuvunakool df87a85b84 De-duplicate vertices in mug.obj.
PiperOrigin-RevId: 508334141
Change-Id: If63e0923392b1ad11d4c9c295a511f929fc4be6d
2023-02-09 04:12:06 -08:00
Alessio Quaglino 2f10a7cb3b Update legacy memory specification in some example models.
PiperOrigin-RevId: 508330060
Change-Id: I16a5e70c5950178826a2a52a7a2005ef7f39ccfb
2023-02-09 03:47:43 -08:00
Saran Tunyasuvunakool 7d8e810ab1 Fix IPython history corruption when using launch_repl.
PiperOrigin-RevId: 508064761
Change-Id: I58fa2e4f35b57a1ab68c3172ba5c0d4495e40ced
2023-02-08 06:37:42 -08:00
Nimrod Gileadi 48e95817e4 Don't compute sensors in mjd_transitionFD, if not requested.
PiperOrigin-RevId: 507878658
Change-Id: I97ece521fd177d97fa5758dda1eb012ba26bcabe
2023-02-07 14:02:45 -08:00
Saran Tunyasuvunakool 15b6e6f060 Remove remarks in the documentation that suggest mj_name2id is inefficient.
`mj_name2id` has been replaced by a hash map lookup in 2.3.2.

PiperOrigin-RevId: 507816210
Change-Id: I3ee038fa6ec3258d51218588a43398f98a0f6de2
2023-02-07 10:13:45 -08:00
Saran Tunyasuvunakool e4b094732b Update dependency versions in Python requirements files.
PiperOrigin-RevId: 507791787
Change-Id: I2f87842c118ab6ee25857c52b7c02ca3012e964c
2023-02-07 08:40:52 -08:00
Saran Tunyasuvunakool 95a07e85cc Fix Windows stack overflow problem in the simulate app.
PiperOrigin-RevId: 507763611
Change-Id: I199910142d9165710c48b41a842ab9aef01ff5c2
2023-02-07 06:34:10 -08:00
Alessio Quaglino dd632b7ccc Bump MuJoCo version to 2.3.2.
PiperOrigin-RevId: 507720557
Change-Id: I7a5b577094ac1a7f468a84c484f62f61dc6b409f
2023-02-07 02:35:17 -08:00
Copybara-Service 36836d8e42 Merge pull request #636 from traversaro:fixextglfw
PiperOrigin-RevId: 507618773
Change-Id: I74362535e9840c97b7c4c3fbff29e06bcdcaf41a
2023-02-06 16:50:54 -08:00
Copybara-Service 6b80b010af Merge pull request #705 from hartikainen:bug/mj_deleteFileVFS-infinite-loop
PiperOrigin-RevId: 507544780
Change-Id: Ie5819d4cc567dce44ceb59624a889a06ecdd7c1b
2023-02-06 12:01:11 -08:00
Saran Tunyasuvunakool 10c5d6a1e5 Add missing entries to 2.3.2 changelog.
PiperOrigin-RevId: 507522863
Change-Id: Id6c094a8054440de4aa918575f6e45d49519861c
2023-02-06 10:44:18 -08:00
Saran Tunyasuvunakool 9a7f4a768a Remove control plugin API.
This is a rollback of f937ffd93326b2964e33689b0dc6024124776a9e.

PiperOrigin-RevId: 507456400
Change-Id: I2026510e6065eb440c0c899fcc5a2cc8ff5afd49
2023-02-06 05:52:17 -08:00
Nimrod Gileadi dc3a900809 Apply body pair filtering at broadphase.
mj_contactFilter removed geom pairs where their bodies share the same weldid, but this check can be applied at broadphase instead of at geom-geom level.

PiperOrigin-RevId: 507435848
Change-Id: Ia37c741071dc5e1c26686dd319f42c9bd334d305
2023-02-06 03:46:20 -08:00
Yuval Tassa 79fffdc0ae Draw body label at the body frame rather than inertial frame, unless inertia is being visualised.
PiperOrigin-RevId: 507424290
Change-Id: I72ca68e2e47f76c0f70959a1a2c8b5f4b6b6b290
2023-02-06 02:38:51 -08:00
Saran Tunyasuvunakool 7251e7b900 Remove superfluous TINYXML2_LIB declaration.
PiperOrigin-RevId: 506867694
Change-Id: I701def961046c46f3cffe4fad2b1b9436bc1deef
2023-02-03 04:24:36 -08:00
Kyle Bayes ffe27d9680 Extract AVX code from sparse utils.
PiperOrigin-RevId: 506851218
Change-Id: I23cc3ffb26face97fc2380bc9cb702cc41b8b29d
2023-02-03 02:42:39 -08:00