diff options
author | Sven Kocksch <github@miniskipper.at> | 2017-05-17 07:22:02 +0200 |
---|---|---|
committer | Sven Kocksch <github@miniskipper.at> | 2017-05-17 07:22:02 +0200 |
commit | 0d8bfd9e607e0aea7c5af61496a6105449eae2b9 (patch) | |
tree | b2049243bbfddf7c66a20a0e651a757a562004a0 /proto-wine/ftnoir_protocol_wine.cpp | |
parent | b7b96007553a5ed11c43aab40f5361487ce9a5e7 (diff) |
use math const
Diffstat (limited to 'proto-wine/ftnoir_protocol_wine.cpp')
-rw-r--r-- | proto-wine/ftnoir_protocol_wine.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/proto-wine/ftnoir_protocol_wine.cpp b/proto-wine/ftnoir_protocol_wine.cpp index ea7fadf2..b3a780e7 100644 --- a/proto-wine/ftnoir_protocol_wine.cpp +++ b/proto-wine/ftnoir_protocol_wine.cpp @@ -4,6 +4,7 @@ #include <QStringList> #include <QCoreApplication> #include <string.h> +#include <math.h> #include <sys/mman.h> #include <sys/stat.h> /* For mode constants */ #include <fcntl.h> /* For O_* constants */ @@ -37,7 +38,7 @@ void wine::pose( const double *headpose ) { lck_shm.lock(); for (int i = 3; i < 6; i++) - shm->data[i] = headpose[i] / 57.295781; + shm->data[i] = headpose[i] / (180 / M_PI ); for (int i = 0; i < 3; i++) shm->data[i] = headpose[i] * 10; if (shm->gameid != gameid) |