Skip to content

feat: add s_hook() module to hooks.scad#1971

Open
junhinhow wants to merge 1 commit intoBelfrySCAD:masterfrom
junhinhow:feat/s-hook-1701
Open

feat: add s_hook() module to hooks.scad#1971
junhinhow wants to merge 1 commit intoBelfrySCAD:masterfrom
junhinhow:feat/s-hook-1701

Conversation

@junhinhow
Copy link
Copy Markdown

Summary

  • Adds s_hook() module to hooks.scad for creating S-shaped hooks
  • Based on code by @RAMilewski from issue discussion, with attachable() support added
  • Configurable cross-section (polygon or circle), shaft length, loop radii/angles, stems, and curls
  • Named anchors: loop1, loop2, shaft_top, shaft_bot
  • Full documentation with 7 examples

Closes #1701

Test plan

  • Verify default s_hook() renders correctly
  • Verify circular cross-section with sides=0
  • Verify asymmetric configurations (different loop sizes)
  • Verify stem and curl extensions
  • Verify anchoring works (anchor=BOT, attach to other parts)

…rySCAD#1701)

Add s_hook() module based on code by RAMilewski, with improvements:
- Full attachable() support (anchor, spin, orient)
- Named anchors: loop1, loop2, shaft_top, shaft_bot
- Bounding box auto-calculated for anchoring
- Parameter validation with assert()
- Full BOSL2 documentation format with 7 examples
- End caps with rotate_sweep for clean closing

The hook is oriented along the Y axis with configurable loops,
stems, and reverse curls on each end. Cross-section can be a
regular polygon or circle.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Thoughts on hooks

1 participant