lmc_filter_node.h
Go to the documentation of this file.
1 
8 #ifndef LMC_FILTER_NODE_H
9 #define LMC_FILTER_NODE_H
10 class lpf
11 {
12  public:
13  lpf();
14  lpf(double);
15  void setCutoff(double);
16  void setInitialPos(double initial_msrmt, int b_idx, int dim);
17  double filter(const double& new_msrmt, int f_idx, int dim);
18  double getFilteredMsrmt(int f_idx, int dim);
19  double c_; // Related to the cutoff frequency of the filter.
20  // c = 1 results in a cutoff at 1/4 of the sampling rate.
21  // See bitbucket.org/AndyZe/pid if you want to get more sophisticated.
22  // Larger c --> trust the filtered data more, trust the measurements less.
23  private:
24  double prev_msrmts_ [6][3][3];
25  double prev_filtered_msrmts_ [6][3][2];
26 };
27 #endif /* LMC_FILTER_NODE_H */
void setInitialPos(double initial_msrmt, int b_idx, int dim)
This is used to set the inital position values of a filter.
lpf()
Uses default values for initial setup.
Lowpass filter class.
double getFilteredMsrmt(int f_idx, int dim)
This is used to get a filtered value of a bone.
void setCutoff(double)
Use this to change the cutoff of a lpf object.
double c_
double prev_msrmts_[6][3][3]
double filter(const double &new_msrmt, int f_idx, int dim)
This is used to filter the position values of a bone.
double prev_filtered_msrmts_[6][3][2]


leap_motion
Author(s): Florian Lier , Mirza Shah , Isaac IY Saito
autogenerated on Tue Jun 2 2020 03:58:01