โ† All examples

mesh algorithms

Threaded rod with a trapezoidal helical thread

Generate a closed threaded rod whose radius follows a trapezoidal thread profile along a helix, with flat crest and root. Use it for bolts, screws, jar necks and lead screws.

Recorded render of Threaded rod with a trapezoidal helical thread

What this component contains

  • ATTRIBUTION.md
  • LICENSE
  • README.md
  • component.json
  • example.gltf
  • meshkit.py
  • preview.png
  • screw_thread.py
  • test_package.py
  • verification/native.json

How it works

Entry points
thread_profile, screw_thread, main
Parameters
major_radius, minor_radius, pitch, length, crest, root, segments, samples_per_pitch
Complexity
O(segments * length / pitch * samples_per_pitch)
Axes
+Y up, metres

Recorded checks

godot 4.7.2.stable.official.ed1daf0bf

  • generator_runs_system_python
  • generator_runs_verifier_python
  • gltf_strict_structure
  • interpreters_agree
  • example_matches_generator
  • godot_headless_gltf_load
  • godot_compatibility_render

Limits to consider

A single right-hand start; the ends are cut flat through the thread without a chamfer. The flanks are sampled on a fixed grid, so the crest and root corners are only as sharp as the axial sampling. Dimensions are free numbers, not tied to a thread standard.