summaryrefslogtreecommitdiffhomepage
path: root/FTNoIR_Filter_Accela
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2012-09-21 07:21:02 +0000
committerStanislaw Halik <sthalik@misaki.pl>2012-09-21 07:21:02 +0000
commit9b75369b820c4d3a93739dbcb664df329b183e09 (patch)
treecfd72be603bd4c2f48291a62a00a965e53cba88b /FTNoIR_Filter_Accela
parent5da3b245b35cdd2bb4b1490aae81f8d0ff0bde82 (diff)
Fix function-config and Accela after recent refactoring.
git-svn-id: svn+ssh://svn.code.sf.net/p/facetracknoir/code@149 19e81ba0-9b1a-49c3-bd6c-561e1906d5fb
Diffstat (limited to 'FTNoIR_Filter_Accela')
-rw-r--r--FTNoIR_Filter_Accela/FTNoIR_FilterControls.ui12
-rw-r--r--FTNoIR_Filter_Accela/ftnoir_filter_accela.cpp15
2 files changed, 10 insertions, 17 deletions
diff --git a/FTNoIR_Filter_Accela/FTNoIR_FilterControls.ui b/FTNoIR_Filter_Accela/FTNoIR_FilterControls.ui
index 6171defe..7a5c8047 100644
--- a/FTNoIR_Filter_Accela/FTNoIR_FilterControls.ui
+++ b/FTNoIR_Filter_Accela/FTNoIR_FilterControls.ui
@@ -9,7 +9,7 @@
<rect>
<x>0</x>
<y>0</y>
- <width>321</width>
+ <width>880</width>
<height>349</height>
</rect>
</property>
@@ -43,7 +43,7 @@
</property>
<property name="minimumSize">
<size>
- <width>300</width>
+ <width>850</width>
<height>300</height>
</size>
</property>
@@ -65,8 +65,8 @@
<rect>
<x>20</x>
<y>20</y>
- <width>215</width>
- <height>220</height>
+ <width>819</width>
+ <height>244</height>
</rect>
</property>
<property name="maxInputEGU" stdset="0">
@@ -76,10 +76,10 @@
<number>8</number>
</property>
<property name="pixPerEGU_Input" stdset="0">
- <number>40</number>
+ <number>191</number>
</property>
<property name="pixPerEGU_Output" stdset="0">
- <number>20</number>
+ <number>23</number>
</property>
<property name="gridDistEGU_Input" stdset="0">
<number>1</number>
diff --git a/FTNoIR_Filter_Accela/ftnoir_filter_accela.cpp b/FTNoIR_Filter_Accela/ftnoir_filter_accela.cpp
index 7b1b7008..e6a009f0 100644
--- a/FTNoIR_Filter_Accela/ftnoir_filter_accela.cpp
+++ b/FTNoIR_Filter_Accela/ftnoir_filter_accela.cpp
@@ -14,6 +14,7 @@
#include "math.h"
#include <QDebug>
#include <windows.h>
+#include <float.h>
FTNoIR_Filter::FTNoIR_Filter() :
functionConfig("Accela-Scaling-Rotation", 4, 8),
@@ -85,16 +86,10 @@ void FTNoIR_Filter::FilterHeadPoseData(THeadPoseData *current_camera_position, T
for (i=0;i<6;i++)
{
- volatile double bleh;
-
- bleh = target[i];
-
- if (bleh != bleh)
+ if (_isnan(target[i]))
return;
- bleh = prev_output[i];
-
- if (bleh != bleh)
+ if (_isnan(prev_output[i]))
return;
double e2 = target[i];
@@ -129,9 +124,7 @@ void FTNoIR_Filter::FilterHeadPoseData(THeadPoseData *current_camera_position, T
output[i] = sum;
}
- bleh = output[i];
-
- if (bleh != bleh)
+ if (_isnan(output[i]))
return;
}