From 6c58bec550a04d71d1269dfd10540a0fd3bac19e Mon Sep 17 00:00:00 2001 From: Andrzej Kapolka Date: Mon, 12 May 2014 17:32:06 -0700 Subject: [PATCH] Untabbed. --- interface/src/devices/PrioVR.cpp | 36 ++++++++++++++++---------------- interface/src/devices/PrioVR.h | 4 ++-- 2 files changed, 20 insertions(+), 20 deletions(-) diff --git a/interface/src/devices/PrioVR.cpp b/interface/src/devices/PrioVR.cpp index f9f807bdb7..9b5427be07 100644 --- a/interface/src/devices/PrioVR.cpp +++ b/interface/src/devices/PrioVR.cpp @@ -14,20 +14,20 @@ #include "PrioVR.h" const unsigned int SERIAL_LIST[] = { 0x00000001, 0x00000000, 0x00000008, 0x00000009, 0x0000000A, 0x0000000C, 0x0000000D, - 0x0000000E, 0x00000004, 0x00000005, 0x00000010, 0x00000011 }; + 0x0000000E, 0x00000004, 0x00000005, 0x00000010, 0x00000011 }; const unsigned char AXIS_LIST[] = { 9, 43, 37, 37, 37, 13, 13, 13, 52, 52, 28, 28 }; const int LIST_LENGTH = sizeof(SERIAL_LIST) / sizeof(SERIAL_LIST[0]); PrioVR::PrioVR() { #ifdef HAVE_PRIOVR - _jointsDiscovered.resize(LIST_LENGTH); + _jointsDiscovered.resize(LIST_LENGTH); _skeletalDevice = yei_setUpPrioVRSensors(0x00000000, const_cast(SERIAL_LIST), - const_cast(AXIS_LIST), _jointsDiscovered.data(), LIST_LENGTH, YEI_TIMESTAMP_SYSTEM); - if (!_skeletalDevice) { - return; - } - _jointRotations.resize(LIST_LENGTH); - yei_tareSensors(_skeletalDevice); + const_cast(AXIS_LIST), _jointsDiscovered.data(), LIST_LENGTH, YEI_TIMESTAMP_SYSTEM); + if (!_skeletalDevice) { + return; + } + _jointRotations.resize(LIST_LENGTH); + yei_tareSensors(_skeletalDevice); #endif } @@ -42,15 +42,15 @@ PrioVR::~PrioVR() { void PrioVR::update() { #ifdef HAVE_PRIOVR if (!_skeletalDevice) { - return; - } - unsigned int timestamp; - yei_getLastStreamDataAll(_skeletalDevice, (char*)_jointRotations.data(), - _jointRotations.size() * sizeof(glm::quat), ×tamp); - for (int i = 0; i < _jointsDiscovered.size(); i++) { - if (_jointsDiscovered.at(i)) { - qDebug() << i << _jointRotations.at(i).x << _jointRotations.at(i).y << _jointRotations.at(i).z << _jointRotations.at(i).w; - } - } + return; + } + unsigned int timestamp; + yei_getLastStreamDataAll(_skeletalDevice, (char*)_jointRotations.data(), + _jointRotations.size() * sizeof(glm::quat), ×tamp); + for (int i = 0; i < _jointsDiscovered.size(); i++) { + if (_jointsDiscovered.at(i)) { + qDebug() << i << _jointRotations.at(i).x << _jointRotations.at(i).y << _jointRotations.at(i).z << _jointRotations.at(i).w; + } + } #endif } diff --git a/interface/src/devices/PrioVR.h b/interface/src/devices/PrioVR.h index d5bac44a9a..1c26009b33 100644 --- a/interface/src/devices/PrioVR.h +++ b/interface/src/devices/PrioVR.h @@ -39,8 +39,8 @@ private: YEI_Device_Id _skeletalDevice; #endif - QVector _jointsDiscovered; - QVector _jointRotations; + QVector _jointsDiscovered; + QVector _jointRotations; }; #endif // hifi_PrioVR_h