Repository navigation
Conversation
The 3D view only had bodies for iPhone 18 Pro, 18 Pro Max, Duo, and iPad Pro 13-inch (M5); every other simulator fell back to the flat view. This adds Apple's AR models for iPhone 14 through 17, 17e, and Air, and maps the hardware names that share a body (14/15 Pro onto 16 Pro, 16e onto 17e, iPad Pro M4 onto M5). Done with Claude Opus 5.5 in T3 Code.
The 18 device GLBs were 39.9 MB (22.3 MB gzipped), almost all uncompressed geometry, and the iPhone 16 and 16 Plus camera glass z-fought with the layer beneath it. - Compress geometry with EXT_meshopt_compression on one scene-wide 16-bit grid. Per-mesh grids round Apple's coincident layers apart and z-fight. The loader registers three's MeshoptDecoder and bakes display meshes back into float model-space geometry, which the screen checks, UVs and touch projection need. - Drop 478 parts that never change a pixel (sources.json hiddenNodes). - Push the iPhone 16 and 16 Plus glass shells 0.0003 units outward (sources.json surfaceOffsets) so they stop crossing the base layer. The converter applies both new fields; docs/internals/devices.md records the pipeline constraints. Models now total 12.0 MB (8.3 MB gzipped). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
ApprovabilityVerdict: Needs Human Approval Macroscope's review found this PR requires human approval — Newly recognized iPhones automatically use bundled 3D bodies instead of the procedural fallback, alongside compressed updates to existing models. Human confirmation is required for this change to the default device presentation. You can add or adjust custom eligibility rules. Learn more. |
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Model source catalog and conversion apps/web/src/components/device/models/sources.json, scripts/convert-device-model.py, docs/internals/devices.md |
The source catalog adds model metadata and node mappings. The converter filters configured hidden nodes and applies surface offsets. The documentation describes the conversion and runtime handling of quantized display meshes. |
Model IDs and asset registration packages/client-runtime/src/device/model.ts, packages/client-runtime/src/device/model.test.ts, apps/web/src/components/device/deviceModels.ts |
The runtime resolves supported iOS hardware names through a case-insensitive mapping and strips trailing memory suffixes. The web catalog registers assets for additional iPhone models. Tests cover mapped and unmatched names, including an Android case. |
Quantized scene loading and display transforms packages/client-runtime/src/device/modelScene.ts, packages/client-runtime/src/device/modelScene.test.ts |
The loader configures MeshoptDecoder and bakes display-mesh transforms into float geometry. Tests check the resulting position attribute type and UV value. |
Estimated code review effort: 3 (Moderate) | ~25 minutes
Change: Feature
Sequence Diagram(s)
sequenceDiagram
participant loadDeviceModel
participant GLTFLoader
participant MeshoptDecoder
participant bakeDisplayTransforms
loadDeviceModel->>GLTFLoader: Configure MeshoptDecoder
GLTFLoader->>MeshoptDecoder: Decode meshopt data
GLTFLoader-->>loadDeviceModel: Return parsed scene
loadDeviceModel->>bakeDisplayTransforms: Bake display transforms
Possibly related PRs
- pingdotgg/t3code#26884: Adds the initial hardware-type model selection and model-loading support that this change expands.
- pingdotgg/t3code#12787: Introduces the device workspace and imported phone-scene loader used by this change.
- pingdotgg/t3code#12813: Adds the iPhone Duo model and shared viewer; this change updates the shared imported-asset pipeline.
Suggested reviewers: juliusmarminge, t3dotgg
Merge Risk: 
Minimal · up to e8d07
-
The model catalog and loader changes have no established merge blocker. Visual behavior of the new models remains unverified in the running app.
Pre-merge checks: 
4
-
Full details: Title check
-
Explanation
The title clearly identifies the primary change: adding 3D device bodies for iPhone 14 through 17 and iPhone Air. Supporting loader, compression, and mapping changes do not need to appear in the title.
Full details: Description check
-
Explanation
The description is mostly complete. It explains the problem, implementation, scope split, asset and license tradeoffs, evidence, verification commands, and unchecked scenarios. It uses different headings from the template and does not state explicit maintainer approval, but the required context is otherwise present.
-
Finishing Touches
-
🧪 Generate unit tests (beta)
-
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Comment @coderabbitai help to get the list of available commands.
Split from #26884 as asked there: this PR is only the new model catalog. The renamed-simulator fix is #27932. Neither depends on the other.
The 3D view only had bodies for iPhone 18 Pro, 18 Pro Max, Duo, and iPad Pro 13-inch (M5). Every other iPhone simulator fell back to the generated slab.
Models.
resolveDeviceModelIdis now one name table. I converted Apple's AR files from the iPhone compare page with the existingscripts/convert-device-model.py:Each entry in
sources.jsonrecords the source URL, checksum, chosen body and screen nodes, and Blender version. The converter gainedexcludeNodesbecause the Air's source file stacks every colour variant's back glass.Size (commit by @DominikScholz, from Kaloyanes#12). All 18 models compress from 39.9 MB to 12.0 MB (8.3 MB gzipped) with meshopt on one scene-wide 16-bit grid, plus removal of 478 parts that never change a pixel. The loader decodes meshopt and bakes display transforms back to float geometry. That commit also fixes z-fighting on the iPhone 16 and 16 Plus camera glass. It recompresses the five existing models too, so they need the new loader to ship together with them.
Tradeoffs for maintainers:
sources.jsonalready records for the existing five.Evidence
Blender renders of the converted models (front and back):
Compression before/after renders are in Kaloyanes#12. Close-up renders average 0.06/255 per pixel against the originals.
Checks:
vp test run packages/client-runtime/src/device/model.test.ts packages/client-runtime/src/device/modelScene.test.ts: the name table rows, and a quantized display accepted once its transform is baked.vp run check:changed: format, lint, knip, typecheck, tests, and react compiler pass.Not checked: the new models live in the app; I only had iPhone 18 Pro simulators booted. Android is unchanged. Mobile has no 3D viewer.
Model: Claude Opus 5.5 in Claude Code (T3 Code); compression by DominikScholz with Claude Opus 5.5.