Update UsdWriter to write any parts of MjSpec that are not from USD to the EditTarget.

This enables two workflows:
1) Users that parsed some other format into MjSpec, or built it programmatically can export animated USD easily with as minimal as possible interaction with USD.

2) Creating a spec from USD, then modifying the spec, should not cause a duplication of data when writing to USD.

PiperOrigin-RevId: 827627520
Change-Id: I02c8c14a18569547710e54f3704d52ac0bf70ce6
This commit is contained in:
Sam Haves
2025-11-03 13:28:36 -08:00
committed by Copybara-Service
parent abc02b736e
commit 7d7648f7ed
5 changed files with 96 additions and 29 deletions
+1
View File
@@ -38,6 +38,7 @@ class Writer {
void AddSink(PoseSinkFn sink_fn);
private:
void WriteSpecsWithoutUSDOriginToLayer();
void BuildMjUsdMapping();
pxr::UsdStageRefPtr stage_;