docs: record usd-core decision, add Dockerfile task 1.0

- Mark USD library question as decided: usd-core>=24.11 (pxr module)
- Add Task 1.0 to USD implementation plan: Dockerfile install step
- Add usd-core to Priority 2 file targets in ROADMAP

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-11 15:13:10 +01:00
parent 5d912594dd
commit cbffcfbf8b
2 changed files with 18 additions and 3 deletions
+1
View File
@@ -92,6 +92,7 @@ This priority combines dead-code deletion and task decomposition because both ar
| Action | Path | | Action | Path |
|---|---| |---|---|
| ADD pip install | `render-worker/Dockerfile``usd-core>=24.11` (provides `pxr` module) ✅ decided |
| CREATE | `render-worker/scripts/export_step_to_usd.py` — XCAF → USD, hierarchy + metadata + partKey | | CREATE | `render-worker/scripts/export_step_to_usd.py` — XCAF → USD, hierarchy + metadata + partKey |
| ADD enum value | `backend/app/domains/media/models.py``usd_master` to `MediaAssetType` | | ADD enum value | `backend/app/domains/media/models.py``usd_master` to `MediaAssetType` |
| CREATE migration | `backend/alembic/versions/060_usd_master_asset_type.py` | | CREATE migration | `backend/alembic/versions/060_usd_master_asset_type.py` |
+17 -3
View File
@@ -9,7 +9,7 @@
## Prerequisites ## Prerequisites
- [ ] Priority 1 complete (step_tasks.py decomposed, blender_render.py decomposed) - [ ] Priority 1 complete (step_tasks.py decomposed, blender_render.py decomposed)
- [ ] Decision: USD authoring library (see Open Questions below) - [x] Decision: USD authoring library **`usd-core` (pip)** — provides `pxr` module, no GPU tools needed, pip-installable in render-worker
- [ ] Decision: seam/sharp payload encoding (primvars vs. JSON sidecar) - [ ] Decision: seam/sharp payload encoding (primvars vs. JSON sidecar)
--- ---
@@ -18,6 +18,21 @@
**Goal:** Export a valid `usd_master` alongside the existing GLB pipeline without changing any browser behavior. **Goal:** Export a valid `usd_master` alongside the existing GLB pipeline without changing any browser behavior.
### Task 1.0 — Install `usd-core` in render-worker
**File:** `render-worker/Dockerfile`
```dockerfile
# OpenUSD Python bindings — provides pxr module for USD authoring
RUN pip3 install --no-cache-dir "usd-core>=24.11"
```
Add after the `gmsh` line. `usd-core` is the Pixar-maintained pip distribution of OpenUSD — no GPU, no USD imaging, just the core authoring/scene APIs (`pxr.Usd`, `pxr.UsdGeom`, `pxr.Sdf`, `pxr.Vt`).
**Acceptance gate:** `docker compose exec render-worker python3 -c "from pxr import Usd; print(Usd.GetVersion())"``(24, 11, 0)` or later.
---
### Task 1.1 — `export_step_to_usd.py` scaffolding ### Task 1.1 — `export_step_to_usd.py` scaffolding
**File:** `render-worker/scripts/export_step_to_usd.py` **File:** `render-worker/scripts/export_step_to_usd.py`
@@ -304,11 +319,10 @@ Clicking an unassigned part in the viewer auto-focuses it in the MaterialPanel.
| # | Question | Options | Default recommendation | | # | Question | Options | Default recommendation |
|---|---|---|---| |---|---|---|---|
| 1 | USD authoring library | `pxr` (full OpenUSD, heavy) / `usda` text templating (no deps) / `usd-core` pip | Start with `pxr`pip-installable, same OCC kernel available | | 1 | USD authoring library | ~~`pxr` full / `usda` text / `usd-core` pip~~ | ✅ **`usd-core` pip** — `pip install usd-core` in render-worker Dockerfile |
| 2 | Seam/sharp payload encoding | Custom primvars on mesh prim / separate JSON sidecar / GLB extras (current) | Index-space primvars — cleaner, survives transforms | | 2 | Seam/sharp payload encoding | Custom primvars on mesh prim / separate JSON sidecar / GLB extras (current) | Index-space primvars — cleaner, survives transforms |
| 3 | Preview GLB derivation | USD → GLB export pass / co-author from same tessellation pass | Co-author during migration (avoid round-trip loss) | | 3 | Preview GLB derivation | USD → GLB export pass / co-author from same tessellation pass | Co-author during migration (avoid round-trip loss) |
| 4 | Single-file USD or override layers | Flat single file / canonical + overlay layers (flattened for delivery) | RFC recommends Option B (overlay layers, flatten for delivery) | | 4 | Single-file USD or override layers | Flat single file / canonical + overlay layers (flattened for delivery) | RFC recommends Option B (overlay layers, flatten for delivery) |
| 5 | `pxr` install in render-worker | Add to `render-worker/Dockerfile` / use system package | `pip install usd-core` — no NVIDIA/Pixar GPU tools needed |
--- ---