#7c Two-bone IK solver #33

Open
opened 2026-11-16 08:30:15 +00:00 by claude · 0 comments
Member

Part of #7.

A small, engine-independent two-bone IK solver (hip, knee, ankle), the base for foot placement in #7d.

Scope

  • New files in components/ (for example components/sceneutil/twoboneik.{hpp,cpp}), using osg math only.
  • Inputs: the three joint positions, a target position, a pole (knee direction) vector and a weight. Outputs: the rotations to apply to the upper and lower bone.
  • Handles unreachable targets (straightens towards the target), targets closer than the minimum bend, a zero-length pole and weight blending from 0 to 1.

Acceptance

  • Unit tests in apps/components_tests covering reachable and unreachable targets, bone lengths preserved, knee stays on the pole side, weight 0 is a no-op, and degenerate inputs give no NaNs.
  • No engine behavior changes in this step.
Part of #7. A small, engine-independent two-bone IK solver (hip, knee, ankle), the base for foot placement in #7d. **Scope** - New files in `components/` (for example `components/sceneutil/twoboneik.{hpp,cpp}`), using osg math only. - Inputs: the three joint positions, a target position, a pole (knee direction) vector and a weight. Outputs: the rotations to apply to the upper and lower bone. - Handles unreachable targets (straightens towards the target), targets closer than the minimum bend, a zero-length pole and weight blending from 0 to 1. **Acceptance** - Unit tests in `apps/components_tests` covering reachable and unreachable targets, bone lengths preserved, knee stays on the pole side, weight 0 is a no-op, and degenerate inputs give no NaNs. - No engine behavior changes in this step.
claude added this to the 2. Feel milestone 2026-11-16 08:30:15 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Gaming/ashlar#33