summaryrefslogtreecommitdiffhomepage
path: root/filter-ewma2/ftnoir_filter_ewma2.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'filter-ewma2/ftnoir_filter_ewma2.cpp')
-rw-r--r--filter-ewma2/ftnoir_filter_ewma2.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/filter-ewma2/ftnoir_filter_ewma2.cpp b/filter-ewma2/ftnoir_filter_ewma2.cpp
index c79596ef..b29746a0 100644
--- a/filter-ewma2/ftnoir_filter_ewma2.cpp
+++ b/filter-ewma2/ftnoir_filter_ewma2.cpp
@@ -22,7 +22,7 @@
// to minSmooth at a rate controlled by the powCurve setting.
-ewma::ewma() : first_run(true)
+ewma::ewma()
{
}
@@ -48,10 +48,10 @@ void ewma::filter(const double *input, double *output)
double noise_alpha = dt/(dt + noise_RC);
// scale curve .01->1 where 1.0 is sqrt(norm_noise).
- const double smoothing_scale_curve = static_cast<slider_value>(s.kSmoothingScaleCurve);
+ const double smoothing_scale_curve = *s.kSmoothingScaleCurve;
// min/max smoothing .01->1
- const double min_smoothing = static_cast<slider_value>(s.kMinSmoothing);
- const double max_smoothing = std::fmax(min_smoothing, static_cast<slider_value>(s.kMaxSmoothing));
+ const double min_smoothing = *s.kMinSmoothing;
+ const double max_smoothing = std::fmax(min_smoothing, *s.kMaxSmoothing);
// Calculate the new camera position.
for (int i=0;i<6;i++)