forked from RTMilliken/EDFbrowser
-
Notifications
You must be signed in to change notification settings - Fork 1
/
filter.h
36 lines (21 loc) · 778 Bytes
/
filter.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#ifndef filter_INCLUDED
#define filter_INCLUDED
#include <stdlib.h>
#include <string.h>
#define _USE_MATH_DEFINES
#include <math.h>
struct filter_settings{
double old_input;
double old_output;
double factor;
double sample_frequency;
double cutoff_frequency;
int is_LPF;
int first_sample;
};
struct filter_settings * create_filter(int, double, double);
void reset_filter(int, struct filter_settings *);
int first_order_filter(int, struct filter_settings *);
double get_filter_factor(double, double);
struct filter_settings * create_filter_copy(struct filter_settings *);
#endif