Summary
Add a one-shot Align cylinders tool so a shaft can be placed into a hole (or the reverse) by picking two cylindrical faces, coaxially aligning them, then dragging insert depth along the shared axis before baking the transform.
This is not a persistent assembly mate. Placement bakes into BREP like Move / Rotate (SetLocalTransformation preview -> bake_transform_into_geometry + Shape_geom_delta).
Problem
- Users can Move / Rotate solids freely, but there is no way to snap a rod into a hole by cylindrical axes.
- Hole and shaft geometry already exist as OCCT cylindrical faces; the app did not extract axis/radius or offer an insert-align workflow.
Implemented scope
Behavior:
- Mode
Shape_cyl_align, default hotkey J (mode.cyl_align, remappable).
- Pick moving cylindrical face, then fixed cylindrical face on a different solid.
- Coaxial align; drag axial depth (or Tab for exact depth); LMB / Enter finalize; Esc cancel.
- Options Flip direction reverses axis sense.
- Radius mismatch logs a warning but still places.
- Face selection mode while picking; dynamic AIS highlight off during depth drag.
Code:
cylinder_from_face / cyl_align_trsf in utl_geom
Shp_cyl_align operation
- Mode / hotkey / toolbar / Options / Occt_view wiring
Documentation:
docs/usage.md (Align cylinders section + hotkeys)
src/doc/shape.md, src/doc/gui.md
CHANGELOG.md [Unreleased]
Acceptance criteria
Out of scope (v1)
- Persistent mates / assembly constraints
- Auto flush to planar end faces
- Script bindings
- Fit / interference checking beyond radius warning
Related
- Branch:
Trailcode/shp-cyl-align
Summary
Add a one-shot Align cylinders tool so a shaft can be placed into a hole (or the reverse) by picking two cylindrical faces, coaxially aligning them, then dragging insert depth along the shared axis before baking the transform.
This is not a persistent assembly mate. Placement bakes into BREP like Move / Rotate (
SetLocalTransformationpreview ->bake_transform_into_geometry+Shape_geom_delta).Problem
Implemented scope
Behavior:
Shape_cyl_align, default hotkey J (mode.cyl_align, remappable).Code:
cylinder_from_face/cyl_align_trsfinutl_geomShp_cyl_alignoperationDocumentation:
docs/usage.md(Align cylinders section + hotkeys)src/doc/shape.md,src/doc/gui.mdCHANGELOG.md[Unreleased]Acceptance criteria
Out of scope (v1)
Related
Trailcode/shp-cyl-align