You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 3b0f5a0
Browse filesBrowse the repository at this point in the historyBrowse files
fix(content): port the #297/#298 export contract to template, skill, rule, example
PR #309 fixed the snippets only. The same two defects remained elsewhere:
- templates/ai-asset-pipeline-template/pipeline.py: the Unreal path scaled
obj.scale x100 but not obj.location, so node translations stayed in meters
under centimeter geometry (origin_to_base always moves location.z, so every
LOD was affected). apply_selected_mesh_transforms looped transform_apply per
object. Both now match snippets/export_preset_unreal.py / _unity.py.
- skills/ai-mesh-cleanup/SKILL.md: apply_object_transform overrode
selected_objects=[obj] (does not narrow transform_apply) and was called in a
loop. Now apply_transforms(objs): one call, selected_editable_objects.
- rules/validate-imported-mesh-scale.mdc: the "required pattern" looped
transform_apply per object, against prefer-data-over-ops-in-loops. Now one
call over the scaled meshes.
- examples/export-preset-axis: per-object loop with selected_objects=[obj]
replaced by the snippet body.
Proof (local, .scratch/blender-5.2.1-windows-x64/blender.exe, 5.2.1 LTS):
- pipeline --preset unreal on tests/smoke/make_pipeline_glb.py fixture:
lod0 node translation before [0, -1, 0] (m), after [0, -100, 0] (cm),
matching the cm POSITION data.
- export-preset-axis: happy path exit 0 ("export-preset-axis OK");
falsifier --same-axis still exits 9.
- check_import_export_rules, check_exit_code_readme, build_claude_rules --check pass.
Closes#326
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@@ -107,9 +112,7 @@ if not scene_units_are_meters(scene):
107
112
scene.unit_settings.system ="METRIC"
108
113
scene.unit_settings.scale_length =1.0
109
114
110
-
for obj in imported_meshes():
111
-
ifnot scale_is_identity(obj):
112
-
apply_object_transform(obj)
115
+
apply_transforms([o for o in imported_meshes() ifnot scale_is_identity(o)])
113
116
```
114
117
115
118
`export_apply=True` on glTF applies **modifiers**, not object scale. Unapplied object scale lands on the glTF node. Witness: `examples/unapplied-scale-gltf/`.
0 commit comments