Spur Gear

Spur Gear render

gears/external/spur_gear.pyOBJECT_OT_add_spur_gear (object.add_spur_gear, "Add Spur Gear")

Straight-tooth external involute gear. The baseline gear primitive — every other external-gear generator in this library (helical, herringbone, bevel) is a variation on the same tooth-profile math built in this file. See README.md for conventions shared across the whole family.

Properties

Property Type Default Range Notes
targetObject pointergears with bmech_moduleMatch Target; runs sync_module_pa
moduleFloat (mm)1.00.1–50.0
tooth_countInt205–500
pressure_angle_degFloat (°)20.010–45
width_mmFloat (mm)6.00.1–100 (soft)Solidify modifier depth
bore_enableBoolTrue
bore_diameterFloat (mm)5.00.1–50 (soft)
bore_compensationFloat (mm)0.20.0–1.0 (soft)Added to bore radius

Build method

Unlike every other gear primitive in the library, the spur gear is built as a flat 2D n-gon profile + Solidify modifier, not a hand-extruded solid mesh. build_gear_profile() produces a closed polygon (tooth flanks are involute curves sampled at INVOLUTE_POINTS=15 points, tooth spaces are dedendum-circle arcs), which is filled as a single face and thickened with a SOLIDIFY modifier (thickness=width_mm, offset=0.0).

If bore_enable, the Solidify modifier is applied first (so the bore boolean operates on a real solid, not a modifier stack), then a cylinder cutter is boolean-subtracted (EXACT solver) using the same bore_r = bore_diameter/2 + bore_compensation convention as the rest of the family.

Panel warnings

Output

One object, name Gear (or Gear.001, etc. via unique_name), stamped gear_matching.stamp_gear(obj, "spur", module, pressure_angle_deg, tooth_count=tooth_count). No hand or helix_angle_deg fields — spur gears are straight-toothed.