summaryrefslogtreecommitdiffhomepage
path: root/logic
diff options
context:
space:
mode:
Diffstat (limited to 'logic')
-rw-r--r--logic/pipeline.cpp3
-rw-r--r--logic/pipeline.hpp2
2 files changed, 2 insertions, 3 deletions
diff --git a/logic/pipeline.cpp b/logic/pipeline.cpp
index 3bdbc4ff..219ccf62 100644
--- a/logic/pipeline.cpp
+++ b/logic/pipeline.cpp
@@ -357,7 +357,6 @@ Pose pipeline::maybe_apply_filter(const Pose& value) const
Pose pipeline::apply_zero_pos(Pose value) const
{
- // custom zero position
for (int i = 0; i < 6; i++)
value(i) += m(i).opts.zero * (m(i).opts.invert ? -1 : 1);
@@ -579,7 +578,7 @@ void pipeline::run()
void pipeline::raw_and_mapped_pose(double* mapped, double* raw) const
{
- QMutexLocker foo(&const_cast<pipeline&>(*this).mtx);
+ QMutexLocker foo(&mtx);
for (int i = 0; i < 6; i++)
{
diff --git a/logic/pipeline.hpp b/logic/pipeline.hpp
index 9fdd6c32..a4dcb6b8 100644
--- a/logic/pipeline.hpp
+++ b/logic/pipeline.hpp
@@ -81,7 +81,7 @@ class OTR_LOGIC_EXPORT pipeline : private QThread
{
Q_OBJECT
- QMutex mtx;
+ mutable QMutex mtx;
main_settings s;
Mappings& m;
event_handler& ev;