Skip to content

Commit

Permalink
Don't call the reference origin position 'waist,' as it's not exactly…
Browse files Browse the repository at this point in the history
… 'waist'
  • Loading branch information
KimihikoAkayasaki committed Oct 1, 2022
1 parent bf237ec commit 54b3b6e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Amethyst/GeneralPage.xaml.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2375,7 +2375,7 @@ Windows::Foundation::IAsyncAction Amethyst::implementation::GeneralPage::Execute
// Set up the calibration origin
if (calibration_first_time)
*calibrationOrigin =
k2app::interfacing::kinectWaistPosition[
k2app::interfacing::deviceRelativeTransformOrigin[
general_calibrating_device_guid];

// Cache the calibration first_time
Expand Down
2 changes: 1 addition & 1 deletion Amethyst/K2Interfacing.h
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ namespace k2app::interfacing
// Position helpers for k2 devices -> GUID, Pose
inline std::map<std::wstring, Eigen::Vector3d>
kinectHeadPosition, // But this one's kinect-only
kinectWaistPosition; // This one applies to both bases
deviceRelativeTransformOrigin; // This one applies to both

// OpenVR playspace position
inline Eigen::Vector3d vrPlayspaceTranslation = Eigen::Vector3d(0, 0, 0);
Expand Down
10 changes: 5 additions & 5 deletions Amethyst/K2Main.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#pragma once
#pragma once
#include <ranges>

#include "K2DeviceMath.h"
Expand Down Expand Up @@ -248,7 +248,7 @@ namespace k2app::main

interfacing::kinectHeadPosition[pDevice->getDeviceGUID()] =
pDevice->getTrackedJoints()[ktvr::Joint_Head].getJointPosition();
interfacing::kinectWaistPosition[pDevice->getDeviceGUID()] =
interfacing::deviceRelativeTransformOrigin[pDevice->getDeviceGUID()] =
pDevice->getTrackedJoints()[ktvr::Joint_SpineWaist].getJointPosition();
}
break;
Expand All @@ -260,7 +260,7 @@ namespace k2app::main
pDevice->update(); // Update the device

if (K2Settings.K2TrackersVector[0].selectedTrackedJointID < pDevice->getTrackedJoints().size())
interfacing::kinectWaistPosition[pDevice->getDeviceGUID()] = pDevice->getTrackedJoints().at(
interfacing::deviceRelativeTransformOrigin[pDevice->getDeviceGUID()] = pDevice->getTrackedJoints().at(
K2Settings.K2TrackersVector[0].selectedTrackedJointID).getJointPosition();
}
break;
Expand All @@ -280,7 +280,7 @@ namespace k2app::main

interfacing::kinectHeadPosition[pDevice->getDeviceGUID()] =
pDevice->getTrackedJoints()[ktvr::Joint_Head].getJointPosition();
interfacing::kinectWaistPosition[pDevice->getDeviceGUID()] =
interfacing::deviceRelativeTransformOrigin[pDevice->getDeviceGUID()] =
pDevice->getTrackedJoints()[ktvr::Joint_SpineWaist].getJointPosition();
}
break;
Expand All @@ -293,7 +293,7 @@ namespace k2app::main
pDevice->update(); // Update the device

if (K2Settings.K2TrackersVector[0].selectedTrackedJointID < pDevice->getTrackedJoints().size())
interfacing::kinectWaistPosition[pDevice->getDeviceGUID()] = pDevice->getTrackedJoints().at(
interfacing::deviceRelativeTransformOrigin[pDevice->getDeviceGUID()] = pDevice->getTrackedJoints().at(
K2Settings.K2TrackersVector[0].selectedTrackedJointID).getJointPosition();
}
break;
Expand Down

0 comments on commit 54b3b6e

Please sign in to comment.