client: xrHandTrackingDataSourceExt to filter out controller-based HT

This commit is contained in:
galister
2026-09-27 17:14:33 +09:00
parent 596e661d7e
commit ee0d667105
11 changed files with 127 additions and 68 deletions
+3 -3
View File
@@ -160,14 +160,14 @@ public:
static std::optional<std::array<from_headset::hand_tracking::pose, XR_HAND_JOINT_COUNT_EXT>> locate_hands(xr::hand_tracker & hand, XrSpace space, XrTime time)
{
auto joints = hand.locate(space, time);
auto located = hand.locate(space, time);
if (joints)
if (located and located->is_input_source())
{
std::array<from_headset::hand_tracking::pose, XR_HAND_JOINT_COUNT_EXT> poses;
for (int i = 0; i < XR_HAND_JOINT_COUNT_EXT; i++)
{
const auto & joint = (*joints)[i];
const auto & joint = located->joints[i];
poses[i] = {
.position = joint.first.pose.position,
.orientation = pack(joint.first.pose.orientation),