9#include <glm/gtc/quaternion.hpp>
49 [[nodiscard]]
static constexpr std::size_t
index(std::size_t finger, std::size_t joint)
noexcept
constexpr std::size_t kGripPoseBonesPerFinger
Number of bones authored per finger.
Definition GripPose.hpp:15
bool loadWeaponGripPose(const std::string &path, WeaponGripPose &out)
Load a weapon grip pose from a TOML side-table.
Definition GripPose.cpp:92
bool saveWeaponGripPoseToml(const std::string &path, const WeaponGripPose &pose, bool rightHandValid, bool leftHandValid)
Save a grip pose back to a TOML file.
Definition GripPose.cpp:115
constexpr std::size_t kGripPoseFingerCount
Number of fingers per hand: thumb, index, middle, ring, pinky.
Definition GripPose.hpp:18
constexpr std::size_t kGripPoseJointCount
Total joint count per hand grip pose (5 fingers × 4 joints = 20 joints).
Definition GripPose.hpp:21
Authored local-space finger angles describing how a hand wraps a weapon.
Definition GripPose.hpp:42
std::array< glm::vec2, kGripPoseJointCount > jointAngles
(pitch, yaw) in degrees per joint. .x = pitch (curl), .y = yaw (splay).
Definition GripPose.hpp:44
static constexpr std::size_t index(std::size_t finger, std::size_t joint) noexcept
Helper: index into jointAngles for (finger, joint).
Definition GripPose.hpp:49
Per-weapon pair of hand grip poses.
Definition GripPose.hpp:57
bool leftHandValid
Definition GripPose.hpp:61
GripPose leftHand
Definition GripPose.hpp:59
GripPose rightHand
Definition GripPose.hpp:58
bool rightHandValid
Definition GripPose.hpp:60