Add option to only sync the state to improve sync performance in passive mode.
By default this option is off, which preserves the current behavior of syncing all of `mjModel` and `mjData`. PiperOrigin-RevId: 776498017 Change-Id: I02127c9397efbabebb89b0e0d139b00b6e665d35
This commit is contained in:
committed by
Copybara-Service
parent
8f6a13aa8f
commit
09f7154e57
+4
-3
@@ -54,9 +54,10 @@ class Simulate {
|
||||
std::unique_ptr<PlatformUIAdapter> platform_ui_adapter,
|
||||
mjvCamera* cam, mjvOption* opt, mjvPerturb* pert, bool is_passive);
|
||||
|
||||
// Synchronize mjModel and mjData state with UI inputs, and update
|
||||
// visualization.
|
||||
void Sync();
|
||||
// Synchronize state with UI inputs, and update visualization. If state_only
|
||||
// is false mjData and mjModel will be updated, otherwise only the subset of
|
||||
// mjData corresponding to mjSTATE_INTEGRATION will be synced.
|
||||
void Sync(bool state_only = false);
|
||||
|
||||
void UpdateHField(int hfieldid);
|
||||
void UpdateMesh(int meshid);
|
||||
|
||||
Reference in New Issue
Block a user